Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(185)

Unified Diff: ash/mus/shell_delegate_mus.cc

Issue 1685313002: ash/mash: Fix launching ash as a mus-app in chromeos. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « ash/mus/BUILD.gn ('k') | ash/mus/sysui_application.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ash/mus/shell_delegate_mus.cc
diff --git a/ash/mus/shell_delegate_mus.cc b/ash/mus/shell_delegate_mus.cc
index c796359ad1ed2b06d30ef14726c4b662c587d464..f2c0de4307dec9aad33eae45b7e6c7585c9b49eb 100644
--- a/ash/mus/shell_delegate_mus.cc
+++ b/ash/mus/shell_delegate_mus.cc
@@ -6,6 +6,8 @@
#include "ash/default_accessibility_delegate.h"
#include "ash/default_user_wallpaper_delegate.h"
+#include "ash/gpu_support_stub.h"
+#include "ash/media_delegate.h"
#include "ash/mus/shelf_delegate_mus.h"
#include "ash/session/session_state_delegate.h"
#include "ash/system/tray/default_system_tray_delegate.h"
@@ -72,6 +74,24 @@ class SessionStateDelegateStub : public SessionStateDelegate {
DISALLOW_COPY_AND_ASSIGN(SessionStateDelegateStub);
};
+class MediaDelegateStub : public MediaDelegate {
+ public:
+ MediaDelegateStub() {}
+ ~MediaDelegateStub() override {}
+
+ // MediaDelegate:
+ void HandleMediaNextTrack() override { NOTIMPLEMENTED(); }
+ void HandleMediaPlayPause() override { NOTIMPLEMENTED(); }
+ void HandleMediaPrevTrack() override { NOTIMPLEMENTED(); }
+ MediaCaptureState GetMediaCaptureState(UserIndex index) override {
+ NOTIMPLEMENTED();
+ return MEDIA_CAPTURE_NONE;
+ }
+
+ private:
+ DISALLOW_COPY_AND_ASSIGN(MediaDelegateStub);
+};
+
} // namespace
ShellDelegateMus::ShellDelegateMus() {}
@@ -147,47 +167,47 @@ ShelfDelegate* ShellDelegateMus::CreateShelfDelegate(ShelfModel* model) {
return new ShelfDelegateMus(model);
}
-ash::SystemTrayDelegate* ShellDelegateMus::CreateSystemTrayDelegate() {
+SystemTrayDelegate* ShellDelegateMus::CreateSystemTrayDelegate() {
NOTIMPLEMENTED() << " Using the default SystemTrayDelegate implementation";
return new DefaultSystemTrayDelegate;
}
-ash::UserWallpaperDelegate* ShellDelegateMus::CreateUserWallpaperDelegate() {
+UserWallpaperDelegate* ShellDelegateMus::CreateUserWallpaperDelegate() {
NOTIMPLEMENTED() << " Using the default UserWallpaperDelegate implementation";
return new DefaultUserWallpaperDelegate();
}
-ash::SessionStateDelegate* ShellDelegateMus::CreateSessionStateDelegate() {
+SessionStateDelegate* ShellDelegateMus::CreateSessionStateDelegate() {
NOTIMPLEMENTED() << " Using a stub SessionStateDeleagte implementation";
return new SessionStateDelegateStub;
}
-ash::AccessibilityDelegate* ShellDelegateMus::CreateAccessibilityDelegate() {
+AccessibilityDelegate* ShellDelegateMus::CreateAccessibilityDelegate() {
NOTIMPLEMENTED() << " Using the default AccessibilityDelegate implementation";
return new DefaultAccessibilityDelegate;
}
-ash::NewWindowDelegate* ShellDelegateMus::CreateNewWindowDelegate() {
+NewWindowDelegate* ShellDelegateMus::CreateNewWindowDelegate() {
NOTIMPLEMENTED();
return nullptr;
}
-ash::MediaDelegate* ShellDelegateMus::CreateMediaDelegate() {
- NOTIMPLEMENTED();
- return nullptr;
+MediaDelegate* ShellDelegateMus::CreateMediaDelegate() {
+ NOTIMPLEMENTED() << " Using a stub MediaDelegate implementation";
+ return new MediaDelegateStub;
}
ui::MenuModel* ShellDelegateMus::CreateContextMenu(
aura::Window* root_window,
- ash::ShelfItemDelegate* item_delegate,
- ash::ShelfItem* item) {
+ ShelfItemDelegate* item_delegate,
+ ShelfItem* item) {
NOTIMPLEMENTED();
return nullptr;
}
GPUSupport* ShellDelegateMus::CreateGPUSupport() {
- NOTIMPLEMENTED();
- return nullptr;
+ NOTIMPLEMENTED() << " Using a stub GPUSupport implementation";
+ return new GPUSupportStub();
}
base::string16 ShellDelegateMus::GetProductName() const {
« no previous file with comments | « ash/mus/BUILD.gn ('k') | ash/mus/sysui_application.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698