From c2bd3b1eccd90c6b579e6661ffc2d077119508c2 Mon Sep 17 00:00:00 2001 From: Philip Langdale Date: Tue, 26 Nov 2019 08:46:47 +0800 Subject: 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. --- video/out/vo.h | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'video/out') 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 -- cgit v1.2.3