OLD | NEW |
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 #ifndef CHROME_BROWSER_FIRST_RUN_FIRST_RUN_INTERNAL_H_ | 5 #ifndef CHROME_BROWSER_FIRST_RUN_FIRST_RUN_INTERNAL_H_ |
6 #define CHROME_BROWSER_FIRST_RUN_FIRST_RUN_INTERNAL_H_ | 6 #define CHROME_BROWSER_FIRST_RUN_FIRST_RUN_INTERNAL_H_ |
7 | 7 |
8 #include <vector> | 8 #include <vector> |
9 | 9 |
10 #include "base/basictypes.h" | 10 #include "base/basictypes.h" |
(...skipping 20 matching lines...) Expand all Loading... |
31 | 31 |
32 enum FirstRunState { | 32 enum FirstRunState { |
33 FIRST_RUN_UNKNOWN, // The state is not tested or set yet. | 33 FIRST_RUN_UNKNOWN, // The state is not tested or set yet. |
34 FIRST_RUN_TRUE, | 34 FIRST_RUN_TRUE, |
35 FIRST_RUN_FALSE | 35 FIRST_RUN_FALSE |
36 }; | 36 }; |
37 | 37 |
38 // This variable should only be accessed through IsChromeFirstRun(). | 38 // This variable should only be accessed through IsChromeFirstRun(). |
39 extern FirstRunState first_run_; | 39 extern FirstRunState first_run_; |
40 | 40 |
41 // The kSentinelFile file absence will tell us it is a first run. | |
42 extern const char* const kSentinelFile; | |
43 | |
44 // Loads master preferences from the master preference file into the installer | 41 // Loads master preferences from the master preference file into the installer |
45 // master preferences. Passes the master preference file path out in | 42 // master preferences. Passes the master preference file path out in |
46 // master_prefs_path. Returns the pointer to installer::MasterPreferences object | 43 // master_prefs_path. Returns the pointer to installer::MasterPreferences object |
47 // if successful; otherwise, returns NULL. | 44 // if successful; otherwise, returns NULL. |
48 installer::MasterPreferences* LoadMasterPrefs(FilePath* master_prefs_path); | 45 installer::MasterPreferences* LoadMasterPrefs(FilePath* master_prefs_path); |
49 | 46 |
50 // Copies user preference file to master preference file. Returns true if | 47 // Copies user preference file to master preference file. Returns true if |
51 // successful. | 48 // successful. |
52 bool CopyPrefFile(const FilePath& user_data_dir, | 49 bool CopyPrefFile(const FilePath& user_data_dir, |
53 const FilePath& master_prefs_path); | 50 const FilePath& master_prefs_path); |
(...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
112 const CommandLine& cmdline); | 109 const CommandLine& cmdline); |
113 | 110 |
114 #if !defined(OS_WIN) | 111 #if !defined(OS_WIN) |
115 bool ImportBookmarks(const FilePath& import_bookmarks_path); | 112 bool ImportBookmarks(const FilePath& import_bookmarks_path); |
116 #endif | 113 #endif |
117 | 114 |
118 } // namespace internal | 115 } // namespace internal |
119 } // namespace first_run | 116 } // namespace first_run |
120 | 117 |
121 #endif // CHROME_BROWSER_FIRST_RUN_FIRST_RUN_INTERNAL_H_ | 118 #endif // CHROME_BROWSER_FIRST_RUN_FIRST_RUN_INTERNAL_H_ |
OLD | NEW |