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

Remove unused VOUT_PARENT

By the way:
 - the OSX implementation seemed buggy w.r.t. fullscreen,
 - the X11 implementation seemed buggy w.r.t. both vout_window and events,
 - the OMAPFB implementation was bogus.
parent 2b50f07b
......@@ -707,7 +707,6 @@ enum output_query_e
{
VOUT_SET_SIZE, /* arg1= unsigned int, arg2= unsigned int, res= */
VOUT_SET_STAY_ON_TOP, /* arg1= bool res= */
VOUT_REPARENT,
VOUT_SET_VIEWPORT, /* arg1= view rect, arg2=clip rect, res= */
VOUT_REDRAW_RECT, /* arg1= area rect, res= */
};
......
......@@ -779,17 +779,6 @@ static int aglControl( vout_thread_t *p_vout, int i_query, va_list args )
return VLC_SUCCESS;
}
case VOUT_REPARENT:
{
AGLDrawable drawable = (AGLDrawable)va_arg( args, int);
if( !p_vout->b_fullscreen && drawable != p_vout->p_sys->agl_drawable )
{
p_vout->p_sys->agl_drawable = drawable;
aglSetDrawable(p_vout->p_sys->agl_ctx, drawable);
}
return VLC_SUCCESS;
}
default:
return VLC_EGENERIC;
}
......
......@@ -367,17 +367,6 @@ int aglControl( vout_thread_t *p_vout, int i_query, va_list args )
return VLC_SUCCESS;
}
case VOUT_REPARENT:
{
AGLDrawable drawable = (AGLDrawable)va_arg( args, int);
if( !p_vout->b_fullscreen && drawable != p_vout->p_sys->agl_drawable )
{
p_vout->p_sys->agl_drawable = drawable;
aglSetDrawable(p_vout->p_sys->agl_ctx, drawable);
}
return VLC_SUCCESS;
}
default:
return VLC_EGENERIC;
}
......
......@@ -1062,50 +1062,6 @@ static int Control( vout_thread_t *p_vout, int i_query, va_list args )
return VLC_SUCCESS;
case VOUT_REPARENT:
/* Retrieve the window position */
point.x = point.y = 0;
ClientToScreen( p_vout->p_sys->hwnd, &point );
HWND d = 0;
if( i_query == VOUT_REPARENT ) d = (HWND)va_arg( args, int );
if( !d )
{
vlc_mutex_lock( &p_vout->p_sys->lock );
p_vout->p_sys->hparent = 0;
vlc_mutex_unlock( &p_vout->p_sys->lock );
SetParent( p_vout->p_sys->hwnd, 0 );
p_vout->p_sys->i_window_style =
WS_CLIPCHILDREN | WS_OVERLAPPEDWINDOW | WS_SIZEBOX;
SetWindowLong( p_vout->p_sys->hwnd, GWL_STYLE,
p_vout->p_sys->i_window_style | WS_VISIBLE);
SetWindowLong( p_vout->p_sys->hwnd, GWL_EXSTYLE, WS_EX_APPWINDOW );
SetWindowPos( p_vout->p_sys->hwnd, 0, point.x, point.y, 0, 0,
SWP_NOSIZE|SWP_NOZORDER|SWP_FRAMECHANGED );
}
else
{
vlc_mutex_lock( &p_vout->p_sys->lock );
p_vout->p_sys->hparent = d;
vlc_mutex_unlock( &p_vout->p_sys->lock );
SetParent( p_vout->p_sys->hwnd, d );
p_vout->p_sys->i_window_style = WS_CLIPCHILDREN;
SetWindowLong( p_vout->p_sys->hwnd, GWL_STYLE,
p_vout->p_sys->i_window_style | WS_VISIBLE);
SetWindowLong( p_vout->p_sys->hwnd, GWL_EXSTYLE, WS_EX_APPWINDOW );
/* Retrieve the parent size */
RECT rect;
GetClientRect( d, &rect );
SetWindowPos( p_vout->p_sys->hwnd, d, point.x, point.y, rect.right, rect.bottom,
SWP_FRAMECHANGED );
}
vout_ReleaseWindow( p_vout->p_sys->parent_window );
return VLC_SUCCESS;
case VOUT_SET_STAY_ON_TOP:
if( p_vout->p_sys->hparent && !var_GetBool( p_vout, "fullscreen" ) )
return vaControlParentWindow( p_vout, i_query, args );
......
......@@ -373,14 +373,7 @@ static void End( vout_thread_t *p_vout )
*****************************************************************************/
static int Control( vout_thread_t *p_vout, int i_query, va_list args )
{
switch( i_query )
{
case VOUT_REPARENT:
vout_ReleaseWindow( p_vout->p_sys->owner_window );
return VLC_SUCCESS;
default:
return VLC_EGENERIC;
}
return VLC_EGENERIC;
}
/*****************************************************************************
......
......@@ -3150,30 +3150,6 @@ static int Control( vout_thread_t *p_vout, int i_query, va_list args )
#endif
return VLC_SUCCESS;
case VOUT_REPARENT:
if( i_query == VOUT_REPARENT ) d = (Drawable)va_arg( args, int );
if( !d )
{
#ifdef MODULE_NAME_IS_xvmc
xvmc_context_reader_lock( &p_vout->p_sys->xvmc_lock );
#endif
XReparentWindow( p_vout->p_sys->p_display,
p_vout->p_sys->original_window.base_window,
DefaultRootWindow( p_vout->p_sys->p_display ),
0, 0 );
}
else
XReparentWindow( p_vout->p_sys->p_display,
p_vout->p_sys->original_window.base_window,
d, 0, 0);
XSync( p_vout->p_sys->p_display, False );
#ifdef MODULE_NAME_IS_xvmc
xvmc_context_reader_unlock( &p_vout->p_sys->xvmc_lock );
#endif
vout_ReleaseWindow( p_vout->p_sys->p_win->owner_window );
p_vout->p_sys->original_window.owner_window = NULL;
return VLC_SUCCESS;
case VOUT_SET_STAY_ON_TOP:
if( p_vout->p_sys->p_win->owner_window )
return vout_ControlWindow( p_vout->p_sys->p_win->owner_window,
......
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