| 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_CHROMEOS_LOGIN_SCREENS_NETWORK_ERROR_VIEW_H_ | 5 #ifndef CHROME_BROWSER_CHROMEOS_LOGIN_SCREENS_NETWORK_ERROR_VIEW_H_ |
| 6 #define CHROME_BROWSER_CHROMEOS_LOGIN_SCREENS_NETWORK_ERROR_VIEW_H_ | 6 #define CHROME_BROWSER_CHROMEOS_LOGIN_SCREENS_NETWORK_ERROR_VIEW_H_ |
| 7 | 7 |
| 8 #include "base/strings/string16.h" | 8 #include "base/strings/string16.h" |
| 9 #include "chrome/browser/chromeos/login/oobe_screen.h" | 9 #include "chrome/browser/chromeos/login/oobe_screen.h" |
| 10 | 10 |
| 11 namespace chromeos { | 11 namespace chromeos { |
| 12 | 12 |
| 13 class ErrorScreen; | 13 class ErrorScreen; |
| 14 | 14 |
| 15 // Interface for dependency injection between ErrorScreen and its actual | 15 // Interface for dependency injection between ErrorScreen and its actual |
| 16 // representation. Owned by ErrorScreen. | 16 // representation. Owned by ErrorScreen. |
| 17 class NetworkErrorView { | 17 class NetworkErrorView { |
| 18 public: | 18 public: |
| 19 constexpr static OobeScreen kScreenId = OobeScreen::SCREEN_ERROR_MESSAGE; |
| 20 |
| 19 virtual ~NetworkErrorView() {} | 21 virtual ~NetworkErrorView() {} |
| 20 | 22 |
| 21 // Shows the contents of the screen. | 23 // Shows the contents of the screen. |
| 22 virtual void Show() = 0; | 24 virtual void Show() = 0; |
| 23 | 25 |
| 24 // Hides the contents of the screen. | 26 // Hides the contents of the screen. |
| 25 virtual void Hide() = 0; | 27 virtual void Hide() = 0; |
| 26 | 28 |
| 27 // Binds |screen| to the view. | 29 // Binds |screen| to the view. |
| 28 virtual void Bind(ErrorScreen* screen) = 0; | 30 virtual void Bind(ErrorScreen* screen) = 0; |
| 29 | 31 |
| 30 // Unbinds the screen from the view. | 32 // Unbinds the screen from the view. |
| 31 virtual void Unbind() = 0; | 33 virtual void Unbind() = 0; |
| 32 | 34 |
| 33 // Switches to |screen|. | 35 // Switches to |screen|. |
| 34 virtual void ShowOobeScreen(OobeScreen screen) = 0; | 36 virtual void ShowOobeScreen(OobeScreen screen) = 0; |
| 35 }; | 37 }; |
| 36 | 38 |
| 37 } // namespace chromeos | 39 } // namespace chromeos |
| 38 | 40 |
| 39 #endif // CHROME_BROWSER_CHROMEOS_LOGIN_SCREENS_NETWORK_ERROR_VIEW_H_ | 41 #endif // CHROME_BROWSER_CHROMEOS_LOGIN_SCREENS_NETWORK_ERROR_VIEW_H_ |
| OLD | NEW |