[vlc-commits] qt: main_interface: Create the videoWidget when needed

Hugo Beauzée-Luyssen git at videolan.org
Wed Jan 24 11:07:10 CET 2018


vlc | branch: master | Hugo Beauzée-Luyssen <hugo at beauzee.fr> | Mon Jan 22 14:22:15 2018 +0100| [8da9abc69582c9792c9fb48e3cc05f74b50a3e72] | committer: Hugo Beauzée-Luyssen

qt: main_interface: Create the videoWidget when needed

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

 modules/gui/qt/main_interface.cpp | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/modules/gui/qt/main_interface.cpp b/modules/gui/qt/main_interface.cpp
index 7ad3ffa015..9c9c9c3b97 100644
--- a/modules/gui/qt/main_interface.cpp
+++ b/modules/gui/qt/main_interface.cpp
@@ -746,6 +746,11 @@ void MainInterface::getVideoSlot( struct vout_window_t *p_wnd,
         toggleUpdateSystrayMenu();
 
     /* Request the videoWidget */
+    if ( !videoWidget )
+    {
+        videoWidget = new VideoWidget( p_intf, stackCentralW );
+        stackCentralW->addWidget( videoWidget );
+    }
     *res = videoWidget->request( p_wnd );
     if( *res ) /* The videoWidget is available */
     {



More information about the vlc-commits mailing list