OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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_NETWORK_SCREEN_ACTOR_H_ | 5 #ifndef CHROME_BROWSER_CHROMEOS_LOGIN_NETWORK_SCREEN_ACTOR_H_ |
6 #define CHROME_BROWSER_CHROMEOS_LOGIN_NETWORK_SCREEN_ACTOR_H_ | 6 #define CHROME_BROWSER_CHROMEOS_LOGIN_NETWORK_SCREEN_ACTOR_H_ |
7 | 7 |
8 #include "base/string16.h" | 8 #include "base/string16.h" |
9 | 9 |
10 namespace chromeos { | 10 namespace chromeos { |
11 | 11 |
12 // Interface for dependency injection between NetworkScreen and its actual | 12 // Interface for dependency injection between NetworkScreen and its actual |
13 // representation, either views based or WebUI. Owned by NetworkScreen. | 13 // representation, either views based or WebUI. Owned by NetworkScreen. |
14 class NetworkScreenActor { | 14 class NetworkScreenActor { |
15 public: | 15 public: |
16 class Delegate { | 16 class Delegate { |
17 public: | 17 public: |
18 virtual ~Delegate() {} | 18 virtual ~Delegate() {} |
| 19 virtual void OnActorDestroyed(NetworkScreenActor* actor) = 0; |
19 virtual void OnContinuePressed() = 0; | 20 virtual void OnContinuePressed() = 0; |
20 }; | 21 }; |
21 | 22 |
22 virtual ~NetworkScreenActor() {} | 23 virtual ~NetworkScreenActor() {} |
23 | 24 |
24 // Sets screen this actor belongs to. | 25 // Sets screen this actor belongs to. |
25 virtual void SetDelegate(Delegate* screen) = 0; | 26 virtual void SetDelegate(Delegate* screen) = 0; |
26 | 27 |
27 // Prepare the contents to showing. | 28 // Prepare the contents to showing. |
28 virtual void PrepareToShow() = 0; | 29 virtual void PrepareToShow() = 0; |
(...skipping 15 matching lines...) Expand all Loading... |
44 bool connecting, | 45 bool connecting, |
45 const string16& network_id) = 0; | 46 const string16& network_id) = 0; |
46 | 47 |
47 // Sets whether continue control is enabled. | 48 // Sets whether continue control is enabled. |
48 virtual void EnableContinue(bool enabled) = 0; | 49 virtual void EnableContinue(bool enabled) = 0; |
49 }; | 50 }; |
50 | 51 |
51 } // namespace chromeos | 52 } // namespace chromeos |
52 | 53 |
53 #endif // CHROME_BROWSER_CHROMEOS_LOGIN_NETWORK_SCREEN_ACTOR_H_ | 54 #endif // CHROME_BROWSER_CHROMEOS_LOGIN_NETWORK_SCREEN_ACTOR_H_ |
OLD | NEW |