[MPlayer-cvslog] r38638 - trunk/gui/interface.c

ib subversion at mplayerhq.hu
Sat Aug 24 20:33:09 EEST 2024


Author: ib
Date: Sat Aug 24 20:33:09 2024
New Revision: 38638

Log:
Fix lost full screen mode and lost video menu items.

This all disappeared in svn r38514, where the video driver for the GUI
was no longer implicitly set, and without a specified video driver,
GUI_PREPARE could not decide if there would be a video window.

This is now determined later at GUI_SET_VIDEO when a video output driver
is finally set.

Modified:
   trunk/gui/interface.c

Modified: trunk/gui/interface.c
==============================================================================
--- trunk/gui/interface.c	Wed Jul  3 11:56:50 2024	(r38637)
+++ trunk/gui/interface.c	Sat Aug 24 20:33:09 2024	(r38638)
@@ -646,18 +646,7 @@ int gui(int what, void *data)
 
         /* video opts */
 
-        {
-            int i = 0;
-
-            guiInfo.VideoWindow = False;
-
-            while (video_out_drivers[i++]) {
-                if ((video_driver_list && !gstrcmp(video_driver_list[0], video_out_drivers[i - 1]->info->short_name)) && (video_out_drivers[i - 1]->control(VOCTRL_GUISUPPORT, NULL) == VO_TRUE)) {
-                    guiInfo.VideoWindow = True;
-                    break;
-                }
-            }
-        }
+        guiInfo.VideoWindow = False;
 
         if (video_driver_list && !gstrcmp(video_driver_list[0], "dxr3"))
             if (guiInfo.StreamType != STREAMTYPE_DVD && guiInfo.StreamType != STREAMTYPE_VCD)
@@ -904,6 +893,20 @@ int gui(int what, void *data)
         btnSet(evBackward10min, state);
         btnSet(evSetMoviePosition, state);
 
+        if (guiInfo.mpcontext->video_out) {
+            const char *short_name;
+            int i = 0;
+
+            short_name = guiInfo.mpcontext->video_out->info->short_name;
+
+            while (video_out_drivers[i++]) {
+                if (gstrcmp(short_name, video_out_drivers[i - 1]->info->short_name) == 0 && video_out_drivers[i - 1]->control(VOCTRL_GUISUPPORT, NULL) == VO_TRUE) {
+                    guiInfo.VideoWindow = True;
+                    break;
+                }
+            }
+        }
+
         if (video_driver_list && !gstrcmp(video_driver_list[0], "dxr3") && (guiInfo.mpcontext->demuxer->file_format != DEMUXER_TYPE_MPEG_PS) && !gtkVfLAVC) {
             gtkMessageBox(MSGBOX_FATAL, _(MSGTR_GUI_MSG_DXR3NeedsLavc));
             return False;


More information about the MPlayer-cvslog mailing list