Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(5053)

Unified Diff: chrome/browser/ui/views/tabs/fake_base_tab_strip_controller.cc

Issue 983853002: Hide close buttons of inactive stacked tabs by default (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: histograms.xml changed Created 5 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/browser/about_flags.cc ('k') | chrome/browser/ui/views/tabs/tab.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/views/tabs/fake_base_tab_strip_controller.cc
diff --git a/chrome/browser/ui/views/tabs/fake_base_tab_strip_controller.cc b/chrome/browser/ui/views/tabs/fake_base_tab_strip_controller.cc
index 89a234b9c6ef189e30ca5c65caf2559af3c7c21a..22845aaf19ad9606d69a37f3f6fd1bc5c903d7f4 100644
--- a/chrome/browser/ui/views/tabs/fake_base_tab_strip_controller.cc
+++ b/chrome/browser/ui/views/tabs/fake_base_tab_strip_controller.cc
@@ -65,6 +65,9 @@ bool FakeBaseTabStripController::IsNewTabPage(int index) const {
}
void FakeBaseTabStripController::SelectTab(int index) {
+ if (!IsValidIndex(index))
+ return;
+ active_index_ = index;
}
void FakeBaseTabStripController::ExtendSelectionTo(int index) {
« no previous file with comments | « chrome/browser/about_flags.cc ('k') | chrome/browser/ui/views/tabs/tab.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698