[MPlayer-dev-eng] [PATCH] double click to switch to full screen in GUI

laurent wozniak laurent.wozniak at laposte.net
Sat Sep 30 15:59:36 CEST 2006


Hello,

Diego Biurrun wrote:
>> --- Gui/interface.c	(revision 19814)
>> +++ Gui/interface.c	(working copy)
>> @@ -217,6 +218,10 @@
>>   if ( autosync && autosync != gtkAutoSync ) { gtkAutoSyncOn=1; gtkAutoSync=autosync; }
>>     
>>   gtkInit();
>> +// --- initialize some input constants 
>> + g_object_get ( G_OBJECT ( gtk_settings_get_default() ), 
>> +    "gtk-double-click-time", &double_click_time, NULL );
>> + mp_input_set_double_click_time(double_click_time);
>>     
>
> IIUC you're querying for the GTK default doubleclick time here.  I'm not
> 100% convinced this is what we want.  The GUI depends on GTK, but it's
> not really a full-blown GTK application..
In this case, this is an override of the default hard-coded double click 
time value.
This double click time itself is only mandatory for platforms that don't 
provide double click events, others will ignore it.
ex: used with X11, ignored with DX.
Initially it is set to an acceptable default value, then I try to adapt 
to the current window system.
I think GTK is encapsulating the way to retrieve this value for me.
Anyway, a GUI not using GTK on X11 (on Windows or Mac, this value would 
be read but not used) could call "mp_input_set_double_click_time" if it 
knows a better way to get this value.
With GNome and X11, this is the best way to retrieve the value.
With KDE and X11, I'm not sure and should be tested.

Cheers,
Laurent



More information about the MPlayer-dev-eng mailing list