| OLD | NEW |
| 1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 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_UI_WEBUI_CHROMEOS_LOGIN_SIGNIN_SCREEN_HANDLER_H_ | 5 #ifndef CHROME_BROWSER_UI_WEBUI_CHROMEOS_LOGIN_SIGNIN_SCREEN_HANDLER_H_ |
| 6 #define CHROME_BROWSER_UI_WEBUI_CHROMEOS_LOGIN_SIGNIN_SCREEN_HANDLER_H_ | 6 #define CHROME_BROWSER_UI_WEBUI_CHROMEOS_LOGIN_SIGNIN_SCREEN_HANDLER_H_ |
| 7 | 7 |
| 8 #include <set> | 8 #include <set> |
| 9 #include <string> | 9 #include <string> |
| 10 | 10 |
| 11 #include "base/callback.h" | 11 #include "base/callback.h" |
| 12 #include "base/containers/hash_tables.h" | 12 #include "base/containers/hash_tables.h" |
| 13 #include "base/memory/ref_counted.h" | 13 #include "base/memory/ref_counted.h" |
| 14 #include "base/memory/scoped_ptr.h" |
| 14 #include "base/memory/weak_ptr.h" | 15 #include "base/memory/weak_ptr.h" |
| 15 #include "chrome/browser/chromeos/login/help_app_launcher.h" | 16 #include "chrome/browser/chromeos/login/help_app_launcher.h" |
| 16 #include "chrome/browser/chromeos/login/login_display.h" | 17 #include "chrome/browser/chromeos/login/login_display.h" |
| 17 #include "chrome/browser/chromeos/login/screens/error_screen_actor.h" | 18 #include "chrome/browser/chromeos/login/screens/error_screen_actor.h" |
| 18 #include "chrome/browser/chromeos/login/user_manager.h" | 19 #include "chrome/browser/chromeos/login/user_manager.h" |
| 19 #include "chrome/browser/chromeos/net/network_portal_detector.h" | 20 #include "chrome/browser/chromeos/net/network_portal_detector.h" |
| 21 #include "chrome/browser/chromeos/settings/cros_settings.h" |
| 20 #include "chrome/browser/chromeos/system_key_event_listener.h" | 22 #include "chrome/browser/chromeos/system_key_event_listener.h" |
| 21 #include "chrome/browser/ui/webui/chromeos/login/base_screen_handler.h" | 23 #include "chrome/browser/ui/webui/chromeos/login/base_screen_handler.h" |
| 22 #include "chrome/browser/ui/webui/chromeos/login/network_state_informer.h" | 24 #include "chrome/browser/ui/webui/chromeos/login/network_state_informer.h" |
| 23 #include "chrome/browser/ui/webui/chromeos/login/oobe_ui.h" | 25 #include "chrome/browser/ui/webui/chromeos/login/oobe_ui.h" |
| 24 #include "content/public/browser/notification_observer.h" | 26 #include "content/public/browser/notification_observer.h" |
| 25 #include "content/public/browser/notification_registrar.h" | 27 #include "content/public/browser/notification_registrar.h" |
| 26 #include "content/public/browser/web_ui.h" | 28 #include "content/public/browser/web_ui.h" |
| 27 #include "net/base/net_errors.h" | 29 #include "net/base/net_errors.h" |
| 28 | 30 |
| 29 namespace base { | 31 namespace base { |
| (...skipping 241 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 271 | 273 |
| 272 // Tells webui to load authentication extension. |force| is used to force the | 274 // Tells webui to load authentication extension. |force| is used to force the |
| 273 // extension reloading, if it has already been loaded. |silent_load| is true | 275 // extension reloading, if it has already been loaded. |silent_load| is true |
| 274 // for cases when extension should be loaded in the background and it | 276 // for cases when extension should be loaded in the background and it |
| 275 // shouldn't grab the focus. |offline| is true when offline version of the | 277 // shouldn't grab the focus. |offline| is true when offline version of the |
| 276 // extension should be used. | 278 // extension should be used. |
| 277 void LoadAuthExtension(bool force, bool silent_load, bool offline); | 279 void LoadAuthExtension(bool force, bool silent_load, bool offline); |
| 278 | 280 |
| 279 // Updates authentication extension. Called when device settings that affect | 281 // Updates authentication extension. Called when device settings that affect |
| 280 // sign-in (allow BWSI and allow whitelist) are changed. | 282 // sign-in (allow BWSI and allow whitelist) are changed. |
| 283 void UserSettingsChanged(); |
| 281 void UpdateAuthExtension(); | 284 void UpdateAuthExtension(); |
| 282 void UpdateAddButtonStatus(); | 285 void UpdateAddButtonStatus(); |
| 283 | 286 |
| 284 // Fill |params| that are passed to JS.. | 287 // Fill |params| that are passed to JS.. |
| 285 void UpdateAuthParams(DictionaryValue* params); | 288 void UpdateAuthParams(DictionaryValue* params); |
| 286 | 289 |
| 287 // Restore input focus to current user pod. | 290 // Restore input focus to current user pod. |
| 288 void RefocusCurrentPod(); | 291 void RefocusCurrentPod(); |
| 289 | 292 |
| 290 // WebUI message handlers. | 293 // WebUI message handlers. |
| (...skipping 170 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 461 base::CancelableClosure update_state_closure_; | 464 base::CancelableClosure update_state_closure_; |
| 462 base::CancelableClosure connecting_closure_; | 465 base::CancelableClosure connecting_closure_; |
| 463 | 466 |
| 464 content::NotificationRegistrar registrar_; | 467 content::NotificationRegistrar registrar_; |
| 465 | 468 |
| 466 // Whether there is an auth UI pending. This flag is set on receiving | 469 // Whether there is an auth UI pending. This flag is set on receiving |
| 467 // NOTIFICATION_AUTH_NEEDED and reset on either NOTIFICATION_AUTH_SUPPLIED or | 470 // NOTIFICATION_AUTH_NEEDED and reset on either NOTIFICATION_AUTH_SUPPLIED or |
| 468 // NOTIFICATION_AUTH_CANCELLED. | 471 // NOTIFICATION_AUTH_CANCELLED. |
| 469 bool has_pending_auth_ui_; | 472 bool has_pending_auth_ui_; |
| 470 | 473 |
| 474 scoped_ptr<CrosSettings::ObserverSubscription> allow_new_user_subscription_; |
| 475 scoped_ptr<CrosSettings::ObserverSubscription> allow_guest_subscription_; |
| 476 |
| 471 DISALLOW_COPY_AND_ASSIGN(SigninScreenHandler); | 477 DISALLOW_COPY_AND_ASSIGN(SigninScreenHandler); |
| 472 }; | 478 }; |
| 473 | 479 |
| 474 } // namespace chromeos | 480 } // namespace chromeos |
| 475 | 481 |
| 476 #endif // CHROME_BROWSER_UI_WEBUI_CHROMEOS_LOGIN_SIGNIN_SCREEN_HANDLER_H_ | 482 #endif // CHROME_BROWSER_UI_WEBUI_CHROMEOS_LOGIN_SIGNIN_SCREEN_HANDLER_H_ |
| OLD | NEW |