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

Side by Side Diff: chrome/browser/importer/external_process_importer_client.cc

Issue 17379006: OOP import on Linux (i.e., on all platforms since Linux is the only one left!). (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 6 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/importer/external_process_importer_client.h" 5 #include "chrome/browser/importer/external_process_importer_client.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/strings/string_number_conversions.h" 8 #include "base/strings/string_number_conversions.h"
9 #include "chrome/browser/bookmarks/imported_bookmark_entry.h" 9 #include "chrome/browser/bookmarks/imported_bookmark_entry.h"
10 #include "chrome/browser/browser_process.h" 10 #include "chrome/browser/browser_process.h"
(...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after
57 cancelled_ = true; 57 cancelled_ = true;
58 BrowserThread::PostTask( 58 BrowserThread::PostTask(
59 BrowserThread::IO, FROM_HERE, 59 BrowserThread::IO, FROM_HERE,
60 base::Bind( 60 base::Bind(
61 &ExternalProcessImporterClient::CancelImportProcessOnIOThread, 61 &ExternalProcessImporterClient::CancelImportProcessOnIOThread,
62 this)); 62 this));
63 Release(); 63 Release();
64 } 64 }
65 65
66 void ExternalProcessImporterClient::OnProcessCrashed(int exit_code) { 66 void ExternalProcessImporterClient::OnProcessCrashed(int exit_code) {
67 DLOG(ERROR) << __FUNCTION__;
gab 2013/06/19 20:06:03 Also adding this as it helped me when debugging to
67 if (cancelled_) 68 if (cancelled_)
68 return; 69 return;
69 70
70 process_importer_host_->Cancel(); 71 process_importer_host_->Cancel();
71 } 72 }
72 73
73 bool ExternalProcessImporterClient::OnMessageReceived( 74 bool ExternalProcessImporterClient::OnMessageReceived(
74 const IPC::Message& message) { 75 const IPC::Message& message) {
75 bool handled = true; 76 bool handled = true;
76 IPC_BEGIN_MESSAGE_MAP(ExternalProcessImporterClient, message) 77 IPC_BEGIN_MESSAGE_MAP(ExternalProcessImporterClient, message)
(...skipping 216 matching lines...) Expand 10 before | Expand all | Expand 10 after
293 localized_strings.SetString( 294 localized_strings.SetString(
294 base::IntToString(IDS_IMPORT_FROM_SAFARI), 295 base::IntToString(IDS_IMPORT_FROM_SAFARI),
295 l10n_util::GetStringUTF8(IDS_IMPORT_FROM_SAFARI)); 296 l10n_util::GetStringUTF8(IDS_IMPORT_FROM_SAFARI));
296 localized_strings.SetString( 297 localized_strings.SetString(
297 base::IntToString(IDS_BOOKMARK_BAR_FOLDER_NAME), 298 base::IntToString(IDS_BOOKMARK_BAR_FOLDER_NAME),
298 l10n_util::GetStringUTF8(IDS_BOOKMARK_BAR_FOLDER_NAME)); 299 l10n_util::GetStringUTF8(IDS_BOOKMARK_BAR_FOLDER_NAME));
299 300
300 utility_process_host_->Send(new ProfileImportProcessMsg_StartImport( 301 utility_process_host_->Send(new ProfileImportProcessMsg_StartImport(
301 source_profile_, items_, localized_strings)); 302 source_profile_, items_, localized_strings));
302 } 303 }
OLDNEW
« no previous file with comments | « chrome/browser/first_run/first_run.cc ('k') | chrome/browser/importer/firefox_importer_browsertest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698