[vlc-commits] display: set on-top state immediately

Rémi Denis-Courmont git at videolan.org
Mon Dec 31 17:40:21 CET 2018


vlc | branch: master | Rémi Denis-Courmont <remi at remlab.net> | Sun Dec 30 21:38:18 2018 +0200| [5fcabf7775f60290c38eeefa53e1d389a7fb3eb5] | committer: Rémi Denis-Courmont

display: set on-top state immediately

Do not postpone until the first manage poll event.

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=5fcabf7775f60290c38eeefa53e1d389a7fb3eb5
---

 src/video_output/display.c | 9 ++++++---
 1 file changed, 6 insertions(+), 3 deletions(-)

diff --git a/src/video_output/display.c b/src/video_output/display.c
index d9acf089af..c17716a581 100644
--- a/src/video_output/display.c
+++ b/src/video_output/display.c
@@ -965,9 +965,6 @@ static vout_display_t *DisplayNew(vout_thread_t *vout,
 
 #if defined(_WIN32) || defined(__OS2__)
     osys->is_fullscreen  = osys->cfg.is_fullscreen;
-    osys->wm_state = var_InheritBool(vout, "video-on-top")
-                     ? VOUT_WINDOW_STATE_ABOVE : VOUT_WINDOW_STATE_NORMAL;
-    osys->ch_wm_state = true;
 #endif
 
     osys->source = *source;
@@ -1000,6 +997,12 @@ static vout_display_t *DisplayNew(vout_thread_t *vout,
 
         vout_window_SetSize(osys->cfg.window,
                             osys->cfg.display.width, osys->cfg.display.height);
+
+#if defined(_WIN32) || defined(__OS2__)
+        if (var_InheritBool(vout, "video-on-top"))
+            vout_display_Control(vd, VOUT_DISPLAY_CHANGE_WINDOW_STATE,
+                                 (unsigned)VOUT_WINDOW_STATE_ABOVE);
+#endif
     } else {
         video_format_Copy(&vd->fmt, &vd->source);
         vd->module = NULL;



More information about the vlc-commits mailing list