]> git.sesse.net Git - vlc/blobdiff - modules/misc/qte_main.cpp
* finally use the iTunes volumeslider knob that we have had since 0.7.0 but which...
[vlc] / modules / misc / qte_main.cpp
index 158679aa0d7d4bef34c92cabbe4ca805f6cd4f21..a0de625e93340440401f9c5adb2a2f9e4a364f80 100644 (file)
@@ -1,7 +1,7 @@
 /*****************************************************************************
  * qte_main.c : QT Embedded wrapper for gte_main
  *****************************************************************************
- * Copyright (C) 2003 VideoLAN
+ * Copyright (C) 2003 the VideoLAN team
  * $Id$
  *
  * Authors: Jean-Paul Saman <jpsaman@wxs.nl>
@@ -116,6 +116,9 @@ static int Open( vlc_object_t *p_this )
     i_refcount++;
     vlc_mutex_unlock( (vlc_mutex_t *) lockval.p_address );
 
+    vlc_object_attach( p_qte_main, p_this );
+    msg_Dbg( p_this, "qte_main running" );
+
     return VLC_SUCCESS;
 }
 
@@ -143,6 +146,9 @@ static void Close( vlc_object_t *p_this )
     delete p_qte_main->p_qte_widget;
     delete p_qte_main->p_qte_application;
 
+    msg_Dbg( p_this, "Detaching qte_main" );
+    vlc_object_detach( p_qte_main );
+
     vlc_object_destroy( p_qte_main );
     p_qte_main = NULL;
 
@@ -175,15 +181,12 @@ static void QteMain( qte_thread_t *p_this )
         p_this->p_qte_application = pApp;
     }
 
-    QWidget* pWidget = new QWidget();
+    QWidget* pWidget = new QWidget(0, _("video") );
     if(pWidget)
     {
         p_this->p_qte_widget = pWidget;
     }
 
-    if (p_this->b_gui_server) {
-        p_this->p_qte_application->desktop()->setFixedSize(240, 320);
-    }
     /* signal the creation of the window */
     p_this->p_qte_application->setMainWidget(p_this->p_qte_widget);
     p_this->p_qte_widget->show();