[dbus] Add target mode signaling. JB#44479
Some transitions such as activating mtp mode can take so long that giving
user feedback becomes necessary. However as usb-moded exposes only what
has happened, there is no reliable source of information for what is
going on.
Also, the "sig_usb_state_ind" D-Bus signal is used for transmitting both
mode change notifications and transient events - which is confusing and
can cause problems if new signals are ever added as there is no backwards
compatible ways to tell apart mode names from event names.
Add dbus query / change notifications for target mode. The target mode
is changed before starting mode transition, so that processes listening
to signals from usb-moded know what kind of transition is happening when
the current mode changes to "busy".
Add separate dbus signals for mode changes and events. The legacy
"sig_usb_state_ind" is retained as-is for the sake of backwards
compatibility.
Also synchronize the content of D-Bus Introspect xml data provided as
a file in development package and made available at runtime via D-Bus
method call.
Signed-off-by:
Simo Piiroinen <simo.piiroinen@jollamobile.com>
Showing
Please register or sign in to comment