]> git.sesse.net Git - vlc/blobdiff - plugins/kde/kde.cpp
* ./plugins/kde/*: the KDE interface now works again.
[vlc] / plugins / kde / kde.cpp
index fa17841fe762afbfc793a6a47fe0441f63505617..92b8c65976fcef6ba3bba5cfeb0fd7588bfdcc6d 100644 (file)
@@ -2,7 +2,7 @@
  * kde.cpp : KDE plugin for vlc
  *****************************************************************************
  * Copyright (C) 2001 VideoLAN
- * $Id: kde.cpp,v 1.10 2002/03/19 00:30:44 sam Exp $
+ * $Id: kde.cpp,v 1.14 2002/07/01 17:39:27 sam Exp $
  *
  * Authors: Andres Krapf <dae@chez.com> Sun Mar 25 2001
  *
@@ -51,7 +51,7 @@ MODULE_CONFIG_START
 MODULE_CONFIG_STOP
 
 MODULE_INIT_START
-    SET_DESCRIPTION( "KDE interface module" )
+    SET_DESCRIPTION( _("KDE interface module") )
 #ifndef WIN32
     if( getenv( "DISPLAY" ) == NULL )
     {
@@ -62,7 +62,6 @@ MODULE_INIT_START
     {
         ADD_CAPABILITY( INTF, 85 )
     }
-    ADD_SHORTCUT( "kde" )
     ADD_PROGRAM( "kvlc" )
 MODULE_INIT_STOP
 
@@ -117,29 +116,15 @@ KThread::KThread(intf_thread_t *p_intf)
     this->p_intf = p_intf;
 
     p_intf->p_sys->p_about =
-        new KAboutData( "VideoLAN Client", I18N_NOOP("Kvlc"), VERSION,
-            "This is the VideoLAN client, a DVD and MPEG player. It can play MPEG and MPEG 2 files from a file or from a network source.", KAboutData::License_GPL,
-            "(C) 1996, 1997, 1998, 1999, 2000, 2001 - the VideoLAN Team", 0, 0, "dae@chez.com");
+      new KAboutData( "VideoLAN Client", I18N_NOOP("Kvlc"), VERSION,
+         _("This is the VideoLAN client, a DVD and MPEG player. It can play "
+           "MPEG and MPEG 2 files from a file or from a network source."),
+         KAboutData::License_GPL,
+         _("(C) 1996, 1997, 1998, 1999, 2000, 2001, 2002 - the VideoLAN Team"),
+         0, 0, "");
 
     char *authors[][2] = {
-        { "Régis Duchesne", "<regis@via.ecp.fr>" },
-        { "Michel Lespinasse", "<walken@zoy.org>" },
-        { "Olivier Pomel", "<pomel@via.ecp.fr>" },
-        { "Pierre Baillet", "<oct@zoy.org>" },
-        { "Jean-Philippe Grimaldi", "<jeanphi@via.ecp.fr>" },
-        { "Andres Krapf", "<dae@via.ecp.fr>" },
-        { "Christophe Massiot", "<massiot@via.ecp.fr>" },
-        { "Vincent Seguin", "<seguin@via.ecp.fr>" },
-        { "Benoit Steiner", "<benny@via.ecp.fr>" },
-        { "Arnaud de Bossoreille de Ribou", "<bozo@via.ecp.fr>" },
-        { "Jean-Marc Dressler", "<polux@via.ecp.fr>" },
-        { "Gaël Hendryckx", "<jimmy@via.ecp.fr>" },
-        { "Samuel Hocevar","<sam@zoy.org>" },
-        { "Brieuc Jeunhomme", "<bbp@via.ecp.fr>" },
-        { "Michel Kaempf", "<maxx@via.ecp.fr>" },
-        { "Stéphane Borel", "<stef@via.ecp.fr>" },
-        { "Renaud Dartus", "<reno@via.ecp.fr>" },
-        { "Henri Fallon", "<henri@via.ecp.fr>" },
+        { "the VideoLAN Team", "<videolan@videolan.org>" },
         { NULL, NULL },
     };
 
@@ -148,12 +133,14 @@ KThread::KThread(intf_thread_t *p_intf)
     }
 
     int argc = 1;
-    char *argv[] = { p_main->psz_arg0, NULL };
+    char *argv[] = { p_intf->p_vlc->psz_object_name, NULL };
     KCmdLineArgs::init( argc, argv, p_intf->p_sys->p_about );
 
     p_intf->p_sys->p_app = new KApplication();
     p_intf->p_sys->p_window = new KInterface(p_intf);
     p_intf->p_sys->p_window->setCaption( VOUT_TITLE " (KDE interface)" );
+
+    p_intf->p_sys->p_input = NULL;
 }
 
 /*****************************************************************************
@@ -161,6 +148,11 @@ KThread::KThread(intf_thread_t *p_intf)
  *****************************************************************************/
 KThread::~KThread()
 {
+    if( p_intf->p_sys->p_input )
+    {
+        vlc_object_release( p_intf->p_sys->p_input );
+    }
+
     /* XXX: can be deleted if the user closed the window ! */
     //delete p_intf->p_sys->p_window;
 
@@ -177,7 +169,7 @@ int KThread::open(intf_thread_t *p_intf)
     p_intf->p_sys = (intf_sys_t *)malloc( sizeof( intf_sys_t ) );
     if( p_intf->p_sys == NULL )
     {
-        intf_ErrMsg( "intf error: %s", strerror(ENOMEM) );
+        msg_Err( p_intf, "out of memory" );
         return( 1 );
     }