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

Side by Side Diff: chrome/browser/ui/startup/startup_browser_creator_impl.cc

Issue 13145003: Rewrite std::string("") to std::string(), Linux edition. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Ugh Created 7 years, 8 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "chrome/browser/ui/startup/startup_browser_creator_impl.h" 5 #include "chrome/browser/ui/startup/startup_browser_creator_impl.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <vector> 8 #include <vector>
9 9
10 #include "apps/app_restore_service.h" 10 #include "apps/app_restore_service.h"
(...skipping 915 matching lines...) Expand 10 before | Expand all | Expand 10 after
926 std::vector<GURL>* startup_urls) const { 926 std::vector<GURL>* startup_urls) const {
927 PrefService* prefs = profile_->GetPrefs(); 927 PrefService* prefs = profile_->GetPrefs();
928 bool has_reset_local_passphrase_switch = 928 bool has_reset_local_passphrase_switch =
929 command_line_.HasSwitch(switches::kResetLocalPassphrase); 929 command_line_.HasSwitch(switches::kResetLocalPassphrase);
930 if ((is_first_run_ || has_reset_local_passphrase_switch) && 930 if ((is_first_run_ || has_reset_local_passphrase_switch) &&
931 prefs->GetBoolean(prefs::kProfileIsManaged)) { 931 prefs->GetBoolean(prefs::kProfileIsManaged)) {
932 startup_urls->insert(startup_urls->begin(), 932 startup_urls->insert(startup_urls->begin(),
933 GURL(std::string(chrome::kChromeUISettingsURL) + 933 GURL(std::string(chrome::kChromeUISettingsURL) +
934 chrome::kManagedUserSettingsSubPage)); 934 chrome::kManagedUserSettingsSubPage));
935 if (has_reset_local_passphrase_switch) { 935 if (has_reset_local_passphrase_switch) {
936 prefs->SetString(prefs::kManagedModeLocalPassphrase, ""); 936 prefs->SetString(prefs::kManagedModeLocalPassphrase, std::string());
937 prefs->SetString(prefs::kManagedModeLocalSalt, ""); 937 prefs->SetString(prefs::kManagedModeLocalSalt, std::string());
938 } 938 }
939 } 939 }
940 940
941 // If we have urls specified by the first run master preferences use them 941 // If we have urls specified by the first run master preferences use them
942 // and nothing else. 942 // and nothing else.
943 if (browser_creator_ && startup_urls->empty()) { 943 if (browser_creator_ && startup_urls->empty()) {
944 if (!browser_creator_->first_run_tabs_.empty()) { 944 if (!browser_creator_->first_run_tabs_.empty()) {
945 std::vector<GURL>::iterator it = 945 std::vector<GURL>::iterator it =
946 browser_creator_->first_run_tabs_.begin(); 946 browser_creator_->first_run_tabs_.begin();
947 while (it != browser_creator_->first_run_tabs_.end()) { 947 while (it != browser_creator_->first_run_tabs_.end()) {
(...skipping 22 matching lines...) Expand all
970 } 970 }
971 971
972 #if !defined(OS_WIN) || defined(USE_AURA) 972 #if !defined(OS_WIN) || defined(USE_AURA)
973 // static 973 // static
974 bool StartupBrowserCreatorImpl::OpenStartupURLsInExistingBrowser( 974 bool StartupBrowserCreatorImpl::OpenStartupURLsInExistingBrowser(
975 Profile* profile, 975 Profile* profile,
976 const std::vector<GURL>& startup_urls) { 976 const std::vector<GURL>& startup_urls) {
977 return false; 977 return false;
978 } 978 }
979 #endif 979 #endif
OLDNEW
« no previous file with comments | « chrome/browser/ui/search/instant_browsertest.cc ('k') | chrome/browser/ui/sync/one_click_signin_helper_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698