[vlc-devel] [PATCH 2/2] dbus: Correct introspection data

FeRD (Frank Dana) ferdnyc at gmail.com
Tue Apr 23 05:20:38 CEST 2019


The MPRIS2 introspection metadata contained several errors and
omissions inconsistent with the official MPRIS2.2 spec:
- The Player.Position property should be type 'x', not 'i'
- The Player.Shuffle property should be type 'b', not 'd'
- The Player.{Minimum,Maximum}Rate properties should be read-only,
  not read-write
- The Player.CanGo{Next,Previous} properties were not declared,
  despite being implemented
- The Player.Seeked signal was not declared, despite being emitted
---
 modules/control/dbus/dbus_introspect.h | 13 +++++++++----
 1 file changed, 9 insertions(+), 4 deletions(-)

diff --git a/modules/control/dbus/dbus_introspect.h b/modules/control/dbus/dbus_introspect.h
index edd3caebb4..24e5a56809 100644
--- a/modules/control/dbus/dbus_introspect.h
+++ b/modules/control/dbus/dbus_introspect.h
@@ -78,12 +78,14 @@ static const char* psz_introspection_xml =
 "    <property name=\"PlaybackStatus\" type=\"s\" access=\"read\" />\n"
 "    <property name=\"LoopStatus\" type=\"s\" access=\"readwrite\" />\n"
 "    <property name=\"Rate\" type=\"d\" access=\"readwrite\" />\n"
-"    <property name=\"Shuffle\" type=\"d\" access=\"readwrite\" />\n"
+"    <property name=\"Shuffle\" type=\"b\" access=\"readwrite\" />\n"
 "    <property name=\"Metadata\" type=\"a{sv}\" access=\"read\" />\n"
 "    <property name=\"Volume\" type=\"d\" access=\"readwrite\" />\n"
-"    <property name=\"Position\" type=\"i\" access=\"read\" />\n"
-"    <property name=\"MinimumRate\" type=\"d\" access=\"readwrite\" />\n"
-"    <property name=\"MaximumRate\" type=\"d\" access=\"readwrite\" />\n"
+"    <property name=\"Position\" type=\"x\" access=\"read\" />\n"
+"    <property name=\"MinimumRate\" type=\"d\" access=\"read\" />\n"
+"    <property name=\"MaximumRate\" type=\"d\" access=\"read\" />\n"
+"    <property name=\"CanGoNext\" type=\"b\" access=\"read\" />\n"
+"    <property name=\"CanGoPrevious\" type=\"b\" access=\"read\" />\n"
 "    <property name=\"CanPlay\" type=\"b\" access=\"read\" />\n"
 "    <property name=\"CanPause\" type=\"b\" access=\"read\" />\n"
 "    <property name=\"CanSeek\" type=\"b\" access=\"read\" />\n"
@@ -104,6 +106,9 @@ static const char* psz_introspection_xml =
 "    <method name=\"OpenUri\">\n"
 "      <arg type=\"s\" direction=\"in\" />\n"
 "    </method>\n"
+"    <signal name=\"Seeked\">\n"
+"      <arg type=\"x\" />\n"
+"    </signal>\n"
 "  </interface>\n"
 "  <interface name=\"org.mpris.MediaPlayer2.TrackList\">\n"
 "    <property name=\"Tracks\" type=\"ao\" access=\"read\" />\n"
-- 
2.20.1



More information about the vlc-devel mailing list