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

Unified Diff: components/mus/public/cpp/window_manager_delegate.h

Issue 1656123002: Moves accelerator registration to WindowManager (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fix mandoline Created 4 years, 11 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
Index: components/mus/public/cpp/window_manager_delegate.h
diff --git a/components/mus/public/cpp/window_manager_delegate.h b/components/mus/public/cpp/window_manager_delegate.h
index 9fe860f20b19a6843fb44ed3ddf94f8389f95eec..c4ac88e66d90d67e29e083a0c7105fd238792e86 100644
--- a/components/mus/public/cpp/window_manager_delegate.h
+++ b/components/mus/public/cpp/window_manager_delegate.h
@@ -10,7 +10,10 @@
#include <map>
#include <vector>
+#include "base/callback_forward.h"
#include "base/memory/scoped_ptr.h"
+#include "components/mus/public/interfaces/input_event_matcher.mojom.h"
+#include "components/mus/public/interfaces/input_events.mojom.h"
#include "components/mus/public/interfaces/window_manager_constants.mojom.h"
namespace gfx {
@@ -21,11 +24,18 @@ namespace mus {
class Window;
+// See the mojom with the same name for details on the functions in this
+// interface.
class WindowManagerClient {
public:
virtual void SetFrameDecorationValues(
mojom::FrameDecorationValuesPtr values) = 0;
+ virtual void AddAccelerator(uint32_t id,
+ mojom::EventMatcherPtr event_matcher,
+ const base::Callback<void(bool)>& callback) = 0;
+ virtual void RemoveAccelerator(uint32_t id) = 0;
+
protected:
virtual ~WindowManagerClient() {}
};
@@ -62,6 +72,8 @@ class WindowManagerDelegate {
virtual Window* OnWmCreateTopLevelWindow(
std::map<std::string, std::vector<uint8_t>>* properties) = 0;
+ virtual void OnAccelerator(uint32_t id, mus::mojom::EventPtr event) = 0;
+
protected:
virtual ~WindowManagerDelegate() {}
};
« no previous file with comments | « components/mus/public/cpp/tests/window_server_test_base.cc ('k') | components/mus/public/interfaces/window_manager.mojom » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698