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 ASH_SHELL_SHELL_DELEGATE_IMPL_H_ | 5 #ifndef ASH_SHELL_SHELL_DELEGATE_IMPL_H_ |
6 #define ASH_SHELL_SHELL_DELEGATE_IMPL_H_ | 6 #define ASH_SHELL_SHELL_DELEGATE_IMPL_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 | 9 |
10 #include "ash/shell_delegate.h" | 10 #include "ash/shell_delegate.h" |
11 #include "base/compiler_specific.h" | 11 #include "base/compiler_specific.h" |
12 | 12 |
13 namespace keyboard { | 13 namespace keyboard { |
14 class KeyboardControllerProxy; | 14 class KeyboardControllerProxy; |
15 } | 15 } |
16 | 16 |
17 namespace ash { | 17 namespace ash { |
18 namespace shell { | 18 namespace shell { |
19 | 19 |
20 class LauncherDelegateImpl; | 20 class LauncherDelegateImpl; |
21 class WindowWatcher; | 21 class WindowWatcher; |
22 | 22 |
23 class ShellDelegateImpl : public ash::ShellDelegate { | 23 class ShellDelegateImpl : public ash::ShellDelegate { |
24 public: | 24 public: |
25 ShellDelegateImpl(); | 25 ShellDelegateImpl(); |
26 virtual ~ShellDelegateImpl(); | 26 virtual ~ShellDelegateImpl(); |
27 | 27 |
28 void SetWatcher(WindowWatcher* watcher); | 28 void SetWatcher(WindowWatcher* watcher); |
29 | 29 |
| 30 virtual bool IsUserLoggedIn() const OVERRIDE; |
| 31 virtual bool IsSessionStarted() const OVERRIDE; |
| 32 virtual bool IsGuestSession() const OVERRIDE; |
30 virtual bool IsFirstRunAfterBoot() const OVERRIDE; | 33 virtual bool IsFirstRunAfterBoot() const OVERRIDE; |
31 virtual bool IsMultiProfilesEnabled() const OVERRIDE; | 34 virtual bool IsMultiProfilesEnabled() const OVERRIDE; |
32 virtual bool IsRunningInForcedAppMode() const OVERRIDE; | 35 virtual bool IsRunningInForcedAppMode() const OVERRIDE; |
| 36 virtual bool CanLockScreen() const OVERRIDE; |
| 37 virtual void LockScreen() OVERRIDE; |
| 38 virtual void UnlockScreen() OVERRIDE; |
| 39 virtual bool IsScreenLocked() const OVERRIDE; |
33 virtual void PreInit() OVERRIDE; | 40 virtual void PreInit() OVERRIDE; |
34 virtual void Shutdown() OVERRIDE; | 41 virtual void Shutdown() OVERRIDE; |
35 virtual void Exit() OVERRIDE; | 42 virtual void Exit() OVERRIDE; |
36 virtual void NewTab() OVERRIDE; | 43 virtual void NewTab() OVERRIDE; |
37 virtual void NewWindow(bool incognito) OVERRIDE; | 44 virtual void NewWindow(bool incognito) OVERRIDE; |
38 virtual void ToggleMaximized() OVERRIDE; | 45 virtual void ToggleMaximized() OVERRIDE; |
39 virtual void OpenFileManager(bool as_dialog) OVERRIDE; | 46 virtual void OpenFileManager(bool as_dialog) OVERRIDE; |
40 virtual void OpenCrosh() OVERRIDE; | 47 virtual void OpenCrosh() OVERRIDE; |
41 virtual void OpenMobileSetup(const std::string& service_path) OVERRIDE; | 48 virtual void OpenMobileSetup(const std::string& service_path) OVERRIDE; |
42 virtual void RestoreTab() OVERRIDE; | 49 virtual void RestoreTab() OVERRIDE; |
(...skipping 12 matching lines...) Expand all Loading... |
55 virtual void SetMagnifierType(MagnifierType type) OVERRIDE; | 62 virtual void SetMagnifierType(MagnifierType type) OVERRIDE; |
56 virtual bool IsMagnifierEnabled() const OVERRIDE; | 63 virtual bool IsMagnifierEnabled() const OVERRIDE; |
57 virtual MagnifierType GetMagnifierType() const OVERRIDE; | 64 virtual MagnifierType GetMagnifierType() const OVERRIDE; |
58 virtual bool ShouldAlwaysShowAccessibilityMenu() const OVERRIDE; | 65 virtual bool ShouldAlwaysShowAccessibilityMenu() const OVERRIDE; |
59 virtual app_list::AppListViewDelegate* CreateAppListViewDelegate() OVERRIDE; | 66 virtual app_list::AppListViewDelegate* CreateAppListViewDelegate() OVERRIDE; |
60 virtual ash::LauncherDelegate* CreateLauncherDelegate( | 67 virtual ash::LauncherDelegate* CreateLauncherDelegate( |
61 ash::LauncherModel* model) OVERRIDE; | 68 ash::LauncherModel* model) OVERRIDE; |
62 virtual ash::SystemTrayDelegate* CreateSystemTrayDelegate() OVERRIDE; | 69 virtual ash::SystemTrayDelegate* CreateSystemTrayDelegate() OVERRIDE; |
63 virtual ash::UserWallpaperDelegate* CreateUserWallpaperDelegate() OVERRIDE; | 70 virtual ash::UserWallpaperDelegate* CreateUserWallpaperDelegate() OVERRIDE; |
64 virtual ash::CapsLockDelegate* CreateCapsLockDelegate() OVERRIDE; | 71 virtual ash::CapsLockDelegate* CreateCapsLockDelegate() OVERRIDE; |
65 virtual ash::SessionStateDelegate* CreateSessionStateDelegate() OVERRIDE; | |
66 virtual aura::client::UserActionClient* CreateUserActionClient() OVERRIDE; | 72 virtual aura::client::UserActionClient* CreateUserActionClient() OVERRIDE; |
67 virtual void OpenFeedbackPage() OVERRIDE; | 73 virtual void OpenFeedbackPage() OVERRIDE; |
68 virtual void RecordUserMetricsAction(UserMetricsAction action) OVERRIDE; | 74 virtual void RecordUserMetricsAction(UserMetricsAction action) OVERRIDE; |
69 virtual void HandleMediaNextTrack() OVERRIDE; | 75 virtual void HandleMediaNextTrack() OVERRIDE; |
70 virtual void HandleMediaPlayPause() OVERRIDE; | 76 virtual void HandleMediaPlayPause() OVERRIDE; |
71 virtual void HandleMediaPrevTrack() OVERRIDE; | 77 virtual void HandleMediaPrevTrack() OVERRIDE; |
72 virtual base::string16 GetTimeRemainingString(base::TimeDelta delta) OVERRIDE; | 78 virtual base::string16 GetTimeRemainingString(base::TimeDelta delta) OVERRIDE; |
73 virtual base::string16 GetTimeDurationLongString( | 79 virtual base::string16 GetTimeDurationLongString( |
74 base::TimeDelta delta) OVERRIDE; | 80 base::TimeDelta delta) OVERRIDE; |
75 virtual void SaveScreenMagnifierScale(double scale) OVERRIDE; | 81 virtual void SaveScreenMagnifierScale(double scale) OVERRIDE; |
76 virtual double GetSavedScreenMagnifierScale() OVERRIDE; | 82 virtual double GetSavedScreenMagnifierScale() OVERRIDE; |
77 virtual ui::MenuModel* CreateContextMenu( | 83 virtual ui::MenuModel* CreateContextMenu( |
78 aura::RootWindow* root_window) OVERRIDE; | 84 aura::RootWindow* root_window) OVERRIDE; |
79 virtual RootWindowHostFactory* CreateRootWindowHostFactory() OVERRIDE; | 85 virtual RootWindowHostFactory* CreateRootWindowHostFactory() OVERRIDE; |
80 virtual base::string16 GetProductName() const OVERRIDE; | 86 virtual base::string16 GetProductName() const OVERRIDE; |
81 | 87 |
82 private: | 88 private: |
83 // Used to update Launcher. Owned by main. | 89 // Used to update Launcher. Owned by main. |
84 WindowWatcher* watcher_; | 90 WindowWatcher* watcher_; |
85 | 91 |
86 LauncherDelegateImpl* launcher_delegate_; | 92 LauncherDelegateImpl* launcher_delegate_; |
87 | 93 |
| 94 bool locked_; |
88 bool spoken_feedback_enabled_; | 95 bool spoken_feedback_enabled_; |
89 bool high_contrast_enabled_; | 96 bool high_contrast_enabled_; |
90 bool screen_magnifier_enabled_; | 97 bool screen_magnifier_enabled_; |
91 MagnifierType screen_magnifier_type_; | 98 MagnifierType screen_magnifier_type_; |
92 | 99 |
93 DISALLOW_COPY_AND_ASSIGN(ShellDelegateImpl); | 100 DISALLOW_COPY_AND_ASSIGN(ShellDelegateImpl); |
94 }; | 101 }; |
95 | 102 |
96 } // namespace shell | 103 } // namespace shell |
97 } // namespace ash | 104 } // namespace ash |
98 | 105 |
99 #endif // ASH_SHELL_SHELL_DELEGATE_IMPL_H_ | 106 #endif // ASH_SHELL_SHELL_DELEGATE_IMPL_H_ |
OLD | NEW |