Commit 5de19c37 authored by Mirsal Ennaime's avatar Mirsal Ennaime

dbus: fix the CanSetFullscreen property getter

Make org.mpris.MediaPlayer2.CanSetFullscreen true only when
a vout thread is running.
parent 34f86346
......@@ -101,7 +101,18 @@ DBUS_METHOD( Identity )
static int
MarshalCanSetFullscreen( intf_thread_t *p_intf, DBusMessageIter *container )
{
const dbus_bool_t b_ret = (p_intf->p_sys->p_playlist) ? TRUE : FALSE;
input_thread_t *p_input = NULL;
dbus_bool_t b_ret = FALSE;
if (p_intf->p_sys->p_input)
{
p_input = (input_thread_t*) vlc_object_hold( p_intf->p_sys->p_input );
vout_thread_t* p_vout = input_GetVout( p_input );
vlc_object_release( p_input );
if ( p_vout )
b_ret = TRUE;
}
dbus_message_iter_append_basic( container, DBUS_TYPE_BOOLEAN, &b_ret );
return VLC_SUCCESS;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment