OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 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_CHROMEOS_APP_MODE_KIOSK_APP_UPDATE_SERVICE_H_ | 5 #ifndef CHROME_BROWSER_CHROMEOS_APP_MODE_KIOSK_APP_UPDATE_SERVICE_H_ |
6 #define CHROME_BROWSER_CHROMEOS_APP_MODE_KIOSK_APP_UPDATE_SERVICE_H_ | 6 #define CHROME_BROWSER_CHROMEOS_APP_MODE_KIOSK_APP_UPDATE_SERVICE_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 | 9 |
10 #include "base/basictypes.h" | 10 #include "base/basictypes.h" |
11 #include "base/compiler_specific.h" | 11 #include "base/compiler_specific.h" |
12 #include "base/memory/singleton.h" | 12 #include "base/memory/singleton.h" |
13 #include "base/timer.h" | 13 #include "base/timer.h" |
14 #include "chrome/browser/extensions/update_observer.h" | 14 #include "chrome/browser/extensions/update_observer.h" |
15 #include "chrome/browser/profiles/profile_keyed_service.h" | 15 #include "chrome/browser/profiles/profile_keyed_service.h" |
16 #include "chrome/browser/profiles/profile_keyed_service_factory.h" | 16 #include "chrome/browser/profiles/profile_keyed_service_factory.h" |
17 | 17 |
| 18 class Profile; |
| 19 |
18 namespace chromeos { | 20 namespace chromeos { |
19 | 21 |
20 // This class enforces automatic restart on app and Chrome updates in app mode. | 22 // This class enforces automatic restart on app and Chrome updates in app mode. |
21 class KioskAppUpdateService : public ProfileKeyedService, | 23 class KioskAppUpdateService : public ProfileKeyedService, |
22 public extensions::UpdateObserver { | 24 public extensions::UpdateObserver { |
23 public: | 25 public: |
24 explicit KioskAppUpdateService(Profile* profile); | 26 explicit KioskAppUpdateService(Profile* profile); |
25 virtual ~KioskAppUpdateService(); | 27 virtual ~KioskAppUpdateService(); |
26 | 28 |
27 void set_app_id(const std::string& app_id) { app_id_ = app_id; } | 29 void set_app_id(const std::string& app_id) { app_id_ = app_id; } |
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
66 virtual ~KioskAppUpdateServiceFactory(); | 68 virtual ~KioskAppUpdateServiceFactory(); |
67 | 69 |
68 // ProfileKeyedServiceFactory overrides: | 70 // ProfileKeyedServiceFactory overrides: |
69 virtual ProfileKeyedService* BuildServiceInstanceFor( | 71 virtual ProfileKeyedService* BuildServiceInstanceFor( |
70 content::BrowserContext* profile) const OVERRIDE; | 72 content::BrowserContext* profile) const OVERRIDE; |
71 }; | 73 }; |
72 | 74 |
73 } // namespace chromeos | 75 } // namespace chromeos |
74 | 76 |
75 #endif // CHROME_BROWSER_CHROMEOS_APP_MODE_KIOSK_APP_UPDATE_SERVICE_H_ | 77 #endif // CHROME_BROWSER_CHROMEOS_APP_MODE_KIOSK_APP_UPDATE_SERVICE_H_ |
OLD | NEW |