]> git.sesse.net Git - vlc/commitdiff
* skins2/src/vlcproc.cpp: a few cleanup fixes.
authorGildas Bazin <gbazin@videolan.org>
Tue, 18 May 2004 14:50:19 +0000 (14:50 +0000)
committerGildas Bazin <gbazin@videolan.org>
Tue, 18 May 2004 14:50:19 +0000 (14:50 +0000)
* wxwindows/*: a few cleanup fixes.

modules/gui/skins2/src/vlcproc.cpp
modules/gui/wxwindows/bookmarks.cpp
modules/gui/wxwindows/video.cpp

index c6e9ec281115ed9689b4bd7b20bb5ff36b49732f..093f87f211d2087731c89182577133b229428215 100755 (executable)
@@ -56,8 +56,8 @@ void VlcProc::destroy( intf_thread_t *pIntf )
 }
 
 
-VlcProc::VlcProc( intf_thread_t *pIntf ): SkinObject( pIntf ), m_pVoutWindow( NULL ),
-    m_pVout( NULL )
+VlcProc::VlcProc( intf_thread_t *pIntf ): SkinObject( pIntf ),
+                  m_pVoutWindow( NULL ), m_pVout( NULL )
 {
     // Create a timer to poll the status of the vlc
     OSFactory *pOsFactory = OSFactory::instance( pIntf );
@@ -117,6 +117,18 @@ VlcProc::~VlcProc()
     {
         vlc_object_release( getIntf()->p_sys->p_input );
     }
+
+    // Callbacks for vout requests
+    getIntf()->pf_request_window = NULL;
+    getIntf()->pf_release_window = NULL;
+    getIntf()->pf_control_window = NULL;
+
+    var_DelCallback( getIntf()->p_sys->p_playlist, "intf-change",
+                     onIntfChange, this );
+    var_DelCallback( getIntf()->p_sys->p_playlist, "playlist-current",
+                     onPlaylistChange, this );
+    var_DelCallback( getIntf()->p_sys->p_playlist, "item-change",
+                     onItemChange, this );
 }
 
 
index 4973a3ddee05b6c4b9e09522c8d24fdbc638fb27..5b907ade64ad2aa069a76bc944940f8f7a80dd8a 100644 (file)
@@ -2,7 +2,7 @@
  * bookmarks.cpp : wxWindows plugin for vlc
  *****************************************************************************
  * Copyright (C) 2000-2004 VideoLAN
- * $Id: bookmarks.cpp 6961 2004-03-05 17:34:23Z sam $
+ * $Id$
  *
  * Authors: Gildas Bazin <gbazin@videolan.org>
  *
@@ -167,9 +167,8 @@ BookmarksDialog::~BookmarksDialog()
                                        FIND_ANYWHERE );
     if( p_playlist )
     {
-       /* Some global changes happened -> Rebuild all */
-       var_DelCallback( p_playlist, "intf-change", PlaylistChanged, this );
-
+       var_DelCallback( p_playlist, "playlist-current",
+                        PlaylistChanged, this );
        vlc_object_release( p_playlist );
     }
 }
index 96751a5579edb48464025d9b58419c5e7f18e5cd..e8e6f0d99007c57031f2a41fd8d92dd5f9645c29 100644 (file)
@@ -130,6 +130,10 @@ VideoWindow::~VideoWindow()
         if( vout_Control( p_vout, VOUT_REPARENT ) != VLC_SUCCESS )
             vout_Control( p_vout, VOUT_CLOSE );
     }
+
+    p_intf->pf_request_window = NULL;
+    p_intf->pf_release_window = NULL;
+    p_intf->pf_control_window = NULL;
     vlc_mutex_unlock( &lock );
 
     vlc_mutex_destroy( &lock );