Commit ab6349c9 authored by Rémi Denis-Courmont's avatar Rémi Denis-Courmont

window: add info struct and double click flag

Like display plugins before, window plugins need to be handled
differently if they emit double click events than not.
parent 320a0241
...@@ -147,6 +147,11 @@ struct vout_window_t { ...@@ -147,6 +147,11 @@ struct vout_window_t {
*/ */
int (*control)(vout_window_t *, int query, va_list); int (*control)(vout_window_t *, int query, va_list);
struct {
bool has_double_click; /**< Whether double click events are sent,
or need to be emulated */
} info;
/* Private place holder for the vout_window_t module (optional) /* Private place holder for the vout_window_t module (optional)
* *
* A module is free to use it as it wishes. * A module is free to use it as it wishes.
......
...@@ -755,6 +755,7 @@ static int WindowOpen( vout_window_t *p_wnd, const vout_window_cfg_t *cfg ) ...@@ -755,6 +755,7 @@ static int WindowOpen( vout_window_t *p_wnd, const vout_window_cfg_t *cfg )
if( !p_mi->getVideo( p_wnd, cfg->width, cfg->height, cfg->is_fullscreen ) ) if( !p_mi->getVideo( p_wnd, cfg->width, cfg->height, cfg->is_fullscreen ) )
return VLC_EGENERIC; return VLC_EGENERIC;
p_wnd->info.has_double_click = true;
p_wnd->control = WindowControl; p_wnd->control = WindowControl;
p_wnd->sys = (vout_window_sys_t*)p_mi; p_wnd->sys = (vout_window_sys_t*)p_mi;
return VLC_SUCCESS; return VLC_SUCCESS;
......
...@@ -59,6 +59,7 @@ vout_window_t *vout_window_New(vlc_object_t *obj, const char *module, ...@@ -59,6 +59,7 @@ vout_window_t *vout_window_New(vlc_object_t *obj, const char *module,
vout_window_t *window = &w->wnd; vout_window_t *window = &w->wnd;
memset(&window->handle, 0, sizeof(window->handle)); memset(&window->handle, 0, sizeof(window->handle));
window->info.has_double_click = false;
window->control = NULL; window->control = NULL;
window->sys = NULL; window->sys = NULL;
......
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