* $Id$
*
* Authors: Cyril Deguet <asmax@via.ecp.fr>
- * Olivier Teulière <ipkiss@via.ecp.fr>
+ * Olivier Teulière <ipkiss@via.ecp.fr>
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111, USA.
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301, USA.
*****************************************************************************/
#include "tooltip.hpp"
Tooltip::~Tooltip()
{
VarManager::instance( getIntf() )->getTooltipText().delObserver( this );
- SKINS_DELETE( m_pTimer );
- SKINS_DELETE( m_pOsTooltip );
- if( m_pImage )
- {
- delete m_pImage;
- }
+ delete m_pTimer;
+ delete m_pOsTooltip;
+ delete m_pImage;
}
}
-void Tooltip::onUpdate( Subject<VarText> &rVariable )
+void Tooltip::onUpdate( Subject<VarText> &rVariable , void *arg)
{
// Redisplay the tooltip
displayText( ((VarText&)rVariable).get() );
int h = m_rFont.getSize() + 8;
// Create the image of the tooltip
- if( m_pImage )
- {
- delete m_pImage;
- }
+ delete m_pImage;
m_pImage = OSFactory::instance( getIntf() )->createOSGraphics( w, h );
m_pImage->fillRect( 0, 0, w, h, 0xffffd0 );
m_pImage->drawRect( 0, 0, w, h, 0x000000 );