summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorwm4 <wm4@nowhere>2015-01-03 03:06:26 +0100
committerwm4 <wm4@nowhere>2015-01-03 03:06:26 +0100
commit9300351a30c7142901582ba3ddbe5b72b959bb3a (patch)
treea393a7933968da13ce56fadc87bb21b64e834b03
parentf5ed13bcd4aacd362db9da3b5ad3f8747f13d944 (diff)
downloadmpv-9300351a30c7142901582ba3ddbe5b72b959bb3a.tar.bz2
mpv-9300351a30c7142901582ba3ddbe5b72b959bb3a.tar.xz
x11: make display-names property observable
Reuse MP_EVENT_WIN_STATE for this.
-rw-r--r--player/command.c2
-rw-r--r--video/out/x11_common.c2
2 files changed, 3 insertions, 1 deletions
diff --git a/player/command.c b/player/command.c
index 9fb7c82c1c..f770d197c9 100644
--- a/player/command.c
+++ b/player/command.c
@@ -3438,7 +3438,7 @@ static const char *const *const mp_event_property_change[] = {
E(MP_EVENT_CACHE_UPDATE, "cache", "cache-free", "cache-used", "cache-idle",
"demuxer-cache-duration", "demuxer-cache-idle"),
E(MP_EVENT_WIN_RESIZE, "window-scale"),
- E(MP_EVENT_WIN_STATE, "window-minimized"),
+ E(MP_EVENT_WIN_STATE, "window-minimized", "display-names"),
};
#undef E
diff --git a/video/out/x11_common.c b/video/out/x11_common.c
index 9823570d11..75d36e15ab 100644
--- a/video/out/x11_common.c
+++ b/video/out/x11_common.c
@@ -1491,6 +1491,8 @@ static void vo_x11_update_geometry(struct vo *vo)
if (fps != x11->current_display_fps)
MP_VERBOSE(x11, "Current display FPS: %f\n", fps);
x11->current_display_fps = fps;
+ // might have changed displays
+ x11->pending_vo_events |= VO_EVENT_WIN_STATE;
}
static void vo_x11_fullscreen(struct vo *vo)