]> git.sesse.net Git - vlc/blobdiff - modules/gui/skins2/commands/async_queue.cpp
Add the compile information
[vlc] / modules / gui / skins2 / commands / async_queue.cpp
index 25529d046aaf9499bef4f67e20d00d225c61cb03..bb670d1dc9089f758ede3a36ec775025d2b12545 100644 (file)
@@ -1,7 +1,7 @@
 /*****************************************************************************
  * async_queue.cpp
  *****************************************************************************
- * Copyright (C) 2003 VideoLAN (Centrale Réseaux) and its contributors
+ * Copyright (C) 2003 the VideoLAN team
  * $Id$
  *
  * Authors: Cyril Deguet     <asmax@via.ecp.fr>
 #include "../src/os_timer.hpp"
 
 
-AsyncQueue::AsyncQueue( intf_thread_t *pIntf ): SkinObject( pIntf )
+AsyncQueue::AsyncQueue( intf_thread_t *pIntf ): SkinObject( pIntf ),
+    m_cmdFlush( this )
 {
     // Initialize the mutex
     vlc_mutex_init( pIntf, &m_lock );
 
     // Create a timer
     OSFactory *pOsFactory = OSFactory::instance( pIntf );
-    m_pTimer = pOsFactory->createOSTimer( Callback( this, &doFlush ) );
+    m_pTimer = pOsFactory->createOSTimer( m_cmdFlush );
 
     // Flush the queue every 10 ms
     m_pTimer->start( 10, false );
@@ -129,9 +130,8 @@ void AsyncQueue::flush()
 }
 
 
-void AsyncQueue::doFlush( SkinObject *pObj )
+void AsyncQueue::CmdFlush::execute()
 {
-    AsyncQueue *pThis = (AsyncQueue*)pObj;
     // Flush the queue
-    pThis->flush();
+    m_pParent->flush();
 }