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

Side by Side Diff: chrome/browser/profile_resetter/profile_resetter.h

Issue 1548133002: Switch to standard integer types in chrome/browser/, part 3 of 4. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 12 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) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2013 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_PROFILE_RESETTER_PROFILE_RESETTER_H_ 5 #ifndef CHROME_BROWSER_PROFILE_RESETTER_PROFILE_RESETTER_H_
6 #define CHROME_BROWSER_PROFILE_RESETTER_PROFILE_RESETTER_H_ 6 #define CHROME_BROWSER_PROFILE_RESETTER_PROFILE_RESETTER_H_
7 7
8 #include <stdint.h>
9
8 #include <utility> 10 #include <utility>
9 #include <vector> 11 #include <vector>
10 12
11 #include "base/basictypes.h"
12 #include "base/callback.h" 13 #include "base/callback.h"
13 #include "base/files/file_path.h" 14 #include "base/files/file_path.h"
15 #include "base/macros.h"
14 #include "base/memory/ref_counted.h" 16 #include "base/memory/ref_counted.h"
15 #include "base/memory/scoped_ptr.h" 17 #include "base/memory/scoped_ptr.h"
16 #include "base/memory/weak_ptr.h" 18 #include "base/memory/weak_ptr.h"
17 #include "base/strings/string16.h" 19 #include "base/strings/string16.h"
18 #include "base/threading/non_thread_safe.h" 20 #include "base/threading/non_thread_safe.h"
19 #include "chrome/browser/browsing_data/browsing_data_remover.h" 21 #include "chrome/browser/browsing_data/browsing_data_remover.h"
20 #include "chrome/browser/profile_resetter/brandcoded_default_settings.h" 22 #include "chrome/browser/profile_resetter/brandcoded_default_settings.h"
21 #include "components/search_engines/template_url_service.h" 23 #include "components/search_engines/template_url_service.h"
22 24
23 class Profile; 25 class Profile;
(...skipping 19 matching lines...) Expand all
43 PINNED_TABS = 1 << 6, 45 PINNED_TABS = 1 << 6,
44 SHORTCUTS = 1 << 7, 46 SHORTCUTS = 1 << 7,
45 // Update ALL if you add new values and check whether the type of 47 // Update ALL if you add new values and check whether the type of
46 // ResettableFlags needs to be enlarged. 48 // ResettableFlags needs to be enlarged.
47 ALL = DEFAULT_SEARCH_ENGINE | HOMEPAGE | CONTENT_SETTINGS | 49 ALL = DEFAULT_SEARCH_ENGINE | HOMEPAGE | CONTENT_SETTINGS |
48 COOKIES_AND_SITE_DATA | EXTENSIONS | STARTUP_PAGES | PINNED_TABS | 50 COOKIES_AND_SITE_DATA | EXTENSIONS | STARTUP_PAGES | PINNED_TABS |
49 SHORTCUTS 51 SHORTCUTS
50 }; 52 };
51 53
52 // Bit vector for Resettable enum. 54 // Bit vector for Resettable enum.
53 typedef uint32 ResettableFlags; 55 typedef uint32_t ResettableFlags;
54 56
55 static_assert(sizeof(ResettableFlags) == sizeof(Resettable), 57 static_assert(sizeof(ResettableFlags) == sizeof(Resettable),
56 "ResettableFlags should be the same size as Resettable"); 58 "ResettableFlags should be the same size as Resettable");
57 59
58 explicit ProfileResetter(Profile* profile); 60 explicit ProfileResetter(Profile* profile);
59 ~ProfileResetter() override; 61 ~ProfileResetter() override;
60 62
61 // Resets |resettable_flags| and calls |callback| on the UI thread on 63 // Resets |resettable_flags| and calls |callback| on the UI thread on
62 // completion. |default_settings| allows the caller to specify some default 64 // completion. |default_settings| allows the caller to specify some default
63 // settings. |default_settings| shouldn't be NULL. 65 // settings. |default_settings| shouldn't be NULL.
(...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after
114 116
115 typedef base::RefCountedData<base::CancellationFlag> SharedCancellationFlag; 117 typedef base::RefCountedData<base::CancellationFlag> SharedCancellationFlag;
116 118
117 // On Windows returns all the shortcuts which launch Chrome and corresponding 119 // On Windows returns all the shortcuts which launch Chrome and corresponding
118 // arguments. |cancel| can be passed to abort the operation earlier. 120 // arguments. |cancel| can be passed to abort the operation earlier.
119 // Call on FILE thread. 121 // Call on FILE thread.
120 std::vector<ShortcutCommand> GetChromeLaunchShortcuts( 122 std::vector<ShortcutCommand> GetChromeLaunchShortcuts(
121 const scoped_refptr<SharedCancellationFlag>& cancel); 123 const scoped_refptr<SharedCancellationFlag>& cancel);
122 124
123 #endif // CHROME_BROWSER_PROFILE_RESETTER_PROFILE_RESETTER_H_ 125 #endif // CHROME_BROWSER_PROFILE_RESETTER_PROFILE_RESETTER_H_
OLDNEW
« no previous file with comments | « chrome/browser/profile_resetter/brandcoded_default_settings.h ('k') | chrome/browser/profile_resetter/profile_resetter.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698