summaryrefslogtreecommitdiffstats
path: root/svtools/source
diff options
context:
space:
mode:
authorNoel Grandin <noel@peralex.com>2015-01-09 16:29:43 +0200
committerNoel Grandin <noel@peralex.com>2015-01-12 12:57:04 +0200
commita5b5ad9f9306d868430ed9efd210b95c24a15161 (patch)
treed028638ef38e1e7a062944923b0db1fd6f03d3f5 /svtools/source
parentFocusChanged and DataChanged are never overriden (diff)
downloadcore-a5b5ad9f9306d868430ed9efd210b95c24a15161.tar.gz
core-a5b5ad9f9306d868430ed9efd210b95c24a15161.zip
fdo#84938: replace DATACHANGED_ constants with 'enum class'
and drop DATACHANGED_DATETIME because no-one is using it Change-Id: Id5ac9a7fbba0e35501ed82e5252f66858621f7ff
Diffstat (limited to 'svtools/source')
-rw-r--r--svtools/source/brwbox/datwin.cxx2
-rw-r--r--svtools/source/brwbox/ebbcontrols.cxx2
-rw-r--r--svtools/source/brwbox/editbrowsebox.cxx4
-rw-r--r--svtools/source/config/colorcfg.cxx2
-rw-r--r--svtools/source/config/extcolorcfg.cxx2
-rw-r--r--svtools/source/contnr/ivctrl.cxx6
-rw-r--r--svtools/source/contnr/treelistbox.cxx2
-rw-r--r--svtools/source/control/calendar.cxx6
-rw-r--r--svtools/source/control/ctrlbox.cxx2
-rw-r--r--svtools/source/control/headbar.cxx6
-rw-r--r--svtools/source/control/hyperlabel.cxx4
-rw-r--r--svtools/source/control/roadmap.cxx8
-rw-r--r--svtools/source/control/ruler.cxx8
-rw-r--r--svtools/source/control/scrwin.cxx2
-rw-r--r--svtools/source/control/tabbar.cxx6
-rw-r--r--svtools/source/control/toolbarmenu.cxx6
-rw-r--r--svtools/source/control/valueset.cxx8
-rw-r--r--svtools/source/dialogs/prnsetup.cxx2
-rw-r--r--svtools/source/toolpanel/paneltabbar.cxx2
-rw-r--r--svtools/source/toolpanel/toolpaneldrawer.cxx7
20 files changed, 44 insertions, 43 deletions
diff --git a/svtools/source/brwbox/datwin.cxx b/svtools/source/brwbox/datwin.cxx
index ebf6219919bc..2578c12d4407 100644
--- a/svtools/source/brwbox/datwin.cxx
+++ b/svtools/source/brwbox/datwin.cxx
@@ -283,7 +283,7 @@ void BrowserDataWin::Update()
void BrowserDataWin::DataChanged( const DataChangedEvent& rDCEvt )
{
- if ( (rDCEvt.GetType() == DATACHANGED_SETTINGS) &&
+ if ( (rDCEvt.GetType() == DataChangedEventType::SETTINGS) &&
(rDCEvt.GetFlags() & SETTINGS_STYLE) )
{
if( !bOwnDataChangedHdl )
diff --git a/svtools/source/brwbox/ebbcontrols.cxx b/svtools/source/brwbox/ebbcontrols.cxx
index 7b0e577a038d..c4bedd3c27bf 100644
--- a/svtools/source/brwbox/ebbcontrols.cxx
+++ b/svtools/source/brwbox/ebbcontrols.cxx
@@ -269,7 +269,7 @@ namespace svt
void CheckBoxControl::DataChanged( const DataChangedEvent& _rEvent )
{
- if ( _rEvent.GetType() == DATACHANGED_SETTINGS )
+ if ( _rEvent.GetType() == DataChangedEventType::SETTINGS )
pBox->SetSettings( GetSettings() );
}
diff --git a/svtools/source/brwbox/editbrowsebox.cxx b/svtools/source/brwbox/editbrowsebox.cxx
index d63be61f1cc5..026a2fb8d083 100644
--- a/svtools/source/brwbox/editbrowsebox.cxx
+++ b/svtools/source/brwbox/editbrowsebox.cxx
@@ -802,8 +802,8 @@ namespace svt
{
BrowseBox::DataChanged( rDCEvt );
- if ((( rDCEvt.GetType() == DATACHANGED_SETTINGS ) ||
- ( rDCEvt.GetType() == DATACHANGED_DISPLAY )) &&
+ if ((( rDCEvt.GetType() == DataChangedEventType::SETTINGS ) ||
+ ( rDCEvt.GetType() == DataChangedEventType::DISPLAY )) &&
( rDCEvt.GetFlags() & SETTINGS_STYLE ))
{
ImplInitSettings( true, true, true );
diff --git a/svtools/source/config/colorcfg.cxx b/svtools/source/config/colorcfg.cxx
index 77dbfd0bbe24..c79a34e640f1 100644
--- a/svtools/source/config/colorcfg.cxx
+++ b/svtools/source/config/colorcfg.cxx
@@ -349,7 +349,7 @@ IMPL_LINK( ColorConfig_Impl, DataChangedEventListener, VclWindowEvent*, pEvent )
if ( pEvent->GetId() == VCLEVENT_APPLICATION_DATACHANGED )
{
DataChangedEvent* pData = (DataChangedEvent*)(pEvent->GetData());
- if ( (pData->GetType() == DATACHANGED_SETTINGS) &&
+ if ( (pData->GetType() == DataChangedEventType::SETTINGS) &&
(pData->GetFlags() & SETTINGS_STYLE) )
{
SettingsChanged();
diff --git a/svtools/source/config/extcolorcfg.cxx b/svtools/source/config/extcolorcfg.cxx
index d2a0536613c1..dd6eb881915c 100644
--- a/svtools/source/config/extcolorcfg.cxx
+++ b/svtools/source/config/extcolorcfg.cxx
@@ -545,7 +545,7 @@ IMPL_LINK( ExtendedColorConfig_Impl, DataChangedEventListener, VclWindowEvent*,
if ( pEvent->GetId() == VCLEVENT_APPLICATION_DATACHANGED )
{
DataChangedEvent* pData = (DataChangedEvent*)(pEvent->GetData());
- if ( (pData->GetType() == DATACHANGED_SETTINGS) &&
+ if ( (pData->GetType() == DataChangedEventType::SETTINGS) &&
(pData->GetFlags() & SETTINGS_STYLE) )
{
SettingsChanged();
diff --git a/svtools/source/contnr/ivctrl.cxx b/svtools/source/contnr/ivctrl.cxx
index da44f6e5ef64..ae82f24e5a30 100644
--- a/svtools/source/contnr/ivctrl.cxx
+++ b/svtools/source/contnr/ivctrl.cxx
@@ -366,9 +366,9 @@ void SvtIconChoiceCtrl::StateChanged( StateChangedType nType )
void SvtIconChoiceCtrl::DataChanged( const DataChangedEvent& rDCEvt )
{
- if ( ((rDCEvt.GetType() == DATACHANGED_SETTINGS) ||
- (rDCEvt.GetType() == DATACHANGED_FONTSUBSTITUTION) ||
- (rDCEvt.GetType() == DATACHANGED_FONTS) ) &&
+ if ( ((rDCEvt.GetType() == DataChangedEventType::SETTINGS) ||
+ (rDCEvt.GetType() == DataChangedEventType::FONTSUBSTITUTION) ||
+ (rDCEvt.GetType() == DataChangedEventType::FONTS) ) &&
(rDCEvt.GetFlags() & SETTINGS_STYLE) )
{
_pImp->InitSettings();
diff --git a/svtools/source/contnr/treelistbox.cxx b/svtools/source/contnr/treelistbox.cxx
index 28de1224101b..d131137712c0 100644
--- a/svtools/source/contnr/treelistbox.cxx
+++ b/svtools/source/contnr/treelistbox.cxx
@@ -3771,7 +3771,7 @@ void SvTreeListBox::ShowFocusRect( const SvTreeListEntry* pEntry )
void SvTreeListBox::DataChanged( const DataChangedEvent& rDCEvt )
{
- if( (rDCEvt.GetType()==DATACHANGED_SETTINGS) && (rDCEvt.GetFlags() & SETTINGS_STYLE) )
+ if( (rDCEvt.GetType()==DataChangedEventType::SETTINGS) && (rDCEvt.GetFlags() & SETTINGS_STYLE) )
{
nEntryHeight = 0; // _together_ with true of 1. par (bFont) of InitSettings() a zero-height
// forces complete recalc of heights!
diff --git a/svtools/source/control/calendar.cxx b/svtools/source/control/calendar.cxx
index fa20f9910d91..ed609788ca71 100644
--- a/svtools/source/control/calendar.cxx
+++ b/svtools/source/control/calendar.cxx
@@ -1766,9 +1766,9 @@ void Calendar::DataChanged( const DataChangedEvent& rDCEvt )
{
Control::DataChanged( rDCEvt );
- if ( (rDCEvt.GetType() == DATACHANGED_FONTS) ||
- (rDCEvt.GetType() == DATACHANGED_FONTSUBSTITUTION) ||
- ((rDCEvt.GetType() == DATACHANGED_SETTINGS) &&
+ if ( (rDCEvt.GetType() == DataChangedEventType::FONTS) ||
+ (rDCEvt.GetType() == DataChangedEventType::FONTSUBSTITUTION) ||
+ ((rDCEvt.GetType() == DataChangedEventType::SETTINGS) &&
(rDCEvt.GetFlags() & SETTINGS_STYLE)) )
{
ImplInitSettings();
diff --git a/svtools/source/control/ctrlbox.cxx b/svtools/source/control/ctrlbox.cxx
index e1a26e7f5a6d..0fb5c06b4598 100644
--- a/svtools/source/control/ctrlbox.cxx
+++ b/svtools/source/control/ctrlbox.cxx
@@ -949,7 +949,7 @@ void LineListBox::DataChanged( const DataChangedEvent& rDCEvt )
{
ListBox::DataChanged( rDCEvt );
- if( ( rDCEvt.GetType() == DATACHANGED_SETTINGS ) && ( rDCEvt.GetFlags() & SETTINGS_STYLE ) )
+ if( ( rDCEvt.GetType() == DataChangedEventType::SETTINGS ) && ( rDCEvt.GetFlags() & SETTINGS_STYLE ) )
UpdateEntries( m_nWidth );
}
diff --git a/svtools/source/control/headbar.cxx b/svtools/source/control/headbar.cxx
index 8913ca006edc..8f5df1b0faea 100644
--- a/svtools/source/control/headbar.cxx
+++ b/svtools/source/control/headbar.cxx
@@ -1193,9 +1193,9 @@ void HeaderBar::DataChanged( const DataChangedEvent& rDCEvt )
{
Window::DataChanged( rDCEvt );
- if ( (rDCEvt.GetType() == DATACHANGED_FONTS) ||
- (rDCEvt.GetType() == DATACHANGED_FONTSUBSTITUTION) ||
- ((rDCEvt.GetType() == DATACHANGED_SETTINGS) &&
+ if ( (rDCEvt.GetType() == DataChangedEventType::FONTS) ||
+ (rDCEvt.GetType() == DataChangedEventType::FONTSUBSTITUTION) ||
+ ((rDCEvt.GetType() == DataChangedEventType::SETTINGS) &&
(rDCEvt.GetFlags() & SETTINGS_STYLE)) )
{
ImplInitSettings( true, true, true );
diff --git a/svtools/source/control/hyperlabel.cxx b/svtools/source/control/hyperlabel.cxx
index 5c724842f7d1..a9a28134e6ad 100644
--- a/svtools/source/control/hyperlabel.cxx
+++ b/svtools/source/control/hyperlabel.cxx
@@ -194,8 +194,8 @@ namespace svt
{
const StyleSettings& rStyleSettings = GetSettings().GetStyleSettings();
FixedText::DataChanged( rDCEvt );
- if ((( rDCEvt.GetType() == DATACHANGED_SETTINGS ) ||
- ( rDCEvt.GetType() == DATACHANGED_DISPLAY )) &&
+ if ((( rDCEvt.GetType() == DataChangedEventType::SETTINGS ) ||
+ ( rDCEvt.GetType() == DataChangedEventType::DISPLAY )) &&
( rDCEvt.GetFlags() & SETTINGS_STYLE ))
{
const Color& rGBColor = GetControlBackground();
diff --git a/svtools/source/control/roadmap.cxx b/svtools/source/control/roadmap.cxx
index 7d8705eab97b..1007e27f6c78 100644
--- a/svtools/source/control/roadmap.cxx
+++ b/svtools/source/control/roadmap.cxx
@@ -652,8 +652,8 @@ namespace svt
void ORoadmap::DataChanged( const DataChangedEvent& rDCEvt )
{
- if ((( rDCEvt.GetType() == DATACHANGED_SETTINGS ) ||
- ( rDCEvt.GetType() == DATACHANGED_DISPLAY )) &&
+ if ((( rDCEvt.GetType() == DataChangedEventType::SETTINGS ) ||
+ ( rDCEvt.GetType() == DataChangedEventType::DISPLAY )) &&
( rDCEvt.GetFlags() & SETTINGS_STYLE ))
{
const StyleSettings& rStyleSettings = GetSettings().GetStyleSettings();
@@ -859,8 +859,8 @@ namespace svt
{
const StyleSettings& rStyleSettings = GetSettings().GetStyleSettings();
FixedText::DataChanged( rDCEvt );
- if ((( rDCEvt.GetType() == DATACHANGED_SETTINGS ) ||
- ( rDCEvt.GetType() == DATACHANGED_DISPLAY )) &&
+ if ((( rDCEvt.GetType() == DataChangedEventType::SETTINGS ) ||
+ ( rDCEvt.GetType() == DataChangedEventType::DISPLAY )) &&
( rDCEvt.GetFlags() & SETTINGS_STYLE ))
{
const Color& rGBColor = GetControlBackground();
diff --git a/svtools/source/control/ruler.cxx b/svtools/source/control/ruler.cxx
index 43584cd76acc..249c4add7c46 100644
--- a/svtools/source/control/ruler.cxx
+++ b/svtools/source/control/ruler.cxx
@@ -2238,10 +2238,10 @@ void Ruler::DataChanged( const DataChangedEvent& rDCEvt )
{
Window::DataChanged( rDCEvt );
- if ( (rDCEvt.GetType() == DATACHANGED_FONTS) ||
- (rDCEvt.GetType() == DATACHANGED_DISPLAY) ||
- (rDCEvt.GetType() == DATACHANGED_FONTSUBSTITUTION) ||
- ((rDCEvt.GetType() == DATACHANGED_SETTINGS) &&
+ if ( (rDCEvt.GetType() == DataChangedEventType::FONTS) ||
+ (rDCEvt.GetType() == DataChangedEventType::DISPLAY) ||
+ (rDCEvt.GetType() == DataChangedEventType::FONTSUBSTITUTION) ||
+ ((rDCEvt.GetType() == DataChangedEventType::SETTINGS) &&
(rDCEvt.GetFlags() & SETTINGS_STYLE)) )
{
mbFormat = true;
diff --git a/svtools/source/control/scrwin.cxx b/svtools/source/control/scrwin.cxx
index e948e2c76144..e638002a5eb9 100644
--- a/svtools/source/control/scrwin.cxx
+++ b/svtools/source/control/scrwin.cxx
@@ -79,7 +79,7 @@ void ScrollableWindow::Command( const CommandEvent& rCEvt )
void ScrollableWindow::DataChanged( const DataChangedEvent& rDCEvt )
{
- if ( (rDCEvt.GetType() == DATACHANGED_SETTINGS) &&
+ if ( (rDCEvt.GetType() == DataChangedEventType::SETTINGS) &&
(rDCEvt.GetFlags() & SETTINGS_STYLE) )
{
Resize();
diff --git a/svtools/source/control/tabbar.cxx b/svtools/source/control/tabbar.cxx
index 629e52d6aa70..65bd901f51e3 100644
--- a/svtools/source/control/tabbar.cxx
+++ b/svtools/source/control/tabbar.cxx
@@ -1602,9 +1602,9 @@ void TabBar::DataChanged( const DataChangedEvent& rDCEvt )
{
Window::DataChanged( rDCEvt );
- if ( (rDCEvt.GetType() == DATACHANGED_FONTS) ||
- (rDCEvt.GetType() == DATACHANGED_FONTSUBSTITUTION) ||
- ((rDCEvt.GetType() == DATACHANGED_SETTINGS) &&
+ if ( (rDCEvt.GetType() == DataChangedEventType::FONTS) ||
+ (rDCEvt.GetType() == DataChangedEventType::FONTSUBSTITUTION) ||
+ ((rDCEvt.GetType() == DataChangedEventType::SETTINGS) &&
(rDCEvt.GetFlags() & SETTINGS_STYLE)) )
{
ImplInitSettings( true, true );
diff --git a/svtools/source/control/toolbarmenu.cxx b/svtools/source/control/toolbarmenu.cxx
index beb142b21c0a..d7404dcbd611 100644
--- a/svtools/source/control/toolbarmenu.cxx
+++ b/svtools/source/control/toolbarmenu.cxx
@@ -1513,9 +1513,9 @@ void ToolbarMenu::DataChanged( const DataChangedEvent& rDCEvt )
{
DockingWindow::DataChanged( rDCEvt );
- if ( (rDCEvt.GetType() == DATACHANGED_FONTS) ||
- (rDCEvt.GetType() == DATACHANGED_FONTSUBSTITUTION) ||
- ((rDCEvt.GetType() == DATACHANGED_SETTINGS) &&
+ if ( (rDCEvt.GetType() == DataChangedEventType::FONTS) ||
+ (rDCEvt.GetType() == DataChangedEventType::FONTSUBSTITUTION) ||
+ ((rDCEvt.GetType() == DataChangedEventType::SETTINGS) &&
(rDCEvt.GetFlags() & SETTINGS_STYLE)) )
{
initWindow();
diff --git a/svtools/source/control/valueset.cxx b/svtools/source/control/valueset.cxx
index 4c0e80a4f26d..d0f1d7cd830a 100644
--- a/svtools/source/control/valueset.cxx
+++ b/svtools/source/control/valueset.cxx
@@ -1532,10 +1532,10 @@ void ValueSet::DataChanged( const DataChangedEvent& rDataChangedEvent )
{
Control::DataChanged( rDataChangedEvent );
- if ( rDataChangedEvent.GetType() == DATACHANGED_FONTS ||
- rDataChangedEvent.GetType() == DATACHANGED_DISPLAY ||
- rDataChangedEvent.GetType() == DATACHANGED_FONTSUBSTITUTION ||
- (rDataChangedEvent.GetType() == DATACHANGED_SETTINGS &&
+ if ( rDataChangedEvent.GetType() == DataChangedEventType::FONTS ||
+ rDataChangedEvent.GetType() == DataChangedEventType::DISPLAY ||
+ rDataChangedEvent.GetType() == DataChangedEventType::FONTSUBSTITUTION ||
+ (rDataChangedEvent.GetType() == DataChangedEventType::SETTINGS &&
rDataChangedEvent.GetFlags() & SETTINGS_STYLE) )
{
mbFormat = true;
diff --git a/svtools/source/dialogs/prnsetup.cxx b/svtools/source/dialogs/prnsetup.cxx
index ddadba678879..498f03862ecb 100644
--- a/svtools/source/dialogs/prnsetup.cxx
+++ b/svtools/source/dialogs/prnsetup.cxx
@@ -323,7 +323,7 @@ bool PrinterSetupDialog::Notify( NotifyEvent& rNEvt )
void PrinterSetupDialog::DataChanged( const DataChangedEvent& rDCEvt )
{
- if ( rDCEvt.GetType() == DATACHANGED_PRINTER )
+ if ( rDCEvt.GetType() == DataChangedEventType::PRINTER )
{
mpTempPrinter = ImplPrnDlgUpdatePrinter( mpPrinter, mpTempPrinter );
Printer* pPrn;
diff --git a/svtools/source/toolpanel/paneltabbar.cxx b/svtools/source/toolpanel/paneltabbar.cxx
index d8813475f84d..484cc3cc9d5d 100644
--- a/svtools/source/toolpanel/paneltabbar.cxx
+++ b/svtools/source/toolpanel/paneltabbar.cxx
@@ -1297,7 +1297,7 @@ namespace svt
{
Control::DataChanged( i_rDataChanedEvent );
- if ( ( i_rDataChanedEvent.GetType() == DATACHANGED_SETTINGS )
+ if ( ( i_rDataChanedEvent.GetType() == DataChangedEventType::SETTINGS )
&& ( ( i_rDataChanedEvent.GetFlags() & SETTINGS_STYLE ) != 0 )
)
{
diff --git a/svtools/source/toolpanel/toolpaneldrawer.cxx b/svtools/source/toolpanel/toolpaneldrawer.cxx
index 8fce1ad89f1c..d63840924903 100644
--- a/svtools/source/toolpanel/toolpaneldrawer.cxx
+++ b/svtools/source/toolpanel/toolpaneldrawer.cxx
@@ -257,7 +257,7 @@ namespace svt
switch ( i_rEvent.GetType() )
{
- case DATACHANGED_SETTINGS:
+ case DataChangedEventType::SETTINGS:
if ( ( i_rEvent.GetFlags() & SETTINGS_STYLE ) == 0 )
break;
SetSettings( Application::GetSettings() );
@@ -265,8 +265,8 @@ namespace svt
// fall through.
- case DATACHANGED_FONTS:
- case DATACHANGED_FONTSUBSTITUTION:
+ case DataChangedEventType::FONTS:
+ case DataChangedEventType::FONTSUBSTITUTION:
{
const StyleSettings& rStyleSettings( GetSettings().GetStyleSettings() );
@@ -288,6 +288,7 @@ namespace svt
Invalidate();
}
break;
+ default: break;
}
}