From a66731982e93cdcc5beaa5b0586a7f12a7fc0ef6 Mon Sep 17 00:00:00 2001 From: Noel Grandin Date: Thu, 8 Dec 2016 10:26:01 +0200 Subject: convert SFX_HINT to scoped enum Notes (*) In SC, BULK_DATACHANGED was or'ed into the hint id. Replaced with a dynamic_cast check. (*) In SC, removed the hint id field from ScIndexHint, no point in storing the hint id twice (*) Fold the SfxStyleSheetHintId enum into the new SfxHintId enum, no point in storing two different hint ids (*) In some cases, multiple #define's used to map to the same SFX_HINT value (notably the SFX_HINT_USER* values). I made all of those separate values. Change-Id: I990e2fb587335ebc51c9005588c6a44f768d9de5 Reviewed-on: https://gerrit.libreoffice.org/31751 Reviewed-by: Noel Grandin Tested-by: Noel Grandin --- svtools/source/config/accessibilityoptions.cxx | 2 +- svtools/source/config/extcolorcfg.cxx | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) (limited to 'svtools') diff --git a/svtools/source/config/accessibilityoptions.cxx b/svtools/source/config/accessibilityoptions.cxx index 32bd75a5973c..95f82913fd12 100644 --- a/svtools/source/config/accessibilityoptions.cxx +++ b/svtools/source/config/accessibilityoptions.cxx @@ -391,7 +391,7 @@ SvtAccessibilityOptions::~SvtAccessibilityOptions() void SvtAccessibilityOptions::Notify( SfxBroadcaster&, const SfxHint& rHint ) { NotifyListeners(ConfigurationHints::NONE); - if ( rHint.GetId() == SFX_HINT_ACCESSIBILITY_CHANGED ) + if ( rHint.GetId() == SfxHintId::AccessibilityChanged ) SetVCLSettings(); } diff --git a/svtools/source/config/extcolorcfg.cxx b/svtools/source/config/extcolorcfg.cxx index 9c6c9d187140..07ba461c310b 100644 --- a/svtools/source/config/extcolorcfg.cxx +++ b/svtools/source/config/extcolorcfg.cxx @@ -396,7 +396,7 @@ void ExtendedColorConfig_Impl::Notify( const uno::Sequence& /*rProp m_bBroadcastWhenUnlocked = true; } else - Broadcast(SfxHint(SFX_HINT_COLORS_CHANGED)); + Broadcast(SfxHint(SfxHintId::ColorsChanged)); } void ExtendedColorConfig_Impl::ImplCommit() @@ -495,7 +495,7 @@ void ExtendedColorConfig_Impl::SettingsChanged() { SolarMutexGuard aVclGuard; - Broadcast( SfxHint( SFX_HINT_COLORS_CHANGED ) ); + Broadcast( SfxHint( SfxHintId::ColorsChanged ) ); } void ExtendedColorConfig_Impl::LockBroadcast() @@ -513,7 +513,7 @@ void ExtendedColorConfig_Impl::UnlockBroadcast() if ( ExtendedColorConfig::m_pImpl && ExtendedColorConfig::m_pImpl->m_bIsBroadcastEnabled ) { m_bBroadcastWhenUnlocked = false; - ExtendedColorConfig::m_pImpl->Broadcast(SfxHint(SFX_HINT_COLORS_CHANGED)); + ExtendedColorConfig::m_pImpl->Broadcast(SfxHint(SfxHintId::ColorsChanged)); } } } -- cgit