x11_common: avoid unnecessary XUnmapWindow() call

XDestroyWindow() is called immediately after, which also unmaps window
if needed. according to the manpage:

> If the window specified by the w argument is mapped, it is unmapped
> automatically.
This commit is contained in:
NRK 2023-06-29 03:02:22 +06:00 committed by Dudemanguy
parent e85d70f84f
commit 5d2d7cde8e
1 changed files with 1 additions and 3 deletions

View File

@ -834,10 +834,8 @@ void vo_x11_uninit(struct vo *vo)
set_screensaver(x11, true);
if (x11->window != None && x11->window != x11->rootwin) {
XUnmapWindow(x11->display, x11->window);
if (x11->window != None && x11->window != x11->rootwin)
XDestroyWindow(x11->display, x11->window);
}
if (x11->xic)
XDestroyIC(x11->xic);
if (x11->colormap != None)