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

Unified Diff: components/mus/public/interfaces/input_devices/input_device_server.mojom

Issue 1992443002: Add Mojo IPC based input-device service. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@cleanup_ddm
Patch Set: Fix nits. Created 4 years, 6 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 | « components/mus/public/interfaces/input_devices/BUILD.gn ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/mus/public/interfaces/input_devices/input_device_server.mojom
diff --git a/components/mus/public/interfaces/input_devices/input_device_server.mojom b/components/mus/public/interfaces/input_devices/input_device_server.mojom
new file mode 100644
index 0000000000000000000000000000000000000000..532792a7f48faa513f6819fef45fda46b6d6d2ae
--- /dev/null
+++ b/components/mus/public/interfaces/input_devices/input_device_server.mojom
@@ -0,0 +1,43 @@
+// Copyright 2016 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+module input_device.mojom;
+
+import "ui/events/devices/mojo/input_devices.mojom";
+
+// Receives updates about changes to input-devices. See InputDeviceServer for
+// the expected behaviour.
+interface InputDeviceObserverMojo {
+ // Is called when the list of keyboards changes.
+ OnKeyboardDeviceConfigurationChanged(array<ui.mojom.InputDevice> devices);
+
+ // Is called when the list of touchscreens changes.
+ OnTouchscreenDeviceConfigurationChanged(
+ array<ui.mojom.TouchscreenDevice> devices);
+
+ // Is called when the list of mice changes.
+ OnMouseDeviceConfigurationChanged(array<ui.mojom.InputDevice> devices);
+
+ // Is called when the list of touchpads changes.
+ OnTouchpadDeviceConfigurationChanged(array<ui.mojom.InputDevice> devices);
+
+ // Is called once all of the input-device lists are available. This will
+ // always be the first call that an observer receives.
+ OnDeviceListsComplete(
+ array<ui.mojom.InputDevice> keyboard_devices,
+ array<ui.mojom.TouchscreenDevice> touchscreen_devices,
+ array<ui.mojom.InputDevice> mouse_devices,
+ array<ui.mojom.InputDevice> touchpad_devices);
+};
+
+// Sends updates about input-devices to observers.
+interface InputDeviceServer {
+ // Adds an InputDeviceObserverMojo in another process as an observer to get
+ // notified of changes to input-devices over Mojo IPC. If all input-device
+ // lists are complete when a new observer connects, the implementation will
+ // immediately call OnDeviceListsComplete() with the input-device lists. If
+ // not, the implementation will wait until all input-device lists are complete
+ // then call OnDeviceListsComplete() for all connected observers.
+ AddObserver(InputDeviceObserverMojo observer);
+};
« no previous file with comments | « components/mus/public/interfaces/input_devices/BUILD.gn ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698