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

Side by Side Diff: chrome/browser/importer/importer_list.h

Issue 2106015: Move data types used in the importer process to common/, in preparation for i... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 10 years, 7 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) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2010 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 #ifndef CHROME_BROWSER_IMPORTER_IMPORTER_LIST_H_ 5 #ifndef CHROME_BROWSER_IMPORTER_IMPORTER_LIST_H_
6 #define CHROME_BROWSER_IMPORTER_IMPORTER_LIST_H_ 6 #define CHROME_BROWSER_IMPORTER_IMPORTER_LIST_H_
7 7
8 #include <string> 8 #include <string>
9 #include <vector> 9 #include <vector>
10 10
11 #include "build/build_config.h" 11 #include "build/build_config.h"
12 #include "base/basictypes.h" 12 #include "base/basictypes.h"
13 #include "chrome/browser/importer/importer_data_types.h" 13 #include "chrome/common/importer_data_types.h"
14 14
15 class Importer; 15 class Importer;
16 16
17 class ImporterList { 17 class ImporterList {
18 public: 18 public:
19 ImporterList(); 19 ImporterList();
20 ~ImporterList(); 20 ~ImporterList();
21 21
22 // Detects the installed browsers and their associated profiles, then 22 // Detects the installed browsers and their associated profiles, then
23 // stores their information in a list. It returns the list of description 23 // stores their information in a list. It returns the list of description
24 // of all profiles. 24 // of all profiles.
25 void DetectSourceProfiles(); 25 void DetectSourceProfiles();
26 26
27 Importer* CreateImporterByType(importer::ProfileType type); 27 Importer* CreateImporterByType(importer::ProfileType type);
28 28
29 // Returns the number of different browser profiles you can import from. 29 // Returns the number of different browser profiles you can import from.
30 int GetAvailableProfileCount() const; 30 int GetAvailableProfileCount() const;
31 31
32 // Returns the name of the profile at the 'index' slot. The profiles are 32 // Returns the name of the profile at the 'index' slot. The profiles are
33 // ordered such that the profile at index 0 is the likely default browser. 33 // ordered such that the profile at index 0 is the likely default browser.
34 std::wstring GetSourceProfileNameAt(int index) const; 34 std::wstring GetSourceProfileNameAt(int index) const;
35 35
36 // Returns the ProfileInfo at the specified index. The ProfileInfo should be 36 // Returns the ProfileInfo at the specified index. The ProfileInfo should be
37 // passed to StartImportSettings(). 37 // passed to StartImportSettings().
38 const importer::ProfileInfo& GetSourceProfileInfoAt(int index) const; 38 const importer::ProfileInfo& GetSourceProfileInfoAt(int index) const;
39 39
40 // Returns the ProfileInfo with the given browser type. 40 // Returns the ProfileInfo with the given browser type.
41 const importer::ProfileInfo& GetSourceProfileInfoForBrowserType(int browser_ty pe) const; 41 const importer::ProfileInfo& GetSourceProfileInfoForBrowserType(
42 int browser_type) const;
42 43
43 // Helper methods for detecting available profiles. 44 // Helper methods for detecting available profiles.
44 #if defined(OS_WIN) 45 #if defined(OS_WIN)
45 void DetectIEProfiles(); 46 void DetectIEProfiles();
46 #endif 47 #endif
47 void DetectFirefoxProfiles(); 48 void DetectFirefoxProfiles();
48 void DetectGoogleToolbarProfiles(); 49 void DetectGoogleToolbarProfiles();
49 #if defined(OS_MACOSX) 50 #if defined(OS_MACOSX)
50 void DetectSafariProfiles(); 51 void DetectSafariProfiles();
51 #endif 52 #endif
52 53
53 private: 54 private:
54 // The list of profiles with the default one first. 55 // The list of profiles with the default one first.
55 std::vector<importer::ProfileInfo*> source_profiles_; 56 std::vector<importer::ProfileInfo*> source_profiles_;
56 57
57 DISALLOW_COPY_AND_ASSIGN(ImporterList); 58 DISALLOW_COPY_AND_ASSIGN(ImporterList);
58 }; 59 };
59 60
60 #endif // CHROME_BROWSER_IMPORTER_IMPORTER_LIST_H_ 61 #endif // CHROME_BROWSER_IMPORTER_IMPORTER_LIST_H_
OLDNEW
« no previous file with comments | « chrome/browser/importer/importer_data_types.h ('k') | chrome/browser/importer/importer_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698