summaryrefslogtreecommitdiff
path: root/sw/source/uibase
diff options
context:
space:
mode:
authorArmin Le Grand (Allotropia) <armin.le.grand@me.com>2021-06-17 10:17:25 +0200
committerArmin Le Grand <Armin.Le.Grand@me.com>2021-06-18 11:10:56 +0200
commit04cd6749177f886f382e8bcd026f95112ee22473 (patch)
treeb74693c1a738add2df00cedc85397720598f3021 /sw/source/uibase
parent6317f8cc83ec92b8700785ab67c4c66ed1aa8fb2 (diff)
tdf#130428 remove unnecessary usage of SfxItemState::UNKNOWN
Rename ::StateChanged methods using SfxItemState to allow better analysis of SfxItemState/SfxPoolItem usage(s), discussion see tdf#130428 comment 30 Change-Id: I736be0160ad7a9b7882c1c8a4cc05d9396ee3305 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/117366 Tested-by: Jenkins Reviewed-by: Armin Le Grand <Armin.Le.Grand@me.com>
Diffstat (limited to 'sw/source/uibase')
-rw-r--r--sw/source/uibase/inc/bookctrl.hxx4
-rw-r--r--sw/source/uibase/inc/tmplctrl.hxx4
-rw-r--r--sw/source/uibase/inc/viewlayoutctrl.hxx2
-rw-r--r--sw/source/uibase/inc/wordcountctrl.hxx4
-rw-r--r--sw/source/uibase/inc/workctrl.hxx4
-rw-r--r--sw/source/uibase/inc/zoomctrl.hxx4
-rw-r--r--sw/source/uibase/ribbar/workctrl.cxx4
-rw-r--r--sw/source/uibase/utlui/bookctrl.cxx2
-rw-r--r--sw/source/uibase/utlui/tmplctrl.cxx2
-rw-r--r--sw/source/uibase/utlui/viewlayoutctrl.cxx2
-rw-r--r--sw/source/uibase/utlui/wordcountctrl.cxx2
-rw-r--r--sw/source/uibase/utlui/zoomctrl.cxx4
12 files changed, 19 insertions, 19 deletions
diff --git a/sw/source/uibase/inc/bookctrl.hxx b/sw/source/uibase/inc/bookctrl.hxx
index d35252ceac4c..3b064a1daa22 100644
--- a/sw/source/uibase/inc/bookctrl.hxx
+++ b/sw/source/uibase/inc/bookctrl.hxx
@@ -27,8 +27,8 @@ class SwBookmarkControl final : public SfxStatusBarControl
virtual void Command(const CommandEvent& rCEvt) override;
public:
- virtual void StateChanged(sal_uInt16 nSID, SfxItemState eState,
- const SfxPoolItem* pState) override;
+ virtual void StateChangedAtStatusBarControl(sal_uInt16 nSID, SfxItemState eState,
+ const SfxPoolItem* pState) override;
virtual void Paint(const UserDrawEvent& rEvt) override;
SFX_DECL_STATUSBAR_CONTROL();
diff --git a/sw/source/uibase/inc/tmplctrl.hxx b/sw/source/uibase/inc/tmplctrl.hxx
index dfd0af308625..df8ed5170b04 100644
--- a/sw/source/uibase/inc/tmplctrl.hxx
+++ b/sw/source/uibase/inc/tmplctrl.hxx
@@ -26,8 +26,8 @@ class SwTemplateControl final : public SfxStatusBarControl
virtual void Command(const CommandEvent& rCEvt) override;
public:
- virtual void StateChanged(sal_uInt16 nSID, SfxItemState eState,
- const SfxPoolItem* pState) override;
+ virtual void StateChangedAtStatusBarControl(sal_uInt16 nSID, SfxItemState eState,
+ const SfxPoolItem* pState) override;
virtual void Paint(const UserDrawEvent& rEvt) override;
SFX_DECL_STATUSBAR_CONTROL();
diff --git a/sw/source/uibase/inc/viewlayoutctrl.hxx b/sw/source/uibase/inc/viewlayoutctrl.hxx
index 716b5fdbfbf5..a13f9ff52b2c 100644
--- a/sw/source/uibase/inc/viewlayoutctrl.hxx
+++ b/sw/source/uibase/inc/viewlayoutctrl.hxx
@@ -36,7 +36,7 @@ public:
SwViewLayoutControl( sal_uInt16 nSlotId, sal_uInt16 nId, StatusBar& rStb );
virtual ~SwViewLayoutControl() override;
- virtual void StateChanged( sal_uInt16 nSID, SfxItemState eState, const SfxPoolItem* pState ) override;
+ virtual void StateChangedAtStatusBarControl( sal_uInt16 nSID, SfxItemState eState, const SfxPoolItem* pState ) override;
virtual void Paint( const UserDrawEvent& rEvt ) override;
virtual bool MouseButtonDown( const MouseEvent & ) override;
virtual bool MouseMove( const MouseEvent & ) override;
diff --git a/sw/source/uibase/inc/wordcountctrl.hxx b/sw/source/uibase/inc/wordcountctrl.hxx
index 2079729741e9..8074253b3645 100644
--- a/sw/source/uibase/inc/wordcountctrl.hxx
+++ b/sw/source/uibase/inc/wordcountctrl.hxx
@@ -27,8 +27,8 @@ public:
SwWordCountStatusBarControl(sal_uInt16 nSlotId, sal_uInt16 nId, StatusBar& rStb);
virtual ~SwWordCountStatusBarControl() override;
- virtual void StateChanged(sal_uInt16 nSID, SfxItemState eState,
- const SfxPoolItem* pState) override;
+ virtual void StateChangedAtStatusBarControl(sal_uInt16 nSID, SfxItemState eState,
+ const SfxPoolItem* pState) override;
};
#endif
diff --git a/sw/source/uibase/inc/workctrl.hxx b/sw/source/uibase/inc/workctrl.hxx
index 1ffa50ead702..d478f6ba997a 100644
--- a/sw/source/uibase/inc/workctrl.hxx
+++ b/sw/source/uibase/inc/workctrl.hxx
@@ -60,7 +60,7 @@ public:
virtual ~SwTbxAutoTextCtrl() override;
virtual void CreatePopupWindow() override;
- virtual void StateChanged( sal_uInt16 nSID,
+ virtual void StateChangedAtToolBoxControl( sal_uInt16 nSID,
SfxItemState eState,
const SfxPoolItem* pState ) override;
@@ -75,7 +75,7 @@ public:
SwPreviewZoomControl( sal_uInt16 nSlotId, ToolBoxItemId nId, ToolBox& rTbx );
virtual ~SwPreviewZoomControl() override;
- virtual void StateChanged( sal_uInt16 nSID,
+ virtual void StateChangedAtToolBoxControl( sal_uInt16 nSID,
SfxItemState eState,
const SfxPoolItem* pState ) override;
diff --git a/sw/source/uibase/inc/zoomctrl.hxx b/sw/source/uibase/inc/zoomctrl.hxx
index 38119e0b5a68..58dccbcbdbb4 100644
--- a/sw/source/uibase/inc/zoomctrl.hxx
+++ b/sw/source/uibase/inc/zoomctrl.hxx
@@ -28,8 +28,8 @@ private:
public:
virtual void Command(const CommandEvent& rCEvt) override;
- virtual void StateChanged(sal_uInt16 nSID, SfxItemState eState,
- const SfxPoolItem* pState) override;
+ virtual void StateChangedAtStatusBarControl(sal_uInt16 nSID, SfxItemState eState,
+ const SfxPoolItem* pState) override;
virtual void Paint(const UserDrawEvent& rEvt) override;
SFX_DECL_STATUSBAR_CONTROL();
diff --git a/sw/source/uibase/ribbar/workctrl.cxx b/sw/source/uibase/ribbar/workctrl.cxx
index 52c3a572dee2..2c7e08c23a56 100644
--- a/sw/source/uibase/ribbar/workctrl.cxx
+++ b/sw/source/uibase/ribbar/workctrl.cxx
@@ -128,7 +128,7 @@ void SwTbxAutoTextCtrl::CreatePopupWindow()
GetToolBox().EndSelection();
}
-void SwTbxAutoTextCtrl::StateChanged( sal_uInt16,
+void SwTbxAutoTextCtrl::StateChangedAtToolBoxControl( sal_uInt16,
SfxItemState,
const SfxPoolItem* pState )
{
@@ -495,7 +495,7 @@ SwPreviewZoomControl::~SwPreviewZoomControl()
{
}
-void SwPreviewZoomControl::StateChanged( sal_uInt16 /*nSID*/,
+void SwPreviewZoomControl::StateChangedAtToolBoxControl( sal_uInt16 /*nSID*/,
SfxItemState eState,
const SfxPoolItem* pState )
{
diff --git a/sw/source/uibase/utlui/bookctrl.cxx b/sw/source/uibase/utlui/bookctrl.cxx
index c82d40acfae8..8fb7f59f2a9a 100644
--- a/sw/source/uibase/utlui/bookctrl.cxx
+++ b/sw/source/uibase/utlui/bookctrl.cxx
@@ -49,7 +49,7 @@ SwBookmarkControl::~SwBookmarkControl()
{
}
-void SwBookmarkControl::StateChanged(
+void SwBookmarkControl::StateChangedAtStatusBarControl(
sal_uInt16 /*nSID*/, SfxItemState eState, const SfxPoolItem* pState )
{
if( eState != SfxItemState::DEFAULT || pState->IsVoidItem() )
diff --git a/sw/source/uibase/utlui/tmplctrl.cxx b/sw/source/uibase/utlui/tmplctrl.cxx
index 21cbcfc5a116..da9887745f17 100644
--- a/sw/source/uibase/utlui/tmplctrl.cxx
+++ b/sw/source/uibase/utlui/tmplctrl.cxx
@@ -48,7 +48,7 @@ SwTemplateControl::~SwTemplateControl()
{
}
-void SwTemplateControl::StateChanged(
+void SwTemplateControl::StateChangedAtStatusBarControl(
sal_uInt16 /*nSID*/, SfxItemState eState, const SfxPoolItem* pState )
{
const SfxStringItem* pItem = nullptr;
diff --git a/sw/source/uibase/utlui/viewlayoutctrl.cxx b/sw/source/uibase/utlui/viewlayoutctrl.cxx
index 9f010e73861d..22346de6b03b 100644
--- a/sw/source/uibase/utlui/viewlayoutctrl.cxx
+++ b/sw/source/uibase/utlui/viewlayoutctrl.cxx
@@ -59,7 +59,7 @@ SwViewLayoutControl::~SwViewLayoutControl()
{
}
-void SwViewLayoutControl::StateChanged( sal_uInt16 /*nSID*/, SfxItemState eState, const SfxPoolItem* pState )
+void SwViewLayoutControl::StateChangedAtStatusBarControl( sal_uInt16 /*nSID*/, SfxItemState eState, const SfxPoolItem* pState )
{
if ( SfxItemState::DEFAULT != eState || pState->IsVoidItem() )
GetStatusBar().SetItemText( GetId(), OUString() );
diff --git a/sw/source/uibase/utlui/wordcountctrl.cxx b/sw/source/uibase/utlui/wordcountctrl.cxx
index d617c611c500..66d520d99a21 100644
--- a/sw/source/uibase/utlui/wordcountctrl.cxx
+++ b/sw/source/uibase/utlui/wordcountctrl.cxx
@@ -27,7 +27,7 @@ SwWordCountStatusBarControl::~SwWordCountStatusBarControl()
{
}
-void SwWordCountStatusBarControl::StateChanged(
+void SwWordCountStatusBarControl::StateChangedAtStatusBarControl(
sal_uInt16 /*nSID*/, SfxItemState eState, const SfxPoolItem* pState )
{
if (eState == SfxItemState::DEFAULT) // Can access pState
diff --git a/sw/source/uibase/utlui/zoomctrl.cxx b/sw/source/uibase/utlui/zoomctrl.cxx
index 493b2f9b7828..3f7ff7021fcf 100644
--- a/sw/source/uibase/utlui/zoomctrl.cxx
+++ b/sw/source/uibase/utlui/zoomctrl.cxx
@@ -36,7 +36,7 @@ SwZoomControl::~SwZoomControl()
{
}
-void SwZoomControl::StateChanged( sal_uInt16 nSID, SfxItemState eState,
+void SwZoomControl::StateChangedAtStatusBarControl( sal_uInt16 nSID, SfxItemState eState,
const SfxPoolItem* pState )
{
const SfxStringItem* pItem = nullptr;
@@ -48,7 +48,7 @@ void SwZoomControl::StateChanged( sal_uInt16 nSID, SfxItemState eState,
else
{
sPreviewZoom.clear();
- SvxZoomStatusBarControl::StateChanged(nSID, eState, pState);
+ SvxZoomStatusBarControl::StateChangedAtStatusBarControl(nSID, eState, pState);
}
}