OLD | NEW |
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_UI_WEBUI_CHROMEOS_LOGIN_UPDATE_SCREEN_HANDLER_H_ | 5 #ifndef CHROME_BROWSER_UI_WEBUI_CHROMEOS_LOGIN_UPDATE_SCREEN_HANDLER_H_ |
6 #define CHROME_BROWSER_UI_WEBUI_CHROMEOS_LOGIN_UPDATE_SCREEN_HANDLER_H_ | 6 #define CHROME_BROWSER_UI_WEBUI_CHROMEOS_LOGIN_UPDATE_SCREEN_HANDLER_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 | 9 |
10 #include "base/compiler_specific.h" | 10 #include "base/compiler_specific.h" |
11 #include "chrome/browser/chromeos/login/screens/update_screen_actor.h" | 11 #include "chrome/browser/chromeos/login/screens/update_screen_actor.h" |
12 #include "chrome/browser/ui/webui/chromeos/login/base_screen_handler.h" | 12 #include "chrome/browser/ui/webui/chromeos/login/base_screen_handler.h" |
13 #include "chrome/browser/ui/webui/chromeos/login/network_dropdown_handler.h" | 13 #include "chrome/browser/ui/webui/chromeos/login/network_dropdown_handler.h" |
14 | 14 |
15 namespace chromeos { | 15 namespace chromeos { |
16 | 16 |
17 class UpdateScreenHandler : public UpdateScreenActor, | 17 class UpdateScreenHandler : public UpdateScreenActor, |
18 public BaseScreenHandler, | 18 public BaseScreenHandler, |
19 public NetworkDropdownHandler::Observer { | 19 public NetworkDropdownHandler::Observer { |
20 public: | 20 public: |
21 UpdateScreenHandler(); | 21 UpdateScreenHandler(); |
22 virtual ~UpdateScreenHandler(); | 22 virtual ~UpdateScreenHandler(); |
23 | 23 |
24 // BaseScreenHandler implementation: | 24 // BaseScreenHandler implementation: |
25 virtual void DeclareLocalizedValues(LocalizedValuesBuilder* builder) OVERRIDE; | 25 virtual void DeclareLocalizedValues(LocalizedValuesBuilder* builder) override; |
26 virtual void Initialize() OVERRIDE; | 26 virtual void Initialize() override; |
27 | 27 |
28 // UpdateScreenActor implementation: | 28 // UpdateScreenActor implementation: |
29 virtual void SetDelegate(UpdateScreenActor::Delegate* screen) OVERRIDE; | 29 virtual void SetDelegate(UpdateScreenActor::Delegate* screen) override; |
30 virtual void Show() OVERRIDE; | 30 virtual void Show() override; |
31 virtual void Hide() OVERRIDE; | 31 virtual void Hide() override; |
32 virtual void PrepareToShow() OVERRIDE; | 32 virtual void PrepareToShow() override; |
33 virtual void ShowManualRebootInfo() OVERRIDE; | 33 virtual void ShowManualRebootInfo() override; |
34 virtual void SetProgress(int progress) OVERRIDE; | 34 virtual void SetProgress(int progress) override; |
35 virtual void ShowEstimatedTimeLeft(bool visible) OVERRIDE; | 35 virtual void ShowEstimatedTimeLeft(bool visible) override; |
36 virtual void SetEstimatedTimeLeft(const base::TimeDelta& time) OVERRIDE; | 36 virtual void SetEstimatedTimeLeft(const base::TimeDelta& time) override; |
37 virtual void ShowProgressMessage(bool visible) OVERRIDE; | 37 virtual void ShowProgressMessage(bool visible) override; |
38 virtual void SetProgressMessage(ProgressMessage message) OVERRIDE; | 38 virtual void SetProgressMessage(ProgressMessage message) override; |
39 virtual void ShowCurtain(bool visible) OVERRIDE; | 39 virtual void ShowCurtain(bool visible) override; |
40 | 40 |
41 // WebUIMessageHandler implementation: | 41 // WebUIMessageHandler implementation: |
42 virtual void RegisterMessages() OVERRIDE; | 42 virtual void RegisterMessages() override; |
43 | 43 |
44 private: | 44 private: |
45 // NetworkDropdownHandler::Observer implementation: | 45 // NetworkDropdownHandler::Observer implementation: |
46 virtual void OnConnectToNetworkRequested() OVERRIDE; | 46 virtual void OnConnectToNetworkRequested() override; |
47 | 47 |
48 #if !defined(OFFICIAL_BUILD) | 48 #if !defined(OFFICIAL_BUILD) |
49 // Called when user presses Escape to cancel update. | 49 // Called when user presses Escape to cancel update. |
50 void HandleUpdateCancel(); | 50 void HandleUpdateCancel(); |
51 #endif | 51 #endif |
52 | 52 |
53 UpdateScreenActor::Delegate* screen_; | 53 UpdateScreenActor::Delegate* screen_; |
54 | 54 |
55 // Keeps whether screen should be shown right after initialization. | 55 // Keeps whether screen should be shown right after initialization. |
56 bool show_on_init_; | 56 bool show_on_init_; |
57 | 57 |
58 DISALLOW_COPY_AND_ASSIGN(UpdateScreenHandler); | 58 DISALLOW_COPY_AND_ASSIGN(UpdateScreenHandler); |
59 }; | 59 }; |
60 | 60 |
61 } // namespace chromeos | 61 } // namespace chromeos |
62 | 62 |
63 #endif // CHROME_BROWSER_UI_WEBUI_CHROMEOS_LOGIN_UPDATE_SCREEN_HANDLER_H_ | 63 #endif // CHROME_BROWSER_UI_WEBUI_CHROMEOS_LOGIN_UPDATE_SCREEN_HANDLER_H_ |
OLD | NEW |