diff options
author | Vladimir Glazounov <vg@openoffice.org> | 2003-05-19 11:55:49 +0000 |
---|---|---|
committer | Vladimir Glazounov <vg@openoffice.org> | 2003-05-19 11:55:49 +0000 |
commit | e539e63dd14c2ad12f0dd15fc57eae327b0044a7 (patch) | |
tree | 18ed1b14198237eae55044b899d9ed33ce72bfb1 /dbaccess/source/ui/misc/ToolBoxHelper.cxx | |
parent | a22b85eca92912e6d5dba2947895d0a054abab34 (diff) |
INTEGRATION: CWS dba05 (1.2.4); FILE MERGED
2003/04/30 14:44:48 oj 1.2.4.3: #109263# filter only usefull events
2003/04/30 13:27:21 oj 1.2.4.2: #109216# set -1 as default for bitmaps, will be changed afterwards
2003/04/30 11:08:59 oj 1.2.4.1: #109216# set small as default for bitmaps, will be changed afterwards
Diffstat (limited to 'dbaccess/source/ui/misc/ToolBoxHelper.cxx')
-rw-r--r-- | dbaccess/source/ui/misc/ToolBoxHelper.cxx | 20 |
1 files changed, 13 insertions, 7 deletions
diff --git a/dbaccess/source/ui/misc/ToolBoxHelper.cxx b/dbaccess/source/ui/misc/ToolBoxHelper.cxx index c7b1b2c71661..02cda395a18a 100644 --- a/dbaccess/source/ui/misc/ToolBoxHelper.cxx +++ b/dbaccess/source/ui/misc/ToolBoxHelper.cxx @@ -2,9 +2,9 @@ * * $RCSfile: ToolBoxHelper.cxx,v $ * - * $Revision: 1.2 $ + * $Revision: 1.3 $ * - * last change: $Author: vg $ $Date: 2003-04-17 13:26:48 $ + * last change: $Author: vg $ $Date: 2003-05-19 12:55:49 $ * * The Contents of this file are made available subject to the terms of * either of the following licenses @@ -79,14 +79,16 @@ #ifndef _DBAUI_MODULE_DBU_HXX_ #include "moduledbu.hxx" #endif +#include <vcl/event.hxx> namespace dbaui { OToolBoxHelper::OToolBoxHelper() : m_bIsHiContrast(sal_False) ,m_pToolBox(NULL) - ,m_nBitmapSet( getCurrentSymbolSet() ) + ,m_nBitmapSet(-1 ) { + OSL_ENSURE(m_nBitmapSet != getCurrentSymbolSet(),"BitmapSet should not be identical"); SvtMiscOptions().AddListener( LINK( this, OToolBoxHelper, ConfigOptionsChanged ) ); Application::AddEventListener( LINK( this, OToolBoxHelper, SettingsChanged ) ); } @@ -153,12 +155,16 @@ namespace dbaui return 0L; } // ----------------------------------------------------------------------------- - IMPL_LINK(OToolBoxHelper, SettingsChanged, void*, _pVoid) + IMPL_LINK(OToolBoxHelper, SettingsChanged, VclWindowEvent*, _pEvt) { - if ( m_pToolBox ) + if ( m_pToolBox && _pEvt && _pEvt->GetId() == VCLEVENT_APPLICATION_DATACHANGED ) { - // check if imagelist changed - checkImageList(); + DataChangedEvent* pData = reinterpret_cast<DataChangedEvent*>(_pEvt->GetData()); + if ( pData && ((( pData->GetType() == DATACHANGED_SETTINGS ) || + ( pData->GetType() == DATACHANGED_DISPLAY )) && + ( pData->GetFlags() & SETTINGS_STYLE ))) + // check if imagelist changed + checkImageList(); } return 0L; |