| 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_NETWORK_SCREEN_HANDLER_H_ | 5 #ifndef CHROME_BROWSER_UI_WEBUI_CHROMEOS_LOGIN_NETWORK_SCREEN_HANDLER_H_ |
| 6 #define CHROME_BROWSER_UI_WEBUI_CHROMEOS_LOGIN_NETWORK_SCREEN_HANDLER_H_ | 6 #define CHROME_BROWSER_UI_WEBUI_CHROMEOS_LOGIN_NETWORK_SCREEN_HANDLER_H_ |
| 7 | 7 |
| 8 #include <memory> | 8 #include <memory> |
| 9 #include <string> | 9 #include <string> |
| 10 | 10 |
| 11 #include "base/compiler_specific.h" | 11 #include "base/compiler_specific.h" |
| 12 #include "base/macros.h" | 12 #include "base/macros.h" |
| 13 #include "chrome/browser/chromeos/base/locale_util.h" | 13 #include "chrome/browser/chromeos/base/locale_util.h" |
| 14 #include "chrome/browser/chromeos/login/screens/network_view.h" | 14 #include "chrome/browser/chromeos/login/screens/network_view.h" |
| 15 #include "chrome/browser/ui/webui/chromeos/login/base_screen_handler.h" | 15 #include "chrome/browser/ui/webui/chromeos/login/base_screen_handler.h" |
| 16 #include "ui/base/ime/chromeos/component_extension_ime_manager.h" | 16 #include "ui/base/ime/chromeos/component_extension_ime_manager.h" |
| 17 #include "ui/base/ime/chromeos/input_method_manager.h" | 17 #include "ui/base/ime/chromeos/input_method_manager.h" |
| 18 #include "ui/gfx/geometry/point.h" | 18 #include "ui/gfx/geometry/point.h" |
| 19 | 19 |
| 20 namespace base { | |
| 21 class ListValue; | |
| 22 } | |
| 23 | |
| 24 namespace chromeos { | 20 namespace chromeos { |
| 25 | 21 |
| 26 class CoreOobeView; | 22 class CoreOobeView; |
| 27 | 23 |
| 28 // WebUI implementation of NetworkScreenView. It is used to interact with | 24 // WebUI implementation of NetworkScreenView. It is used to interact with |
| 29 // the welcome screen (part of the page) of the OOBE. | 25 // the welcome screen (part of the page) of the OOBE. |
| 30 class NetworkScreenHandler : public NetworkView, public BaseScreenHandler { | 26 class NetworkScreenHandler : public NetworkView, public BaseScreenHandler { |
| 31 public: | 27 public: |
| 32 explicit NetworkScreenHandler(CoreOobeView* core_oobe_view); | 28 explicit NetworkScreenHandler(CoreOobeView* core_oobe_view); |
| 33 ~NetworkScreenHandler() override; | 29 ~NetworkScreenHandler() override; |
| (...skipping 11 matching lines...) Expand all Loading... |
| 45 const base::string16& network_id) override; | 41 const base::string16& network_id) override; |
| 46 void ReloadLocalizedContent() override; | 42 void ReloadLocalizedContent() override; |
| 47 | 43 |
| 48 // BaseScreenHandler implementation: | 44 // BaseScreenHandler implementation: |
| 49 void DeclareLocalizedValues( | 45 void DeclareLocalizedValues( |
| 50 ::login::LocalizedValuesBuilder* builder) override; | 46 ::login::LocalizedValuesBuilder* builder) override; |
| 51 void GetAdditionalParameters(base::DictionaryValue* dict) override; | 47 void GetAdditionalParameters(base::DictionaryValue* dict) override; |
| 52 void Initialize() override; | 48 void Initialize() override; |
| 53 | 49 |
| 54 // Returns available timezones. Caller gets the ownership. | 50 // Returns available timezones. Caller gets the ownership. |
| 55 static std::unique_ptr<base::ListValue> GetTimezoneList(); | 51 static base::ListValue* GetTimezoneList(); |
| 56 | 52 |
| 57 CoreOobeView* core_oobe_view_ = nullptr; | 53 CoreOobeView* core_oobe_view_ = nullptr; |
| 58 NetworkScreen* screen_ = nullptr; | 54 NetworkScreen* screen_ = nullptr; |
| 59 | 55 |
| 60 // Keeps whether screen should be shown right after initialization. | 56 // Keeps whether screen should be shown right after initialization. |
| 61 bool show_on_init_ = false; | 57 bool show_on_init_ = false; |
| 62 | 58 |
| 63 // Position of the network control. | 59 // Position of the network control. |
| 64 gfx::Point network_control_pos_; | 60 gfx::Point network_control_pos_; |
| 65 | 61 |
| 66 DISALLOW_COPY_AND_ASSIGN(NetworkScreenHandler); | 62 DISALLOW_COPY_AND_ASSIGN(NetworkScreenHandler); |
| 67 }; | 63 }; |
| 68 | 64 |
| 69 } // namespace chromeos | 65 } // namespace chromeos |
| 70 | 66 |
| 71 #endif // CHROME_BROWSER_UI_WEBUI_CHROMEOS_LOGIN_NETWORK_SCREEN_HANDLER_H_ | 67 #endif // CHROME_BROWSER_UI_WEBUI_CHROMEOS_LOGIN_NETWORK_SCREEN_HANDLER_H_ |
| OLD | NEW |