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

Side by Side Diff: chrome/browser/first_run/first_run_win.cc

Issue 11572036: Do not load extension system in the Profile import process. (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: cleanups Created 8 years 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
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/first_run/first_run.h" 5 #include "chrome/browser/first_run/first_run.h"
6 6
7 #include <shellapi.h> 7 #include <shellapi.h>
8 #include <shlobj.h> 8 #include <shlobj.h>
9 #include <windows.h> 9 #include <windows.h>
10 10
(...skipping 320 matching lines...) Expand 10 before | Expand all | Expand 10 after
331 switches::kCountry, 331 switches::kCountry,
332 }; 332 };
333 import_cmd.CopySwitchesFrom(cmdline, kSwitchNames, arraysize(kSwitchNames)); 333 import_cmd.CopySwitchesFrom(cmdline, kSwitchNames, arraysize(kSwitchNames));
334 334
335 // Since ImportSettings is called before the local state is stored on disk 335 // Since ImportSettings is called before the local state is stored on disk
336 // we pass the language as an argument. GetApplicationLocale checks the 336 // we pass the language as an argument. GetApplicationLocale checks the
337 // current command line as fallback. 337 // current command line as fallback.
338 import_cmd.AppendSwitchASCII(switches::kLang, 338 import_cmd.AppendSwitchASCII(switches::kLang,
339 g_browser_process->GetApplicationLocale()); 339 g_browser_process->GetApplicationLocale());
340 340
341 // Always run BrowserMain, even in tests.
342 import_cmd.AppendSwitch(switches::kLaunchAsBrowser);
343
341 if (items_to_import) { 344 if (items_to_import) {
342 import_cmd.AppendSwitchASCII(switches::kImport, 345 import_cmd.AppendSwitchASCII(switches::kImport,
343 EncodeImportParams(importer_type, items_to_import, skip_first_run_ui)); 346 EncodeImportParams(importer_type, items_to_import, skip_first_run_ui));
344 } 347 }
345 348
346 if (!import_bookmarks_path.empty()) { 349 if (!import_bookmarks_path.empty()) {
347 import_cmd.AppendSwitchPath(switches::kImportFromFile, 350 import_cmd.AppendSwitchPath(switches::kImportFromFile,
348 import_bookmarks_path); 351 import_bookmarks_path);
349 } 352 }
350 353
(...skipping 152 matching lines...) Expand 10 before | Expand all | Expand 10 after
503 506
504 FilePath MasterPrefsPath() { 507 FilePath MasterPrefsPath() {
505 // The standard location of the master prefs is next to the chrome binary. 508 // The standard location of the master prefs is next to the chrome binary.
506 FilePath master_prefs; 509 FilePath master_prefs;
507 if (!PathService::Get(base::DIR_EXE, &master_prefs)) 510 if (!PathService::Get(base::DIR_EXE, &master_prefs))
508 return FilePath(); 511 return FilePath();
509 return master_prefs.AppendASCII(installer::kDefaultMasterPrefs); 512 return master_prefs.AppendASCII(installer::kDefaultMasterPrefs);
510 } 513 }
511 514
512 } // namespace first_run 515 } // namespace first_run
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698