Bug 1873042 - Part 3: Optimise substring(0, 1) pattern. r=jandem
[gecko.git] / widget / gtk / MPRISInterfaceDescription.h
blob28e719e651ad8060f6246620a623db36e9719454
1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*-
3 * This Source Code Form is subject to the terms of the Mozilla Public
4 * License, v. 2.0. If a copy of the MPL was not distributed with this
5 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
7 #ifndef WIDGET_GTK_MPRIS_INTERFACE_DESCRIPTION_H_
8 #define WIDGET_GTK_MPRIS_INTERFACE_DESCRIPTION_H_
10 #include <gio/gio.h>
12 extern const gchar introspection_xml[] =
13 // adopted from https://github.com/freedesktop/mpris-spec/blob/master/spec/org.mpris.MediaPlayer2.xml
14 // everything starting with tp can be removed, as it is used for HTML Spec Documentation Generation
15 "<node>"
16 "<interface name=\"org.mpris.MediaPlayer2\">"
17 "<annotation name=\"org.freedesktop.DBus.Property.EmitsChangedSignal\" value=\"true\"/>"
18 "<method name=\"Raise\"/>"
19 "<method name=\"Quit\"/>"
20 "<property name=\"CanQuit\" type=\"b\" access=\"read\"/>"
21 "<property name=\"CanRaise\" type=\"b\" access=\"read\"/>"
22 "<property name=\"HasTrackList\" type=\"b\" access=\"read\"/>"
23 "<property name=\"Identity\" type=\"s\" access=\"read\"/>"
24 "<property name=\"DesktopEntry\" type=\"s\" access=\"read\"/>"
25 "<property name=\"SupportedUriSchemes\" type=\"as\" access=\"read\"/>"
26 "<property name=\"SupportedMimeTypes\" type=\"as\" access=\"read\"/>"
27 "</interface>"
28 // Note that every property emits a changed signal (which is default) apart from Position.
29 "<interface name=\"org.mpris.MediaPlayer2.Player\">"
30 "<method name=\"Next\"/>"
31 "<method name=\"Previous\"/>"
32 "<method name=\"Pause\"/>"
33 "<method name=\"PlayPause\"/>"
34 "<method name=\"Stop\"/>"
35 "<method name=\"Play\"/>"
36 "<method name=\"Seek\">"
37 "<arg direction=\"in\" type=\"x\" name=\"Offset\"/>"
38 "</method>"
39 "<method name=\"SetPosition\">"
40 "<arg direction=\"in\" type=\"o\" name=\"TrackId\"/>"
41 "<arg direction=\"in\" type=\"x\" name=\"Position\"/>"
42 "</method>"
43 "<method name=\"OpenUri\">"
44 "<arg direction=\"in\" type=\"s\" name=\"Uri\"/>"
45 "</method>"
46 "<property name=\"PlaybackStatus\" type=\"s\" access=\"read\">"
47 "<annotation name=\"org.freedesktop.DBus.Property.EmitsChangedSignal\" value=\"true\"/>"
48 "</property>"
49 "<property name=\"Rate\" type=\"d\" access=\"readwrite\">"
50 "<annotation name=\"org.freedesktop.DBus.Property.EmitsChangedSignal\" value=\"true\"/>"
51 "</property>"
52 "<property name=\"Metadata\" type=\"a{sv}\" access=\"read\">"
53 "<annotation name=\"org.freedesktop.DBus.Property.EmitsChangedSignal\" value=\"true\"/>"
54 "</property>"
55 "<property name=\"Volume\" type=\"d\" access=\"readwrite\">"
56 "<annotation name=\"org.freedesktop.DBus.Property.EmitsChangedSignal\" value=\"true\"/>"
57 "</property>"
58 "<property name=\"Position\" type=\"x\" access=\"read\">"
59 "<annotation name=\"org.freedesktop.DBus.Property.EmitsChangedSignal\" value=\"false\"/>"
60 "</property>"
61 "<property name=\"MinimumRate\" type=\"d\" access=\"read\">"
62 "<annotation name=\"org.freedesktop.DBus.Property.EmitsChangedSignal\" value=\"true\"/>"
63 "</property>"
64 "<property name=\"MaximumRate\" type=\"d\" access=\"read\">"
65 "<annotation name=\"org.freedesktop.DBus.Property.EmitsChangedSignal\" value=\"true\"/>"
66 "</property>"
67 "<property name=\"CanGoNext\" type=\"b\" access=\"read\">"
68 "<annotation name=\"org.freedesktop.DBus.Property.EmitsChangedSignal\" value=\"true\"/>"
69 "</property>"
70 "<property name=\"CanGoPrevious\" type=\"b\" access=\"read\">"
71 "<annotation name=\"org.freedesktop.DBus.Property.EmitsChangedSignal\" value=\"true\"/>"
72 "</property>"
73 "<property name=\"CanPlay\" type=\"b\" access=\"read\">"
74 "<annotation name=\"org.freedesktop.DBus.Property.EmitsChangedSignal\" value=\"true\"/>"
75 "</property>"
76 "<property name=\"CanPause\" type=\"b\" access=\"read\">"
77 "<annotation name=\"org.freedesktop.DBus.Property.EmitsChangedSignal\" value=\"true\"/>"
78 "</property>"
79 "<property name=\"CanSeek\" type=\"b\" access=\"read\">"
80 "<annotation name=\"org.freedesktop.DBus.Property.EmitsChangedSignal\" value=\"true\"/>"
81 "</property>"
82 "<property name=\"CanControl\" type=\"b\" access=\"read\">"
83 "<annotation name=\"org.freedesktop.DBus.Property.EmitsChangedSignal\" value=\"false\"/>"
84 "</property>"
85 "<signal name=\"Seeked\">"
86 "<arg name=\"Position\" type=\"x\"/>"
87 "</signal>"
88 "</interface>"
89 "</node>";
91 #endif // WIDGET_GTK_MPRIS_INTERFACE_DESCRIPTION_H_