| OLD | NEW |
| 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_MANAGED_MODE_MANAGED_USER_SERVICE_H_ | 5 #ifndef CHROME_BROWSER_MANAGED_MODE_MANAGED_USER_SERVICE_H_ |
| 6 #define CHROME_BROWSER_MANAGED_MODE_MANAGED_USER_SERVICE_H_ | 6 #define CHROME_BROWSER_MANAGED_MODE_MANAGED_USER_SERVICE_H_ |
| 7 | 7 |
| 8 #include <set> | 8 #include <set> |
| 9 #include <vector> | 9 #include <vector> |
| 10 | 10 |
| (...skipping 206 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 217 void UpdateSiteLists(); | 217 void UpdateSiteLists(); |
| 218 | 218 |
| 219 // Updates the manual overrides for hosts in the URL filters when the | 219 // Updates the manual overrides for hosts in the URL filters when the |
| 220 // corresponding preference is changed. | 220 // corresponding preference is changed. |
| 221 void UpdateManualHosts(); | 221 void UpdateManualHosts(); |
| 222 | 222 |
| 223 // Updates the manual overrides for URLs in the URL filters when the | 223 // Updates the manual overrides for URLs in the URL filters when the |
| 224 // corresponding preference is changed. | 224 // corresponding preference is changed. |
| 225 void UpdateManualURLs(); | 225 void UpdateManualURLs(); |
| 226 | 226 |
| 227 // Records some events (opening the managed user profile, switching from the | |
| 228 // managed user profile, and quitting the browser); each is stored | |
| 229 // using a key with a prefix (|key_prefix|) indicating the type of the event. | |
| 230 // Each entry is a dictionary which has the timestamp of the event. | |
| 231 void RecordProfileAndBrowserEventsHelper(const char* key_prefix); | |
| 232 | |
| 233 // Owns us via the KeyedService mechanism. | 227 // Owns us via the KeyedService mechanism. |
| 234 Profile* profile_; | 228 Profile* profile_; |
| 235 | 229 |
| 236 content::NotificationRegistrar registrar_; | 230 content::NotificationRegistrar registrar_; |
| 237 PrefChangeRegistrar pref_change_registrar_; | 231 PrefChangeRegistrar pref_change_registrar_; |
| 238 | 232 |
| 239 // True iff we're waiting for the Sync service to be initialized. | 233 // True iff we're waiting for the Sync service to be initialized. |
| 240 bool waiting_for_sync_initialization_; | 234 bool waiting_for_sync_initialization_; |
| 241 bool is_profile_active_; | 235 bool is_profile_active_; |
| 242 | 236 |
| 243 std::vector<NavigationBlockedCallback> navigation_blocked_callbacks_; | 237 std::vector<NavigationBlockedCallback> navigation_blocked_callbacks_; |
| 244 | 238 |
| 245 // Sets a profile in elevated state for testing if set to true. | 239 // Sets a profile in elevated state for testing if set to true. |
| 246 bool elevated_for_testing_; | 240 bool elevated_for_testing_; |
| 247 | 241 |
| 248 // True only when |Shutdown()| method has been called. | 242 // True only when |Shutdown()| method has been called. |
| 249 bool did_shutdown_; | 243 bool did_shutdown_; |
| 250 | 244 |
| 251 URLFilterContext url_filter_context_; | 245 URLFilterContext url_filter_context_; |
| 252 | 246 |
| 253 base::WeakPtrFactory<ManagedUserService> weak_ptr_factory_; | 247 base::WeakPtrFactory<ManagedUserService> weak_ptr_factory_; |
| 254 }; | 248 }; |
| 255 | 249 |
| 256 #endif // CHROME_BROWSER_MANAGED_MODE_MANAGED_USER_SERVICE_H_ | 250 #endif // CHROME_BROWSER_MANAGED_MODE_MANAGED_USER_SERVICE_H_ |
| OLD | NEW |