mirror of https://github.com/mpv-player/mpv
Enable runtime border/window decorations-toggling for Linux gl and gl2 vos.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@27338 b3059339-0415-0410-9bf9-f77b7e298cf2
This commit is contained in:
parent
b9d2214eee
commit
983800b76f
|
@ -293,6 +293,7 @@ void glDisableYUVConversion(GLenum target, int type);
|
|||
/** \} */
|
||||
|
||||
#ifdef GL_WIN32
|
||||
#define vo_border() vo_w32_border()
|
||||
#define vo_check_events() vo_w32_check_events()
|
||||
#define vo_fullscreen() vo_w32_fullscreen()
|
||||
#define vo_ontop() vo_w32_ontop()
|
||||
|
@ -300,6 +301,7 @@ void glDisableYUVConversion(GLenum target, int type);
|
|||
int setGlWindow(int *vinfo, HGLRC *context, HWND win);
|
||||
void releaseGlContext(int *vinfo, HGLRC *context);
|
||||
#else
|
||||
#define vo_border() vo_x11_border()
|
||||
#define vo_check_events() vo_x11_check_events(mDisplay)
|
||||
#define vo_fullscreen() vo_x11_fullscreen()
|
||||
#define vo_ontop() vo_x11_ontop()
|
||||
|
|
|
@ -999,12 +999,10 @@ static int control(uint32_t request, void *data, ...)
|
|||
vo_fullscreen();
|
||||
resize(vo_dwidth, vo_dheight);
|
||||
return VO_TRUE;
|
||||
#ifdef GL_WIN32
|
||||
case VOCTRL_BORDER:
|
||||
vo_w32_border();
|
||||
vo_border();
|
||||
resize(vo_dwidth, vo_dheight);
|
||||
return VO_TRUE;
|
||||
#endif
|
||||
case VOCTRL_GET_PANSCAN:
|
||||
if (!use_aspect) return VO_NOTIMPL;
|
||||
return VO_TRUE;
|
||||
|
|
|
@ -889,11 +889,9 @@ static int control(uint32_t request, void *data, ...)
|
|||
initGl(vo_dwidth, vo_dheight);
|
||||
resize(&vo_dwidth, &vo_dheight);
|
||||
return VO_TRUE;
|
||||
#ifdef GL_WIN32
|
||||
case VOCTRL_BORDER:
|
||||
vo_w32_border();
|
||||
vo_border();
|
||||
return VO_TRUE;
|
||||
#endif
|
||||
case VOCTRL_GET_PANSCAN:
|
||||
return VO_TRUE;
|
||||
case VOCTRL_SET_PANSCAN:
|
||||
|
|
|
@ -1588,6 +1588,12 @@ void vo_x11_ontop(void)
|
|||
vo_x11_setlayer(mDisplay, vo_window, vo_ontop);
|
||||
}
|
||||
|
||||
void vo_x11_border(void)
|
||||
{
|
||||
vo_border = !vo_border;
|
||||
vo_x11_decoration(mDisplay, vo_window, vo_border && !vo_fs);
|
||||
}
|
||||
|
||||
/*
|
||||
* XScreensaver stuff
|
||||
*/
|
||||
|
|
|
@ -61,6 +61,7 @@ extern void vo_x11_clearwindow_part(Display *mDisplay, Window vo_window,
|
|||
int img_width, int img_height, int use_fs);
|
||||
extern void vo_x11_clearwindow( Display *mDisplay, Window vo_window );
|
||||
extern void vo_x11_ontop(void);
|
||||
extern void vo_x11_border(void);
|
||||
extern void vo_x11_ewmh_fullscreen( int action );
|
||||
|
||||
#endif
|
||||
|
|
Loading…
Reference in New Issue