Cast: Stop logging kVideoFrameSentToEncoder and rename a couple events.
[chromium-blink-merge.git] / chrome / browser / chromeos / login / login_display_host.h
blob9a7a3fc82d382890391409bb7175c9a0908438e8
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
3 // found in the LICENSE file.
5 #ifndef CHROME_BROWSER_CHROMEOS_LOGIN_LOGIN_DISPLAY_HOST_H_
6 #define CHROME_BROWSER_CHROMEOS_LOGIN_LOGIN_DISPLAY_HOST_H_
8 #include <string>
10 #include "base/callback.h"
11 #include "base/callback_list.h"
12 #include "base/memory/scoped_ptr.h"
13 #include "base/values.h"
14 #include "chrome/browser/chromeos/customization_document.h"
15 #include "chrome/browser/chromeos/login/login_display.h"
16 #include "ui/gfx/native_widget_types.h"
18 namespace views {
19 class Widget;
20 } // namespace views
22 namespace chromeos {
24 class AppLaunchController;
25 class AutoEnrollmentController;
26 class LoginScreenContext;
27 class WebUILoginView;
28 class WizardController;
30 // An interface that defines OOBE/login screen host.
31 // Host encapsulates WebUI window OOBE/login controllers,
32 // UI implementation (such as LoginDisplay).
33 class LoginDisplayHost {
34 public:
35 virtual ~LoginDisplayHost() {}
37 // Creates UI implementation specific login display instance (views/WebUI).
38 // The caller takes ownership of the returned value.
39 virtual LoginDisplay* CreateLoginDisplay(
40 LoginDisplay::Delegate* delegate) = 0;
42 // Returns corresponding native window.
43 virtual gfx::NativeWindow GetNativeWindow() const = 0;
45 // Returns the current login view.
46 virtual WebUILoginView* GetWebUILoginView() const = 0;
48 // Called when browsing session starts before creating initial browser.
49 virtual void BeforeSessionStart() = 0;
51 // Called when user enters or returns to browsing session so
52 // LoginDisplayHost instance may delete itself.
53 virtual void Finalize() = 0;
55 // Called when a login has completed successfully.
56 virtual void OnCompleteLogin() = 0;
58 // Open proxy settings dialog.
59 virtual void OpenProxySettings() = 0;
61 // Toggles status area visibility.
62 virtual void SetStatusAreaVisible(bool visible) = 0;
64 // Gets the auto-enrollment client.
65 virtual AutoEnrollmentController* GetAutoEnrollmentController() = 0;
67 // Starts out-of-box-experience flow or shows other screen handled by
68 // Wizard controller i.e. camera, recovery.
69 // One could specify start screen with |first_screen_name|.
70 // Takes ownership of |screen_parameters|, which can also be NULL.
71 virtual void StartWizard(
72 const std::string& first_screen_name,
73 scoped_ptr<base::DictionaryValue> screen_parameters) = 0;
75 // Returns current WizardController, if it exists.
76 // Result should not be stored.
77 virtual WizardController* GetWizardController() = 0;
79 // Returns current AppLaunchController, if it exists.
80 // Result should not be stored.
81 virtual AppLaunchController* GetAppLaunchController() = 0;
83 // Starts screen for adding user into session.
84 // |completion_callback| called before display host shutdown.
85 // |completion_callback| can be null.
86 virtual void StartUserAdding(const base::Closure& completion_callback) = 0;
88 // Starts sign in screen.
89 virtual void StartSignInScreen(const LoginScreenContext& context) = 0;
91 // Resumes a previously started sign in screen.
92 virtual void ResumeSignInScreen() = 0;
94 // Invoked when system preferences that affect the signin screen have changed.
95 virtual void OnPreferencesChanged() = 0;
97 // Initiates authentication network prewarming.
98 virtual void PrewarmAuthentication() = 0;
100 // Starts app launch splash screen.
101 virtual void StartAppLaunch(const std::string& app_id,
102 bool diagnostic_mode) = 0;
104 // Starts the demo app launch.
105 virtual void StartDemoAppLaunch() = 0;
108 } // namespace chromeos
110 #endif // CHROME_BROWSER_CHROMEOS_LOGIN_LOGIN_DISPLAY_HOST_H_