| Index: chrome/browser/ui/browser.cc
|
| ===================================================================
|
| --- chrome/browser/ui/browser.cc (revision 72629)
|
| +++ chrome/browser/ui/browser.cc (working copy)
|
| @@ -223,8 +223,6 @@
|
| printing_enabled_.Init(prefs::kPrintingEnabled, local_state, this);
|
| dev_tools_disabled_.Init(prefs::kDevToolsDisabled,
|
| profile_->GetPrefs(), this);
|
| - incognito_mode_allowed_.Init(prefs::kIncognitoEnabled,
|
| - profile_->GetPrefs(), this);
|
|
|
| InitCommandState();
|
| BrowserList::AddBrowser(this);
|
| @@ -1307,8 +1305,7 @@
|
|
|
| void Browser::NewWindow() {
|
| if (browser_defaults::kAlwaysOpenIncognitoWindow &&
|
| - CommandLine::ForCurrentProcess()->HasSwitch(switches::kIncognito) &&
|
| - incognito_mode_allowed_.GetValue()) {
|
| + CommandLine::ForCurrentProcess()->HasSwitch(switches::kIncognito)) {
|
| NewIncognitoWindow();
|
| return;
|
| }
|
| @@ -1322,11 +1319,6 @@
|
| }
|
|
|
| void Browser::NewIncognitoWindow() {
|
| - if (!incognito_mode_allowed_.GetValue()) {
|
| - NewWindow();
|
| - return;
|
| - }
|
| -
|
| UserMetrics::RecordAction(UserMetricsAction("NewIncognitoWindow"), profile_);
|
| Browser::OpenEmptyWindow(profile_->GetOffTheRecordProfile());
|
| }
|
| @@ -1950,7 +1942,7 @@
|
| switches::kDisableTabbedOptions)) {
|
| ShowOptionsTab(chrome::kLanguageOptionsSubPage);
|
| } else {
|
| - // Language options dialog has been replaced by DOMUI.
|
| + // Language options dialog has been replaced by DOMUI.
|
| }
|
| }
|
|
|
| @@ -2046,7 +2038,6 @@
|
| prefs->RegisterBooleanPref(prefs::kRemotingHasSetupCompleted, false);
|
| prefs->RegisterStringPref(prefs::kCloudPrintEmail, std::string());
|
| prefs->RegisterBooleanPref(prefs::kDevToolsDisabled, false);
|
| - prefs->RegisterBooleanPref(prefs::kIncognitoEnabled, true);
|
| prefs->RegisterRealPref(prefs::kDefaultZoomLevel, 0.0);
|
| prefs->RegisterIntegerPref(prefs::kMultipleProfilePrefMigration, 0);
|
| // We need to register the type of this preference in order to query
|
| @@ -3450,8 +3441,7 @@
|
|
|
| // Window management commands
|
| command_updater_.UpdateCommandEnabled(IDC_NEW_WINDOW, true);
|
| - command_updater_.UpdateCommandEnabled(IDC_NEW_INCOGNITO_WINDOW,
|
| - incognito_mode_allowed_.GetValue());
|
| + command_updater_.UpdateCommandEnabled(IDC_NEW_INCOGNITO_WINDOW, true);
|
| command_updater_.UpdateCommandEnabled(IDC_CLOSE_WINDOW, true);
|
| command_updater_.UpdateCommandEnabled(IDC_NEW_TAB, true);
|
| command_updater_.UpdateCommandEnabled(IDC_CLOSE_TAB, true);
|
|
|