From: Erwan Tulou Date: Mon, 28 Jan 2013 11:38:45 +0000 (+0100) Subject: skins2: rename command to better readability X-Git-Tag: 2.1.0-git~1450 X-Git-Url: https://git.sesse.net/?a=commitdiff_plain;h=29c75ea7d46d6d5c699c3e338147ad9511f6d170;p=vlc skins2: rename command to better readability --- diff --git a/modules/gui/skins2/commands/cmd_vars.cpp b/modules/gui/skins2/commands/cmd_vars.cpp index 31eaa27b17..423be4b77d 100644 --- a/modules/gui/skins2/commands/cmd_vars.cpp +++ b/modules/gui/skins2/commands/cmd_vars.cpp @@ -28,7 +28,7 @@ #include "../vars/playtree.hpp" -void CmdPlaytreeUpdate::execute() +void CmdItemUpdate::execute() { if( !m_pItem ) return; @@ -43,10 +43,10 @@ void CmdPlaytreeUpdate::execute() VlcProc::instance( getIntf() )->getPlaytreeVar().onUpdateItem( id ); } -bool CmdPlaytreeUpdate::checkRemove( CmdGeneric *pQueuedCommand ) const +bool CmdItemUpdate::checkRemove( CmdGeneric *pQueuedCommand ) const { // We don't use RTTI - Use C-style cast - CmdPlaytreeUpdate *pUpdateCommand = (CmdPlaytreeUpdate *)(pQueuedCommand); + CmdItemUpdate *pUpdateCommand = (CmdItemUpdate *)(pQueuedCommand); return m_pItem == pUpdateCommand->m_pItem; } diff --git a/modules/gui/skins2/commands/cmd_vars.hpp b/modules/gui/skins2/commands/cmd_vars.hpp index 2f527362a5..a27e7aa5aa 100644 --- a/modules/gui/skins2/commands/cmd_vars.hpp +++ b/modules/gui/skins2/commands/cmd_vars.hpp @@ -39,16 +39,16 @@ class EqualizerPreamp; class VarText; /// Command to notify the playtree of an item update -class CmdPlaytreeUpdate: public CmdGeneric +class CmdItemUpdate: public CmdGeneric { public: - CmdPlaytreeUpdate( intf_thread_t *pIntf, input_item_t* pItem ): + CmdItemUpdate( intf_thread_t *pIntf, input_item_t* pItem ): CmdGeneric( pIntf ), m_pItem( pItem ) { if( pItem ) vlc_gc_incref( pItem ); } - virtual ~CmdPlaytreeUpdate() + virtual ~CmdItemUpdate() { if( m_pItem ) vlc_gc_decref( m_pItem ); diff --git a/modules/gui/skins2/src/vlcproc.cpp b/modules/gui/skins2/src/vlcproc.cpp index 80b1395b2d..7127c625e3 100644 --- a/modules/gui/skins2/src/vlcproc.cpp +++ b/modules/gui/skins2/src/vlcproc.cpp @@ -247,7 +247,7 @@ int VlcProc::onItemChange( vlc_object_t *pObj, const char *pVariable, input_item_t *p_item = static_cast(newval.p_address); // Create a playtree notify command - CmdPlaytreeUpdate *pCmdTree = new CmdPlaytreeUpdate( pThis->getIntf(), + CmdItemUpdate *pCmdTree = new CmdItemUpdate( pThis->getIntf(), p_item ); // Push the command in the asynchronous command queue