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

Side by Side Diff: chrome/browser/chromeos/login/startup_utils.h

Issue 1308833004: Show Goodies page to new Chromebook users (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Address reviewer comments Created 5 years, 3 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
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 #ifndef CHROME_BROWSER_CHROMEOS_LOGIN_STARTUP_UTILS_H_ 5 #ifndef CHROME_BROWSER_CHROMEOS_LOGIN_STARTUP_UTILS_H_
6 #define CHROME_BROWSER_CHROMEOS_LOGIN_STARTUP_UTILS_H_ 6 #define CHROME_BROWSER_CHROMEOS_LOGIN_STARTUP_UTILS_H_
7 7
8 #include <string> 8 #include <string>
9 9
10 #include "base/callback.h" 10 #include "base/callback.h"
11 #include "base/files/file_util.h"
achuithb 2015/09/16 03:40:29 file_path.h?
Greg Levin 2015/09/16 16:55:13 Done.
11 12
12 class PrefRegistrySimple; 13 class PrefRegistrySimple;
13 14
14 namespace chromeos { 15 namespace chromeos {
15 16
16 // Static utility methods used at startup time to get/change bits of device 17 // Static utility methods used at startup time to get/change bits of device
17 // state. 18 // state.
18 class StartupUtils { 19 class StartupUtils {
19 public: 20 public:
20 // Returns true if EULA has been accepted. 21 // Returns true if EULA has been accepted.
21 static bool IsEulaAccepted(); 22 static bool IsEulaAccepted();
22 23
23 // Returns OOBE completion status. 24 // Returns OOBE completion status.
24 static bool IsOobeCompleted(); 25 static bool IsOobeCompleted();
25 26
26 // Marks EULA status as accepted. 27 // Marks EULA status as accepted.
27 static void MarkEulaAccepted(); 28 static void MarkEulaAccepted();
28 29
29 // Marks OOBE process as completed. 30 // Marks OOBE process as completed.
30 static void MarkOobeCompleted(); 31 static void MarkOobeCompleted();
31 32
32 // Stores the next pending OOBE screen in case it will need to be resumed. 33 // Stores the next pending OOBE screen in case it will need to be resumed.
33 static void SaveOobePendingScreen(const std::string& screen); 34 static void SaveOobePendingScreen(const std::string& screen);
34 35
36 // Path to flag file indicating oobe completion.
37 static base::FilePath GetOobeCompleteFlagPath();
38
35 // Returns device registration completion status, i.e. second part of OOBE. 39 // Returns device registration completion status, i.e. second part of OOBE.
36 static bool IsDeviceRegistered(); 40 static bool IsDeviceRegistered();
37 41
38 // Marks device registered. i.e. second part of OOBE is completed. 42 // Marks device registered. i.e. second part of OOBE is completed.
39 static void MarkDeviceRegistered(const base::Closure& done_callback); 43 static void MarkDeviceRegistered(const base::Closure& done_callback);
40 44
41 // Mark a device as requiring enrollment recovery. 45 // Mark a device as requiring enrollment recovery.
42 static void MarkEnrollmentRecoveryRequired(); 46 static void MarkEnrollmentRecoveryRequired();
43 47
44 // Returns initial locale from local settings. 48 // Returns initial locale from local settings.
45 static std::string GetInitialLocale(); 49 static std::string GetInitialLocale();
46 50
47 // Sets initial locale in local settings. 51 // Sets initial locale in local settings.
48 static void SetInitialLocale(const std::string& locale); 52 static void SetInitialLocale(const std::string& locale);
49 53
50 // Returns true if webview based signin flow has been activated. 54 // Returns true if webview based signin flow has been activated.
51 static bool IsWebviewSigninEnabled(); 55 static bool IsWebviewSigninEnabled();
52 56
53 // Registers OOBE preferences. 57 // Registers OOBE preferences.
54 static void RegisterPrefs(PrefRegistrySimple* registry); 58 static void RegisterPrefs(PrefRegistrySimple* registry);
55 }; 59 };
56 60
57 } // namespace chromeos 61 } // namespace chromeos
58 62
59 #endif // CHROME_BROWSER_CHROMEOS_LOGIN_STARTUP_UTILS_H_ 63 #endif // CHROME_BROWSER_CHROMEOS_LOGIN_STARTUP_UTILS_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698