summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorwm4 <wm4@nowhere>2016-08-07 16:33:57 +0200
committerwm4 <wm4@nowhere>2016-08-07 19:33:20 +0200
commitcfed84af2be1f95a595fdff7c846248a5e3f9368 (patch)
tree80999bf11a584732b40bcd09a801a930b502f1b8
parent259f2194385e86e47eb054d43f155ca897e265c6 (diff)
downloadmpv-cfed84af2be1f95a595fdff7c846248a5e3f9368.tar.bz2
mpv-cfed84af2be1f95a595fdff7c846248a5e3f9368.tar.xz
w32_common: update window size on resize events
Fixes a regression introduced by commit 088a0075. Fixes #3400.
-rw-r--r--video/out/w32_common.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/video/out/w32_common.c b/video/out/w32_common.c
index 4934a433b2..b1c95f78d1 100644
--- a/video/out/w32_common.c
+++ b/video/out/w32_common.c
@@ -1511,6 +1511,12 @@ int vo_w32_control(struct vo *vo, int *events, int request, void *arg)
struct vo_w32_state *w32 = vo->w32;
if (request == VOCTRL_CHECK_EVENTS) {
*events |= atomic_fetch_and(&w32->event_flags, 0);
+ if (*events & VO_EVENT_RESIZE) {
+ mp_dispatch_lock(w32->dispatch);
+ vo->dwidth = w32->dw;
+ vo->dheight = w32->dh;
+ mp_dispatch_unlock(w32->dispatch);
+ }
return VO_TRUE;
} else {
int r;