| 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 class MasterPrefs; | 8 class MasterPrefs; |
| 9 class Profile; | 9 class Profile; |
| 10 | 10 |
| (...skipping 19 matching lines...) Expand all Loading... |
| 30 extern FirstRunState first_run_; | 30 extern FirstRunState first_run_; |
| 31 | 31 |
| 32 // Sets up master preferences by preferences passed by installer. | 32 // Sets up master preferences by preferences passed by installer. |
| 33 void SetupMasterPrefsFromInstallPrefs( | 33 void SetupMasterPrefsFromInstallPrefs( |
| 34 const installer::MasterPreferences& install_prefs, | 34 const installer::MasterPreferences& install_prefs, |
| 35 MasterPrefs* out_prefs); | 35 MasterPrefs* out_prefs); |
| 36 | 36 |
| 37 // Creates the sentinel file that signals that chrome has been configured. | 37 // Creates the sentinel file that signals that chrome has been configured. |
| 38 bool CreateSentinel(); | 38 bool CreateSentinel(); |
| 39 | 39 |
| 40 // Gives the full path to the sentinel file. The file might not exist. |
| 41 bool GetFirstRunSentinelFilePath(base::FilePath* path); |
| 42 |
| 40 // -- Platform-specific functions -- | 43 // -- Platform-specific functions -- |
| 41 | 44 |
| 42 void DoPostImportPlatformSpecificTasks(Profile* profile); | 45 void DoPostImportPlatformSpecificTasks(Profile* profile); |
| 43 | 46 |
| 44 // Gives the full path to the sentinel file. The file might not exist. | |
| 45 // This function has a common implementation on OS_POSIX and a windows specific | |
| 46 // implementation. | |
| 47 bool GetFirstRunSentinelFilePath(base::FilePath* path); | |
| 48 | |
| 49 // Populates |path| with the old path to first run sentinel for the current | 47 // Populates |path| with the old path to first run sentinel for the current |
| 50 // configuration. Returns true if there is a legacy path for this configuration | 48 // configuration. Returns true if there is a legacy path for this configuration |
| 51 // and it could be obtained. | 49 // and it could be obtained. |
| 52 bool GetLegacyFirstRunSentinelFilePath(base::FilePath* path); | 50 bool GetLegacyFirstRunSentinelFilePath(base::FilePath* path); |
| 53 | 51 |
| 54 // This function has a common implementationin for all non-linux platforms, and | 52 // This function has a common implementationin for all non-linux platforms, and |
| 55 // a linux specific implementation. | 53 // a linux specific implementation. |
| 56 bool IsOrganicFirstRun(); | 54 bool IsOrganicFirstRun(); |
| 57 | 55 |
| 58 // Shows the EULA dialog if required. Returns true if the EULA is accepted, | 56 // Shows the EULA dialog if required. Returns true if the EULA is accepted, |
| 59 // returns false if the EULA has not been accepted, in which case the browser | 57 // returns false if the EULA has not been accepted, in which case the browser |
| 60 // should exit. | 58 // should exit. |
| 61 bool ShowPostInstallEULAIfNeeded(installer::MasterPreferences* install_prefs); | 59 bool ShowPostInstallEULAIfNeeded(installer::MasterPreferences* install_prefs); |
| 62 | 60 |
| 63 // Returns the path for the master preferences file. | 61 // Returns the path for the master preferences file. |
| 64 base::FilePath MasterPrefsPath(); | 62 base::FilePath MasterPrefsPath(); |
| 65 | 63 |
| 66 } // namespace internal | 64 } // namespace internal |
| 67 } // namespace first_run | 65 } // namespace first_run |
| 68 | 66 |
| 69 #endif // CHROME_BROWSER_FIRST_RUN_FIRST_RUN_INTERNAL_H_ | 67 #endif // CHROME_BROWSER_FIRST_RUN_FIRST_RUN_INTERNAL_H_ |
| OLD | NEW |