[vlc-devel] [PATCH 4/4] kva: assume VOUT_DISPLAY_CHANGE_FULLSCREEN is only called to set fullscreen

Steve Lhomme robux4 at ycbcr.xyz
Wed Sep 2 12:08:52 CEST 2020


It's supposed to be handled in the window, not in the display module.

It's likely broken at this stage.
---
 include/vlc_vout_display.h | 2 +-
 modules/video_output/kva.c | 5 ++---
 src/video_output/display.c | 3 +--
 3 files changed, 4 insertions(+), 6 deletions(-)

diff --git a/include/vlc_vout_display.h b/include/vlc_vout_display.h
index 8709604897c..a4d9e431c69 100644
--- a/include/vlc_vout_display.h
+++ b/include/vlc_vout_display.h
@@ -162,7 +162,7 @@ enum vout_display_query {
 #if defined(__OS2__)
     /* Ask the module to acknowledge/refuse the fullscreen state change after
      * being requested (externally or by VOUT_DISPLAY_EVENT_FULLSCREEN */
-    VOUT_DISPLAY_CHANGE_FULLSCREEN VLC_DEPRECATED_ENUM,     /* bool fs */
+    VOUT_DISPLAY_CHANGE_FULLSCREEN VLC_DEPRECATED_ENUM,
     /* Ask the module to acknowledge/refuse the window management state change
      * after being requested externally or by VOUT_DISPLAY_WINDOW_STATE */
     VOUT_DISPLAY_CHANGE_WINDOW_STATE VLC_DEPRECATED_ENUM,
diff --git a/modules/video_output/kva.c b/modules/video_output/kva.c
index 7a2b0bc5112..f438ac70e1b 100644
--- a/modules/video_output/kva.c
+++ b/modules/video_output/kva.c
@@ -393,15 +393,14 @@ static void Display( vout_display_t *vd, picture_t *picture )
  *****************************************************************************/
 static int Control( vout_display_t *vd, int query, va_list args )
 {
+    VLC_UNUSED(args);
     vout_display_sys_t *sys = vd->sys;
 
     switch (query)
     {
     case VOUT_DISPLAY_CHANGE_FULLSCREEN:
     {
-        bool fs = va_arg(args, int);
-
-        WinPostMsg( sys->client, WM_VLC_FULLSCREEN_CHANGE, MPFROMLONG(fs), 0 );
+        WinPostMsg( sys->client, WM_VLC_FULLSCREEN_CHANGE, MPFROMLONG(true), 0 );
         return VLC_SUCCESS;
     }
 
diff --git a/src/video_output/display.c b/src/video_output/display.c
index a435460b099..ea7aaa023c7 100644
--- a/src/video_output/display.c
+++ b/src/video_output/display.c
@@ -754,8 +754,7 @@ vout_display_t *vout_display_New(vlc_object_t *parent,
 #if defined(__OS2__)
     if ((var_GetBool(parent, "fullscreen")
       || var_GetBool(parent, "video-wallpaper"))
-     && vout_display_Control(vd, VOUT_DISPLAY_CHANGE_FULLSCREEN,
-                             true) == VLC_SUCCESS)
+     && vout_display_Control(vd, VOUT_DISPLAY_CHANGE_FULLSCREEN) == VLC_SUCCESS)
         osys->cfg.is_fullscreen = true;
 
     if (var_InheritBool(parent, "video-on-top"))
-- 
2.26.2



More information about the vlc-devel mailing list