]> git.sesse.net Git - vlc/commitdiff
* src/interface/interface.c, modules/gui/wxwindows/video.cpp: couple of fixes.
authorGildas Bazin <gbazin@videolan.org>
Sat, 5 Jun 2004 18:04:06 +0000 (18:04 +0000)
committerGildas Bazin <gbazin@videolan.org>
Sat, 5 Jun 2004 18:04:06 +0000 (18:04 +0000)
modules/gui/wxwindows/video.cpp
src/interface/interface.c

index 4cded777700a0b3c85468c2040a4a791569244b9..fd5f65f2bbf0d9b3bf257816a7d515f27faef237 100644 (file)
@@ -128,11 +128,15 @@ VideoWindow::~VideoWindow()
     if( p_vout )
     {
         if( !p_intf->psz_switch_intf )
+        {
             if( vout_Control( p_vout, VOUT_CLOSE ) != VLC_SUCCESS )
                 vout_Control( p_vout, VOUT_REPARENT );
+        }
         else
+        {
             if( vout_Control( p_vout, VOUT_REPARENT ) != VLC_SUCCESS )
                 vout_Control( p_vout, VOUT_CLOSE );
+        }
     }
 
     p_intf->pf_request_window = NULL;
index d676ba852753bbbc7e89700bfe806b6cee32644a..3e34e12521e5eed55b22d036b679c70166ff82eb 100644 (file)
@@ -316,13 +316,13 @@ static void RunInterface( intf_thread_t *p_intf )
             break;
         }
 
+        /* Make sure the old interface is completely uninitialized */
+        module_Unneed( p_intf, p_intf->p_module );
+
         /* Provide ability to switch the main interface on the fly */
         psz_intf = p_intf->psz_switch_intf;
         p_intf->psz_switch_intf = NULL;
 
-        /* Make sure the old interface is completely uninitialized */
-        module_Unneed( p_intf, p_intf->p_module );
-
         vlc_mutex_lock( &p_intf->object_lock );
         p_intf->b_die = VLC_FALSE;
         p_intf->b_dead = VLC_FALSE;