]> git.sesse.net Git - vlc/commitdiff
skins2: use input_GetVout when possible.
authorRémi Duraffort <ivoire@videolan.org>
Fri, 23 Jan 2009 15:54:17 +0000 (16:54 +0100)
committerRémi Duraffort <ivoire@videolan.org>
Fri, 23 Jan 2009 15:54:17 +0000 (16:54 +0100)
modules/gui/skins2/commands/cmd_fullscreen.cpp
modules/gui/skins2/commands/cmd_snapshot.cpp
modules/gui/skins2/src/vlcproc.cpp

index 04f14a991763e1929f91b609e81f63edcbcb12b8..74a920d781d533d78c8713fe2da2a2d85792b85e 100644 (file)
@@ -1,7 +1,7 @@
 /*****************************************************************************
  * cmd_fullscreen.cpp
  *****************************************************************************
- * Copyright (C) 2003 the VideoLAN team
+ * Copyright (C) 2003-2009 the VideoLAN team
  * $Id$
  *
  * Authors: Cyril Deguet     <asmax@via.ecp.fr>
 
 void CmdFullscreen::execute()
 {
-    vout_thread_t *pVout;
 
     if( getIntf()->p_sys->p_input == NULL )
-    {
         return;
-    }
 
-    pVout = (vout_thread_t *)vlc_object_find( getIntf()->p_sys->p_input,
-                                              VLC_OBJECT_VOUT, FIND_ANYWHERE );
+    vout_thread_t *pVout = input_GetVout( getIntf()->p_sys->p_input );
     if( pVout )
     {
         // Switch to fullscreen
index 23e5a37a306271d60b2d92044625af0ab764e5f9..80d12ca310944c314d3bddf7e31f102e0f485500 100644 (file)
@@ -1,7 +1,7 @@
 /*****************************************************************************
  * cmd_snapshot.cpp
  *****************************************************************************
- * Copyright (C) 2006 the VideoLAN team
+ * Copyright (C) 2006-2009 the VideoLAN team
  * $Id$
  *
  * Authors: Olivier Teulière <ipkiss@via.ecp.fr>
 
 void CmdSnapshot::execute()
 {
-    vout_thread_t *pVout;
-
     if( getIntf()->p_sys->p_input == NULL )
-    {
         return;
-    }
 
-    pVout = (vout_thread_t *)vlc_object_find( getIntf()->p_sys->p_input,
-                                              VLC_OBJECT_VOUT, FIND_CHILD );
+    vout_thread_t *pVout = input_GetVout( getIntf()->p_sys->p_input );
     if( pVout )
     {
         // Take a snapshot
index 451e7be48c854e687a06a2a0c34fb323d25ec0d9..8d6baab98d26ce3a1560e5388efa8d34b8fa71e5 100644 (file)
@@ -1,7 +1,7 @@
 /*****************************************************************************
  * vlcproc.cpp
  *****************************************************************************
- * Copyright (C) 2003 the VideoLAN team
+ * Copyright (C) 2003-2009 the VideoLAN team
  * $Id$
  *
  * Authors: Cyril Deguet     <asmax@via.ecp.fr>
@@ -369,8 +369,7 @@ void VlcProc::refreshInput()
         pVarHasAudio->set( audio_es.i_int > 0 );
 
         // Refresh fullscreen status
-        vout_thread_t *pVout = (vout_thread_t *)vlc_object_find( pInput,
-                                     VLC_OBJECT_VOUT, FIND_CHILD );
+        vout_thread_t *pVout = input_GetVout( pInput );
         pVarHasVout->set( pVout != NULL );
         if( pVout )
         {