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

Side by Side Diff: chrome/utility/profile_import_handler.h

Issue 10777012: Disable uses of ProfileImportProcess on Android. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix build error on Clang Created 8 years, 5 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
(Empty)
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
3 // found in the LICENSE file.
4
5 #ifndef CHROME_UTILITY_PROFILE_IMPORT_HANDLER_H_
6 #define CHROME_UTILITY_PROFILE_IMPORT_HANDLER_H_
7
8 #include "base/basictypes.h"
9 #include "base/compiler_specific.h"
10 #include "base/memory/ref_counted.h"
11 #include "base/memory/scoped_ptr.h"
12 #include "ipc/ipc_listener.h"
13
14 class ExternalProcessImporterBridge;
15 class Importer;
16
17 namespace base {
18 class DictionaryValue;
19 class Thread;
20 }
21
22 namespace importer {
23 struct SourceProfile;
24 }
25
26 namespace chrome {
27
28 // Dispatches IPCs for out of process profile import.
29 class ProfileImportHandler : public IPC::Listener {
30 public:
31 ProfileImportHandler();
32 virtual ~ProfileImportHandler();
33
34 // IPC::Listener:
35 virtual bool OnMessageReceived(const IPC::Message& message) OVERRIDE;
36
37 private:
38 void OnImportStart(
39 const importer::SourceProfile& source_profile,
40 uint16 items,
41 const base::DictionaryValue& localized_strings);
42 void OnImportCancel();
43 void OnImportItemFinished(uint16 item);
44
45 // The following are used with out of process profile import:
46 void ImporterCleanup();
47
48 static bool Send(IPC::Message* message);
49
50 // Thread that importer runs on, while ProfileImportThread handles messages
51 // from the browser process.
52 scoped_ptr<base::Thread> import_thread_;
53
54 // Bridge object is passed to importer, so that it can send IPC calls
55 // directly back to the ProfileImportProcessHost.
56 scoped_refptr<ExternalProcessImporterBridge> bridge_;
57
58 // A bitmask of importer::ImportItem.
59 uint16 items_to_import_;
60
61 // Importer of the appropriate type (Firefox, Safari, IE, etc.)
62 scoped_refptr<Importer> importer_;
63 };
64
65 } // namespace chrome
66
67 #endif // CHROME_UTILITY_PROFILE_IMPORT_HANDLER_H_
OLDNEW
« no previous file with comments | « chrome/utility/chrome_content_utility_client.cc ('k') | chrome/utility/profile_import_handler.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698