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

Unified Diff: chrome/browser/chrome_browser_main.cc

Issue 12670013: Out-of-process import on Windows. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Keep Google Toolbar import in-process. 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/chrome_browser_main.cc
diff --git a/chrome/browser/chrome_browser_main.cc b/chrome/browser/chrome_browser_main.cc
index 38c42ab7d7a98b9348ec8866a08de352a80b4d02..ce0f5f760336ecc71eecf3c569d15c6874701529 100644
--- a/chrome/browser/chrome_browser_main.cc
+++ b/chrome/browser/chrome_browser_main.cc
@@ -754,9 +754,7 @@ int ChromeBrowserMainParts::PreCreateThreadsImpl() {
(!force_first_run &&
parsed_command_line().HasSwitch(switches::kNoFirstRun));
- is_first_run =
- (force_first_run || first_run::IsChromeFirstRun()) &&
- !ProfileManager::IsImportProcess(parsed_command_line());
+ is_first_run = force_first_run || first_run::IsChromeFirstRun();
#endif
scoped_refptr<base::SequencedTaskRunner> local_state_task_runner =
@@ -1100,19 +1098,9 @@ int ChromeBrowserMainParts::PreMainMessageLoopRunImpl() {
return chrome::RESULT_CODE_PACK_EXTENSION_ERROR;
}
- bool pass_command_line = true;
-
-#if !defined(OS_MACOSX)
- // In environments other than Mac OS X we support import of settings
- // from other browsers. In case this process is a short-lived "import"
- // process that another browser runs just to import the settings, we
- // don't want to be checking for another browser process, by design.
- pass_command_line = !ProfileManager::IsImportProcess(parsed_command_line());
-#endif
-
// If we're being launched just to check the connector policy, we are
// short-lived and don't want to be passing that switch off.
- pass_command_line = pass_command_line && !parsed_command_line().HasSwitch(
+ bool pass_command_line = !parsed_command_line().HasSwitch(
switches::kCheckCloudPrintConnectorPolicy);
if (pass_command_line) {
@@ -1216,16 +1204,6 @@ int ChromeBrowserMainParts::PreMainMessageLoopRunImpl() {
#endif
// Post-profile init ---------------------------------------------------------
-#if !defined(OS_MACOSX) && !defined(OS_ANDROID)
- // Importing other browser settings is done in a browser-like process
- // that exits when this task has finished.
- // TODO(port): Port the Mac's IPC-based implementation to other platforms to
- // replace this implementation. http://crbug.com/22142
- if (ProfileManager::IsImportProcess(parsed_command_line())) {
- return first_run::ImportNow(profile_, parsed_command_line());
- }
-#endif
-
#if defined(OS_WIN)
// Do the tasks if chrome has been upgraded while it was last running.
if (!already_running && upgrade_util::DoUpgradeTasks(parsed_command_line()))
@@ -1281,7 +1259,9 @@ int ChromeBrowserMainParts::PreMainMessageLoopRunImpl() {
first_run::AutoImport(profile_,
master_prefs_->homepage_defined,
master_prefs_->do_import_items,
- master_prefs_->dont_import_items);
+ master_prefs_->dont_import_items,
+ master_prefs_->import_bookmarks_path);
+
// Note: this can pop the first run consent dialog on linux.
first_run::DoPostImportTasks(profile_, master_prefs_->make_chrome_default);
« no previous file with comments | « no previous file | chrome/browser/extensions/extension_service.cc » ('j') | chrome/browser/ui/webui/options/import_data_handler.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698