summaryrefslogtreecommitdiff
path: root/config/dbus-api
diff options
context:
space:
mode:
authorDaniel Stone <daniel@fooishbar.org>2006-10-15 19:44:49 +0300
committerDaniel Stone <daniels@endtroducing.fooishbar.org>2006-10-15 19:44:49 +0300
commitec35e7198debf938f1115f584e675ce5995743e3 (patch)
tree3475df7a2004868ebcd8f83ca97ce7b8a3041dc1 /config/dbus-api
parenta05044cfc14a8bc6cc31236dcecada60bec09924 (diff)
config: add replies and dbus api documentation
Add replies, which use standard X error values, to the two currently-supported input configuration requests. Document the D-BUS API we use. Make sure we free everything when we encounter an error. Add a _source option to all incoming requests, noting that it came from a client. Reject all requests to add a device where an option name contains an underscore.
Diffstat (limited to 'config/dbus-api')
-rw-r--r--config/dbus-api35
1 files changed, 35 insertions, 0 deletions
diff --git a/config/dbus-api b/config/dbus-api
new file mode 100644
index 000000000..53bb3e45d
--- /dev/null
+++ b/config/dbus-api
@@ -0,0 +1,35 @@
1D-BUS Configuration API v0.1
2----------------------------
3
4The X server will register the bus name org.x.config.displayN, and the
5object /org/x/config/N, where N is the display number.
6
7Currently only hotplugging of input devices is supported.
8
9org.x.config.input:
10 org.x.config.input.add:
11 Takes an argument of key/value option pairs in arrays, e.g.:
12 [ss][ss][ss][ss]
13 is the signature for four options. These options will be passed
14 to the input driver as with any others.
15 Option names beginning with _ are not allowed; they are reserved
16 for internal use.
17
18 Returns one int32, which is an X Status, as defined in X.h. If
19 everything is successful, Success will be returned. BadMatch will
20 be returned if the options given do not match any device. BadValue
21 is returned for a malformed message.
22
23 Notably, BadAlloc is never returned: the server internally signals
24 to D-BUS that the attempt failed for lack of memory.
25
26 The return does not notify the client of which devices were created
27 or modified as a result of this request: clients are encouraged to
28 listen for the XInput DevicePresenceNotify event to monitor changes
29 in the device list.
30
31 org.x.config.input.remove:
32 Takes one int32 argument, which is the device ID to remove, i.e.:
33 i
34 is the signature.
35 Same return values as org.x.config.input.add.