# HG changeset patch # User ib # Date 1316610904 0 # Node ID 83a80dedac69868580442434bc40b37bd3dbbdc7 # Parent 7880ad51d461f2f9e92b75462291184c5ea323a4 Don't hide or show cursor if attached to an existing window. This gives the application owning the window the control of the cursor. diff -r 7880ad51d461 -r 83a80dedac69 Changelog --- a/Changelog Wed Sep 21 09:53:12 2011 +0000 +++ b/Changelog Wed Sep 21 13:15:04 2011 +0000 @@ -16,6 +16,7 @@ * support adding noise at output resolution with -vo gl:noise-strength=8 * experimental support for PGS (BluRay-compatible), DVB and XSUB subtitles. * experimental af_cmdline slave command to change e.g. audio equalizer options at runtime. + * vo x11: don't hide or show cursor any more if attached to an existing window (-wid) MEncoder: * -force-key-frames option to set explicit seek points. diff -r 7880ad51d461 -r 83a80dedac69 libvo/x11_common.c --- a/libvo/x11_common.c Wed Sep 21 09:53:12 2011 +0000 +++ b/libvo/x11_common.c Wed Sep 21 13:15:04 2011 +0000 @@ -184,8 +184,8 @@ Colormap colormap; static char bm_no_data[] = { 0, 0, 0, 0, 0, 0, 0, 0 }; - if (WinID == 0) - return; // do not hide if playing on the root window + if (WinID >= 0) + return; // do not hide if attached to an existing window colormap = DefaultColormap(disp, DefaultScreen(disp)); if ( !XAllocNamedColor(disp, colormap, "black", &black, &dummy) ) @@ -203,8 +203,8 @@ static void vo_showcursor(Display * disp, Window win) { - if (WinID == 0) - return; + if (WinID >= 0) + return; // do not show if attached to an existing window XDefineCursor(disp, win, 0); }