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

Unified Diff: components/mus/public/interfaces/window_manager.mojom

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/interfaces/window_manager.mojom
diff --git a/components/mus/public/interfaces/window_manager.mojom b/components/mus/public/interfaces/window_manager.mojom
index 5bf1eb45af03d218b15ef7698e9757b088624364..5121ba00e56d70c361968111e91a686a191a0836 100644
--- a/components/mus/public/interfaces/window_manager.mojom
+++ b/components/mus/public/interfaces/window_manager.mojom
@@ -4,6 +4,8 @@
module mus.mojom;
+import "components/mus/public/interfaces/input_event_matcher.mojom";
+import "components/mus/public/interfaces/input_events.mojom";
import "components/mus/public/interfaces/window_manager_constants.mojom";
import "ui/mojo/geometry/geometry.mojom";
@@ -44,11 +46,22 @@ interface WindowManager {
// Asks the WindowManager to create a new window.
WmCreateTopLevelWindow(uint32 change_id,
map<string, array<uint8>> properties);
+
+ // An accelerator registered via AddAccelerator() has been triggered.
+ OnAccelerator(uint32 id, Event event);
};
// This interface is only used as an associated interface and is associated
// with WindowTree.
interface WindowManagerClient {
+ // Add and remove accelerators. When accelerators are registered the
+ // WindowManager receives the event via OnAccelerator() rather than the
+ // target window. The id is defined by the client and can be used to more
+ // easily identify the accelerator's action. If an accelerator with the same
+ // id or the same matcher already exists, then the accelerator is not added.
+ AddAccelerator(uint32 id, EventMatcher matcher) => (bool success);
+ RemoveAccelerator(uint32 id);
+
// The window manager has completed a request with the specific change id.
WmResponse(uint32 change_id, bool response);
« no previous file with comments | « components/mus/public/cpp/window_manager_delegate.h ('k') | components/mus/public/interfaces/window_tree_host.mojom » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698