Commit f4ebb1b3 authored by Gildas Bazin's avatar Gildas Bazin

Restore cursor when closing vout since the window doesn't belong to us

parent 23e13928
...@@ -417,6 +417,13 @@ static void Close (vlc_object_t *obj) ...@@ -417,6 +417,13 @@ static void Close (vlc_object_t *obj)
glXMakeCurrent (dpy, None, NULL); glXMakeCurrent (dpy, None, NULL);
glXDestroyContext (dpy, sys->ctx); glXDestroyContext (dpy, sys->ctx);
} }
/* show the default cursor */
xcb_change_window_attributes (XGetXCBConnection (sys->display),
sys->embed->handle.xid, XCB_CW_CURSOR,
&(uint32_t) { XCB_CURSOR_NONE });
xcb_flush (XGetXCBConnection (sys->display));
XCloseDisplay (dpy); XCloseDisplay (dpy);
vout_display_DeleteWindow (vd, sys->embed); vout_display_DeleteWindow (vd, sys->embed);
free (sys); free (sys);
......
...@@ -310,6 +310,12 @@ static void Close (vlc_object_t *obj) ...@@ -310,6 +310,12 @@ static void Close (vlc_object_t *obj)
vout_display_sys_t *p_sys = vd->sys; vout_display_sys_t *p_sys = vd->sys;
ResetPictures (vd); ResetPictures (vd);
/* show the default cursor */
xcb_change_window_attributes (p_sys->conn, p_sys->embed->handle.xid, XCB_CW_CURSOR,
&(uint32_t) { XCB_CURSOR_NONE });
xcb_flush (p_sys->conn);
/* colormap, window and context are garbage-collected by X */ /* colormap, window and context are garbage-collected by X */
xcb_disconnect (p_sys->conn); xcb_disconnect (p_sys->conn);
vout_display_DeleteWindow (vd, p_sys->embed); vout_display_DeleteWindow (vd, p_sys->embed);
......
...@@ -560,6 +560,11 @@ static void Close (vlc_object_t *obj) ...@@ -560,6 +560,11 @@ static void Close (vlc_object_t *obj)
picture_pool_Delete (p_sys->pool); picture_pool_Delete (p_sys->pool);
} }
/* show the default cursor */
xcb_change_window_attributes (p_sys->conn, p_sys->embed->handle.xid, XCB_CW_CURSOR,
&(uint32_t) { XCB_CURSOR_NONE });
xcb_flush (p_sys->conn);
free (p_sys->att); free (p_sys->att);
xcb_disconnect (p_sys->conn); xcb_disconnect (p_sys->conn);
vout_display_DeleteWindow (vd, p_sys->embed); vout_display_DeleteWindow (vd, p_sys->embed);
......
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