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

Side by Side Diff: chrome/browser/prefs/session_startup_pref.h

Issue 9748016: [protector] Added UI for invalid Preferences backup case. (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Fix unit-test. Created 8 years, 9 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
« no previous file with comments | « chrome/app/generated_resources.grd ('k') | chrome/browser/prefs/session_startup_pref.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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_PREFS_SESSION_STARTUP_PREF_H__ 5 #ifndef CHROME_BROWSER_PREFS_SESSION_STARTUP_PREF_H__
6 #define CHROME_BROWSER_PREFS_SESSION_STARTUP_PREF_H__ 6 #define CHROME_BROWSER_PREFS_SESSION_STARTUP_PREF_H__
7 #pragma once 7 #pragma once
8 8
9 #include <vector> 9 #include <vector>
10 10
(...skipping 18 matching lines...) Expand all
29 // Indicates the user wants to restore a specific set of URLs. The URLs 29 // Indicates the user wants to restore a specific set of URLs. The URLs
30 // are contained in urls. 30 // are contained in urls.
31 URLS, 31 URLS,
32 32
33 // Number of values in this enum. 33 // Number of values in this enum.
34 TYPE_COUNT 34 TYPE_COUNT
35 }; 35 };
36 36
37 static void RegisterUserPrefs(PrefService* prefs); 37 static void RegisterUserPrefs(PrefService* prefs);
38 38
39 // Returns the default value for |type|.
40 static Type GetDefaultStartupType();
41
39 // What should happen on startup for the specified profile. 42 // What should happen on startup for the specified profile.
40 static void SetStartupPref(Profile* profile, const SessionStartupPref& pref); 43 static void SetStartupPref(Profile* profile, const SessionStartupPref& pref);
41 static void SetStartupPref(PrefService* prefs, 44 static void SetStartupPref(PrefService* prefs,
42 const SessionStartupPref& pref); 45 const SessionStartupPref& pref);
43 static SessionStartupPref GetStartupPref(Profile* profile); 46 static SessionStartupPref GetStartupPref(Profile* profile);
44 static SessionStartupPref GetStartupPref(PrefService* prefs); 47 static SessionStartupPref GetStartupPref(PrefService* prefs);
45 48
46 // Whether the startup type and URLs are managed via policy. 49 // Whether the startup type and URLs are managed via policy.
47 static bool TypeIsManaged(PrefService* prefs); 50 static bool TypeIsManaged(PrefService* prefs);
48 static bool URLsAreManaged(PrefService* prefs); 51 static bool URLsAreManaged(PrefService* prefs);
(...skipping 13 matching lines...) Expand all
62 ~SessionStartupPref(); 65 ~SessionStartupPref();
63 66
64 // What to do on startup. 67 // What to do on startup.
65 Type type; 68 Type type;
66 69
67 // The URLs to restore. Only used if type == URLS. 70 // The URLs to restore. Only used if type == URLS.
68 std::vector<GURL> urls; 71 std::vector<GURL> urls;
69 }; 72 };
70 73
71 #endif // CHROME_BROWSER_PREFS_SESSION_STARTUP_PREF_H__ 74 #endif // CHROME_BROWSER_PREFS_SESSION_STARTUP_PREF_H__
OLDNEW
« no previous file with comments | « chrome/app/generated_resources.grd ('k') | chrome/browser/prefs/session_startup_pref.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698