include/vcl/ctrl.hxx | 1 - vcl/source/control/ctrl.cxx | 25 ------------------------- 2 files changed, 26 deletions(-)
New commits: commit 529f584b5e2e86273c812d42ada7a489e36b9cf3 Author: Lionel Elie Mamane <lio...@mamane.lu> Date: Thu May 29 17:41:34 2014 +0200 Allow STYLE_OPTION_MONO to be unset from toolkit-created window This was keeping form controls (e.g. CheckBox and RadioButton) to transition from flat style to 3d style, while the 3d-to-flat transition was allowed, making flat some unescapable pit of doom. Whatever the goal of that pinning, it will have to be achieved in a different way. Change-Id: Icc4dfb9673a7dfe4a7d8726fbfd23f75499f8b41 Reviewed-on: https://gerrit.libreoffice.org/9554 Reviewed-by: Norbert Thiebaud <nthieb...@gmail.com> Tested-by: Norbert Thiebaud <nthieb...@gmail.com> diff --git a/include/vcl/ctrl.hxx b/include/vcl/ctrl.hxx index 4c70732..e4ed1e4 100644 --- a/include/vcl/ctrl.hxx +++ b/include/vcl/ctrl.hxx @@ -136,7 +136,6 @@ public: virtual bool Notify( NotifyEvent& rNEvt ) SAL_OVERRIDE; virtual void StateChanged( StateChangedType nStateChange ) SAL_OVERRIDE; virtual void Resize() SAL_OVERRIDE; - virtual void DataChanged( const DataChangedEvent& rDCEvt ) SAL_OVERRIDE; // invalidates layout data virtual void SetText( const OUString& rStr ) SAL_OVERRIDE; diff --git a/vcl/source/control/ctrl.cxx b/vcl/source/control/ctrl.cxx index 6baf5ae..c505afa 100644 --- a/vcl/source/control/ctrl.cxx +++ b/vcl/source/control/ctrl.cxx @@ -368,31 +368,6 @@ void Control::ImplDrawFrame( OutputDevice* pDev, Rectangle& rRect ) pDev->OutputDevice::SetSettings( aOriginalSettings ); } -void Control::DataChanged( const DataChangedEvent& rDCEvt) -{ - // we don't want to lose some style settings for controls created with the - // toolkit - if ( IsCreatedWithToolkit() && - (rDCEvt.GetType() == DATACHANGED_SETTINGS) && - (rDCEvt.GetFlags() & SETTINGS_STYLE) ) - { - const AllSettings* pOldSettings = rDCEvt.GetOldSettings(); - - AllSettings aSettings = GetSettings(); - StyleSettings aStyleSettings = aSettings.GetStyleSettings(); - sal_uLong nNewOptions = aStyleSettings.GetOptions(); - - if ( pOldSettings && !(nNewOptions & STYLE_OPTION_MONO) && ( pOldSettings->GetStyleSettings().GetOptions() & STYLE_OPTION_MONO ) ) - { - nNewOptions |= STYLE_OPTION_MONO; - aStyleSettings.SetOptions( nNewOptions ); - aStyleSettings.SetMonoColor( pOldSettings->GetStyleSettings().GetMonoColor() ); - aSettings.SetStyleSettings( aStyleSettings ); - SetSettings( aSettings ); - } - } -} - ControlLayoutData::~ControlLayoutData() { if( m_pParent ) _______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits