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

Unified Diff: chrome/browser/browser.cc

Issue 1001003: Allow dynamic switching in and out of sidetabs mode. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: '' Created 10 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
Index: chrome/browser/browser.cc
===================================================================
--- chrome/browser/browser.cc (revision 41630)
+++ chrome/browser/browser.cc (working copy)
@@ -190,6 +190,7 @@
encoding_auto_detect_.Init(prefs::kWebKitUsesUniversalDetector,
profile_->GetPrefs(), NULL);
+ use_vertical_tabs_.Init(prefs::kUseVerticalTabs, profile_->GetPrefs(), this);
}
Browser::~Browser() {
@@ -1521,7 +1522,7 @@
prefs->RegisterBooleanPref(prefs::kWebAppCreateOnDesktop, true);
prefs->RegisterBooleanPref(prefs::kWebAppCreateInAppsMenu, true);
prefs->RegisterBooleanPref(prefs::kWebAppCreateInQuickLaunchBar, true);
- prefs->RegisterBooleanPref(prefs::kUseVerticalTabs, true);
+ prefs->RegisterBooleanPref(prefs::kUseVerticalTabs, false);
prefs->RegisterBooleanPref(prefs::kEnableTranslate, true);
}
@@ -1949,6 +1950,15 @@
BookmarkEditor::SHOW_TREE, NULL);
}
+bool Browser::UseVerticalTabs() const {
+ return use_vertical_tabs_.GetValue();
+}
+
+void Browser::ToggleUseVerticalTabs() {
+ use_vertical_tabs_.SetValue(!UseVerticalTabs());
+ window()->ToggleTabStripMode();
+}
+
///////////////////////////////////////////////////////////////////////////////
// Browser, TabStripModelObserver implementation:

Powered by Google App Engine
This is Rietveld 408576698