| OLD | NEW |
| 1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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 #include "ash/mus/shell_delegate_mus.h" | 5 #include "ash/mus/shell_delegate_mus.h" |
| 6 | 6 |
| 7 #include "ash/default_accessibility_delegate.h" | 7 #include "ash/default_accessibility_delegate.h" |
| 8 #include "ash/default_user_wallpaper_delegate.h" | 8 #include "ash/default_user_wallpaper_delegate.h" |
| 9 #include "ash/gpu_support_stub.h" |
| 10 #include "ash/media_delegate.h" |
| 9 #include "ash/mus/shelf_delegate_mus.h" | 11 #include "ash/mus/shelf_delegate_mus.h" |
| 10 #include "ash/session/session_state_delegate.h" | 12 #include "ash/session/session_state_delegate.h" |
| 11 #include "ash/system/tray/default_system_tray_delegate.h" | 13 #include "ash/system/tray/default_system_tray_delegate.h" |
| 12 #include "base/strings/string16.h" | 14 #include "base/strings/string16.h" |
| 13 #include "components/user_manager/user_info_impl.h" | 15 #include "components/user_manager/user_info_impl.h" |
| 14 #include "ui/gfx/image/image.h" | 16 #include "ui/gfx/image/image.h" |
| 15 | 17 |
| 16 namespace ash { | 18 namespace ash { |
| 17 namespace sysui { | 19 namespace sysui { |
| 18 | 20 |
| (...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 65 | 67 |
| 66 private: | 68 private: |
| 67 bool screen_locked_; | 69 bool screen_locked_; |
| 68 | 70 |
| 69 // A pseudo user info. | 71 // A pseudo user info. |
| 70 scoped_ptr<user_manager::UserInfo> user_info_; | 72 scoped_ptr<user_manager::UserInfo> user_info_; |
| 71 | 73 |
| 72 DISALLOW_COPY_AND_ASSIGN(SessionStateDelegateStub); | 74 DISALLOW_COPY_AND_ASSIGN(SessionStateDelegateStub); |
| 73 }; | 75 }; |
| 74 | 76 |
| 77 class MediaDelegateStub : public MediaDelegate { |
| 78 public: |
| 79 MediaDelegateStub() {} |
| 80 ~MediaDelegateStub() override {} |
| 81 |
| 82 // MediaDelegate: |
| 83 void HandleMediaNextTrack() override { NOTIMPLEMENTED(); } |
| 84 void HandleMediaPlayPause() override { NOTIMPLEMENTED(); } |
| 85 void HandleMediaPrevTrack() override { NOTIMPLEMENTED(); } |
| 86 MediaCaptureState GetMediaCaptureState(UserIndex index) override { |
| 87 NOTIMPLEMENTED(); |
| 88 return MEDIA_CAPTURE_NONE; |
| 89 } |
| 90 |
| 91 private: |
| 92 DISALLOW_COPY_AND_ASSIGN(MediaDelegateStub); |
| 93 }; |
| 94 |
| 75 } // namespace | 95 } // namespace |
| 76 | 96 |
| 77 ShellDelegateMus::ShellDelegateMus() {} | 97 ShellDelegateMus::ShellDelegateMus() {} |
| 78 ShellDelegateMus::~ShellDelegateMus() {} | 98 ShellDelegateMus::~ShellDelegateMus() {} |
| 79 | 99 |
| 80 bool ShellDelegateMus::IsFirstRunAfterBoot() const { | 100 bool ShellDelegateMus::IsFirstRunAfterBoot() const { |
| 81 NOTIMPLEMENTED(); | 101 NOTIMPLEMENTED(); |
| 82 return false; | 102 return false; |
| 83 } | 103 } |
| 84 | 104 |
| (...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 140 | 160 |
| 141 app_list::AppListViewDelegate* ShellDelegateMus::GetAppListViewDelegate() { | 161 app_list::AppListViewDelegate* ShellDelegateMus::GetAppListViewDelegate() { |
| 142 NOTIMPLEMENTED(); | 162 NOTIMPLEMENTED(); |
| 143 return nullptr; | 163 return nullptr; |
| 144 } | 164 } |
| 145 | 165 |
| 146 ShelfDelegate* ShellDelegateMus::CreateShelfDelegate(ShelfModel* model) { | 166 ShelfDelegate* ShellDelegateMus::CreateShelfDelegate(ShelfModel* model) { |
| 147 return new ShelfDelegateMus(model); | 167 return new ShelfDelegateMus(model); |
| 148 } | 168 } |
| 149 | 169 |
| 150 ash::SystemTrayDelegate* ShellDelegateMus::CreateSystemTrayDelegate() { | 170 SystemTrayDelegate* ShellDelegateMus::CreateSystemTrayDelegate() { |
| 151 NOTIMPLEMENTED() << " Using the default SystemTrayDelegate implementation"; | 171 NOTIMPLEMENTED() << " Using the default SystemTrayDelegate implementation"; |
| 152 return new DefaultSystemTrayDelegate; | 172 return new DefaultSystemTrayDelegate; |
| 153 } | 173 } |
| 154 | 174 |
| 155 ash::UserWallpaperDelegate* ShellDelegateMus::CreateUserWallpaperDelegate() { | 175 UserWallpaperDelegate* ShellDelegateMus::CreateUserWallpaperDelegate() { |
| 156 NOTIMPLEMENTED() << " Using the default UserWallpaperDelegate implementation"; | 176 NOTIMPLEMENTED() << " Using the default UserWallpaperDelegate implementation"; |
| 157 return new DefaultUserWallpaperDelegate(); | 177 return new DefaultUserWallpaperDelegate(); |
| 158 } | 178 } |
| 159 | 179 |
| 160 ash::SessionStateDelegate* ShellDelegateMus::CreateSessionStateDelegate() { | 180 SessionStateDelegate* ShellDelegateMus::CreateSessionStateDelegate() { |
| 161 NOTIMPLEMENTED() << " Using a stub SessionStateDeleagte implementation"; | 181 NOTIMPLEMENTED() << " Using a stub SessionStateDeleagte implementation"; |
| 162 return new SessionStateDelegateStub; | 182 return new SessionStateDelegateStub; |
| 163 } | 183 } |
| 164 | 184 |
| 165 ash::AccessibilityDelegate* ShellDelegateMus::CreateAccessibilityDelegate() { | 185 AccessibilityDelegate* ShellDelegateMus::CreateAccessibilityDelegate() { |
| 166 NOTIMPLEMENTED() << " Using the default AccessibilityDelegate implementation"; | 186 NOTIMPLEMENTED() << " Using the default AccessibilityDelegate implementation"; |
| 167 return new DefaultAccessibilityDelegate; | 187 return new DefaultAccessibilityDelegate; |
| 168 } | 188 } |
| 169 | 189 |
| 170 ash::NewWindowDelegate* ShellDelegateMus::CreateNewWindowDelegate() { | 190 NewWindowDelegate* ShellDelegateMus::CreateNewWindowDelegate() { |
| 171 NOTIMPLEMENTED(); | 191 NOTIMPLEMENTED(); |
| 172 return nullptr; | 192 return nullptr; |
| 173 } | 193 } |
| 174 | 194 |
| 175 ash::MediaDelegate* ShellDelegateMus::CreateMediaDelegate() { | 195 MediaDelegate* ShellDelegateMus::CreateMediaDelegate() { |
| 176 NOTIMPLEMENTED(); | 196 NOTIMPLEMENTED() << " Using a stub MediaDelegate implementation"; |
| 177 return nullptr; | 197 return new MediaDelegateStub; |
| 178 } | 198 } |
| 179 | 199 |
| 180 ui::MenuModel* ShellDelegateMus::CreateContextMenu( | 200 ui::MenuModel* ShellDelegateMus::CreateContextMenu( |
| 181 aura::Window* root_window, | 201 aura::Window* root_window, |
| 182 ash::ShelfItemDelegate* item_delegate, | 202 ShelfItemDelegate* item_delegate, |
| 183 ash::ShelfItem* item) { | 203 ShelfItem* item) { |
| 184 NOTIMPLEMENTED(); | 204 NOTIMPLEMENTED(); |
| 185 return nullptr; | 205 return nullptr; |
| 186 } | 206 } |
| 187 | 207 |
| 188 GPUSupport* ShellDelegateMus::CreateGPUSupport() { | 208 GPUSupport* ShellDelegateMus::CreateGPUSupport() { |
| 189 NOTIMPLEMENTED(); | 209 NOTIMPLEMENTED() << " Using a stub GPUSupport implementation"; |
| 190 return nullptr; | 210 return new GPUSupportStub(); |
| 191 } | 211 } |
| 192 | 212 |
| 193 base::string16 ShellDelegateMus::GetProductName() const { | 213 base::string16 ShellDelegateMus::GetProductName() const { |
| 194 NOTIMPLEMENTED(); | 214 NOTIMPLEMENTED(); |
| 195 return base::string16(); | 215 return base::string16(); |
| 196 } | 216 } |
| 197 | 217 |
| 198 gfx::Image ShellDelegateMus::GetDeprecatedAcceleratorImage() const { | 218 gfx::Image ShellDelegateMus::GetDeprecatedAcceleratorImage() const { |
| 199 NOTIMPLEMENTED(); | 219 NOTIMPLEMENTED(); |
| 200 return gfx::Image(); | 220 return gfx::Image(); |
| 201 } | 221 } |
| 202 | 222 |
| 203 } // namespace sysui | 223 } // namespace sysui |
| 204 } // namespace ash | 224 } // namespace ash |
| OLD | NEW |