summaryrefslogtreecommitdiffstats
path: root/video/out
diff options
context:
space:
mode:
authorPhilip Langdale <philipl@overt.org>2019-11-26 08:46:47 +0800
committerPhilip Langdale <github.philipl@overt.org>2019-11-29 16:56:20 +0800
commitc2bd3b1eccd90c6b579e6661ffc2d077119508c2 (patch)
treea64cf82dba2380a5107040953fef382b8609fccf /video/out
parentf3c2f1f6aa969001a74455061637cc7e194f614a (diff)
downloadmpv-c2bd3b1eccd90c6b579e6661ffc2d077119508c2.tar.bz2
mpv-c2bd3b1eccd90c6b579e6661ffc2d077119508c2.tar.xz
command: add `window-maximized` and make `window-minimized` settable
If we want to implement window pseudo-decorations via OSC, we need a way to tell the vo to minimize and maximize the window. Today, we have minimized as a read-only property, and no property for maximized. Let's made minimized settable and add a maximized property to go with it. In turn, that requires us to add VOCTRLs for minimizing or maximizing a window, and an additional WIN_STATE to indicate a maximized window.
Diffstat (limited to 'video/out')
-rw-r--r--video/out/vo.h6
1 files changed, 5 insertions, 1 deletions
diff --git a/video/out/vo.h b/video/out/vo.h
index 08ca1219a1..a02412a8ea 100644
--- a/video/out/vo.h
+++ b/video/out/vo.h
@@ -126,10 +126,14 @@ enum mp_voctrl {
/* private to vo_gpu */
VOCTRL_EXTERNAL_RESIZE,
+
+ VOCTRL_MAXIMIZE,
+ VOCTRL_MINIMIZE,
};
// VOCTRL_GET_WIN_STATE
-#define VO_WIN_STATE_MINIMIZED 1
+#define VO_WIN_STATE_MINIMIZED (1 << 0)
+#define VO_WIN_STATE_MAXIMIZED (1 << 1)
#define VO_TRUE true
#define VO_FALSE false