summaryrefslogtreecommitdiffstats
path: root/video/out/wayland_common.h
diff options
context:
space:
mode:
authorDudemanguy <random342@airmail.cc>2021-08-10 21:17:42 -0500
committerDudemanguy <random342@airmail.cc>2021-09-28 16:54:09 +0000
commit2d348980cbbb8a1d4f547c0cf5b09bd8d9208a0f (patch)
treeda4e5afa306bc31ae4fa566d92cf2381f23cc3b3 /video/out/wayland_common.h
parent940f8715141dfb133ff34f6899608a379f8be5ca (diff)
downloadmpv-2d348980cbbb8a1d4f547c0cf5b09bd8d9208a0f.tar.bz2
mpv-2d348980cbbb8a1d4f547c0cf5b09bd8d9208a0f.tar.xz
wayland: further xdg-decoration/border refinements
The value of the border option should always match what the actual state of the window is. Previously if a compositor rejected the request by mpv, it did not correct itself. Also add some code to keep track of decoration requests. Anytime the state is changed, make the last saved request again (doesn't hurt and seems like intuitive behavior). Unfortunately, this isn't foolproof since options only send callback if the value is changed. (ex. on sway if the floating window has no border, and then is titled, setting the border value to "yes" does nothing since tiling the window already set the border value to "yes").
Diffstat (limited to 'video/out/wayland_common.h')
-rw-r--r--video/out/wayland_common.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/video/out/wayland_common.h b/video/out/wayland_common.h
index f833a8a0de..8e9795fccf 100644
--- a/video/out/wayland_common.h
+++ b/video/out/wayland_common.h
@@ -79,6 +79,7 @@ struct vo_wayland_state {
/* xdg-decoration */
struct zxdg_decoration_manager_v1 *xdg_decoration_manager;
struct zxdg_toplevel_decoration_v1 *xdg_toplevel_decoration;
+ int requested_decoration;
/* xdg-shell */
struct xdg_wm_base *wm_base;