diff options
author | Miklos Vajna <vmiklos@collabora.com> | 2022-01-31 09:24:26 +0100 |
---|---|---|
committer | Miklos Vajna <vmiklos@collabora.com> | 2022-01-31 17:25:31 +0100 |
commit | 1cdff0363727327d3bf0e7d5eb105e867ba2d806 (patch) | |
tree | 87f723420031491564170df1361ebbb512771b14 /sw | |
parent | e1dc4a5815a56eef27d2c83f7971e0eb1ac09b45 (diff) |
sw: prefix members of SwPagePreview, SwScrollbar, ...
... sw::sidebar::PageStylesPanel and sw::sidebar::WrapPropertyPanel
See tdf#94879 for motivation.
Change-Id: I8eb8be59b9fad087fadb2735c46133aca4810415
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/129199
Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
Tested-by: Jenkins
Diffstat (limited to 'sw')
-rw-r--r-- | sw/source/uibase/inc/scroll.hxx | 16 | ||||
-rw-r--r-- | sw/source/uibase/sidebar/PageStylesPanel.cxx | 10 | ||||
-rw-r--r-- | sw/source/uibase/sidebar/PageStylesPanel.hxx | 2 | ||||
-rw-r--r-- | sw/source/uibase/sidebar/WrapPropertyPanel.cxx | 32 | ||||
-rw-r--r-- | sw/source/uibase/sidebar/WrapPropertyPanel.hxx | 10 | ||||
-rw-r--r-- | sw/source/uibase/uiview/scroll.cxx | 34 |
6 files changed, 52 insertions, 52 deletions
diff --git a/sw/source/uibase/inc/scroll.hxx b/sw/source/uibase/inc/scroll.hxx index 6a532b0ed28d..8527e796966e 100644 --- a/sw/source/uibase/inc/scroll.hxx +++ b/sw/source/uibase/inc/scroll.hxx @@ -22,11 +22,11 @@ class SwScrollbar final : public ScrollBar { - Size aDocSz; - bool bHori :1; // horizontal = salTrue, otherwise vertical - bool bAuto :1; // for scrolling mode - bool bVisible :1; // show/hide should only set this flag - bool bSizeSet :1; // was the size already set? + Size m_aDocSz; + bool m_bHori :1; // horizontal = salTrue, otherwise vertical + bool m_bAuto :1; // for scrolling mode + bool m_bVisible :1; // show/hide should only set this flag + bool m_bSizeSet :1; // was the size already set? void AutoShow(); @@ -36,17 +36,17 @@ class SwScrollbar final : public ScrollBar public: void ExtendedShow( bool bVisible = true ); void SetPosSizePixel( const Point& rNewPos, const Size& rNewSize ) override; - bool IsVisible(bool bReal) const { return bReal ? ScrollBar::IsVisible() : bVisible; } + bool IsVisible(bool bReal) const { return bReal ? ScrollBar::IsVisible() : m_bVisible; } // changing of document size void DocSzChgd(const Size &rNewSize); // changing of visible region void ViewPortChgd(const tools::Rectangle &rRectangle); // what is it?? - bool IsHoriScroll() const { return bHori; } + bool IsHoriScroll() const { return m_bHori; } void SetAuto(bool bSet); - bool IsAuto() const { return bAuto;} + bool IsAuto() const { return m_bAuto;} SwScrollbar(vcl::Window *pParent, bool bHori ); virtual ~SwScrollbar() override; diff --git a/sw/source/uibase/sidebar/PageStylesPanel.cxx b/sw/source/uibase/sidebar/PageStylesPanel.cxx index 114349ba194d..c0e1e89b43e0 100644 --- a/sw/source/uibase/sidebar/PageStylesPanel.cxx +++ b/sw/source/uibase/sidebar/PageStylesPanel.cxx @@ -139,7 +139,7 @@ void PageStylesPanel::Initialize() { SvxFillTypeBox::Fill(*mxBgFillType); - aCustomEntry = mxCustomEntry->get_label(); + m_aCustomEntry = mxCustomEntry->get_label(); mpBindings->Invalidate(SID_ATTR_PAGE_COLUMN); mpBindings->Invalidate(SID_ATTR_PAGE); mpBindings->Invalidate(SID_ATTR_PAGE_FILLSTYLE); @@ -330,15 +330,15 @@ void PageStylesPanel::NotifyItemUpdate( if(mpPageColumnItem->GetValue() <= 5) { mxColumnCount->set_active(mpPageColumnItem->GetValue() - 1); - int nIndex = mxColumnCount->find_text(aCustomEntry); + int nIndex = mxColumnCount->find_text(m_aCustomEntry); if (nIndex != -1) mxColumnCount->remove(nIndex); } else { - if (mxColumnCount->find_text(aCustomEntry) == -1) - mxColumnCount->append_text(aCustomEntry); - mxColumnCount->set_active_text(aCustomEntry); + if (mxColumnCount->find_text(m_aCustomEntry) == -1) + mxColumnCount->append_text(m_aCustomEntry); + mxColumnCount->set_active_text(m_aCustomEntry); } } } diff --git a/sw/source/uibase/sidebar/PageStylesPanel.hxx b/sw/source/uibase/sidebar/PageStylesPanel.hxx index 6047d2535666..d39d2a073e67 100644 --- a/sw/source/uibase/sidebar/PageStylesPanel.hxx +++ b/sw/source/uibase/sidebar/PageStylesPanel.hxx @@ -88,7 +88,7 @@ private: std::unique_ptr<SvxPageNumberListBox> mxNumberSelectLB; std::unique_ptr<weld::ComboBox> mxBgFillType; std::unique_ptr<weld::Label> mxCustomEntry; - OUString aCustomEntry; + OUString m_aCustomEntry; void Initialize(); void Update(); diff --git a/sw/source/uibase/sidebar/WrapPropertyPanel.cxx b/sw/source/uibase/sidebar/WrapPropertyPanel.cxx index c45b0a6078ab..45cf0e61f646 100644 --- a/sw/source/uibase/sidebar/WrapPropertyPanel.cxx +++ b/sw/source/uibase/sidebar/WrapPropertyPanel.cxx @@ -55,12 +55,12 @@ WrapPropertyPanel::WrapPropertyPanel( : PanelLayout(pParent, "WrapPropertyPanel", "modules/swriter/ui/sidebarwrap.ui") , mpBindings(pBindings) // spacing - , nTop(0) - , nBottom(0) - , nLeft(0) - , nRight(0) + , m_nTop(0) + , m_nBottom(0) + , m_nLeft(0) + , m_nRight(0) // resources - , aCustomEntry(SwResId(STR_WRAP_PANEL_CUSTOM_STR)) + , m_aCustomEntry(SwResId(STR_WRAP_PANEL_CUSTOM_STR)) // controller items , maSwLRSpacingControl(SID_ATTR_LRSPACE, *pBindings, *this) , maSwULSpacingControl(SID_ATTR_ULSPACE, *pBindings, *this) @@ -94,15 +94,15 @@ void WrapPropertyPanel::Initialize() void WrapPropertyPanel::UpdateSpacingLB() { - if( (nLeft == nRight) && (nTop == nBottom) && (nLeft == nTop) ) + if( (m_nLeft == m_nRight) && (m_nTop == m_nBottom) && (m_nLeft == m_nTop) ) { sal_Int32 nCount = mxSpacingLB->get_count(); for (sal_Int32 i = 0; i < nCount; i++) { - if (mxSpacingLB->get_id(i).toUInt32() == nLeft) + if (mxSpacingLB->get_id(i).toUInt32() == m_nLeft) { mxSpacingLB->set_active(i); - int nCustomEntry = mxSpacingLB->find_text(aCustomEntry); + int nCustomEntry = mxSpacingLB->find_text(m_aCustomEntry); if (nCustomEntry != -1) mxSpacingLB->remove(nCustomEntry); return; @@ -110,9 +110,9 @@ void WrapPropertyPanel::UpdateSpacingLB() } } - if (mxSpacingLB->find_text(aCustomEntry) == -1) - mxSpacingLB->append_text(aCustomEntry); - mxSpacingLB->set_active_text(aCustomEntry); + if (mxSpacingLB->find_text(m_aCustomEntry) == -1) + mxSpacingLB->append_text(m_aCustomEntry); + mxSpacingLB->set_active_text(m_aCustomEntry); } IMPL_LINK(WrapPropertyPanel, SpacingLBHdl, weld::ComboBox&, rBox, void) @@ -122,7 +122,7 @@ IMPL_LINK(WrapPropertyPanel, SpacingLBHdl, weld::ComboBox&, rBox, void) SvxLRSpaceItem aLRItem(nVal, nVal, 0, 0, RES_LR_SPACE); SvxULSpaceItem aULItem(nVal, nVal, RES_UL_SPACE); - nTop = nBottom = nLeft = nRight = nVal; + m_nTop = m_nBottom = m_nLeft = m_nRight = nVal; mpBindings->GetDispatcher()->ExecuteList(SID_ATTR_LRSPACE, SfxCallMode::RECORD, { &aLRItem }); mpBindings->GetDispatcher()->ExecuteList(SID_ATTR_ULSPACE, @@ -143,8 +143,8 @@ void WrapPropertyPanel::NotifyItemUpdate( const SvxLRSpaceItem* pItem = dynamic_cast< const SvxLRSpaceItem* >(pState); if(pItem) { - nLeft = pItem->GetLeft(); - nRight = pItem->GetRight(); + m_nLeft = pItem->GetLeft(); + m_nRight = pItem->GetRight(); UpdateSpacingLB(); } @@ -158,8 +158,8 @@ void WrapPropertyPanel::NotifyItemUpdate( const SvxULSpaceItem* pItem = dynamic_cast< const SvxULSpaceItem* >(pState); if(pItem) { - nTop = pItem->GetUpper(); - nBottom = pItem->GetLower(); + m_nTop = pItem->GetUpper(); + m_nBottom = pItem->GetLower(); UpdateSpacingLB(); } diff --git a/sw/source/uibase/sidebar/WrapPropertyPanel.hxx b/sw/source/uibase/sidebar/WrapPropertyPanel.hxx index 319085513e1b..d81cf71c97d0 100644 --- a/sw/source/uibase/sidebar/WrapPropertyPanel.hxx +++ b/sw/source/uibase/sidebar/WrapPropertyPanel.hxx @@ -57,13 +57,13 @@ namespace sw::sidebar { SfxBindings* mpBindings; //Spacing - sal_uInt16 nTop; - sal_uInt16 nBottom; - sal_uInt16 nLeft; - sal_uInt16 nRight; + sal_uInt16 m_nTop; + sal_uInt16 m_nBottom; + sal_uInt16 m_nLeft; + sal_uInt16 m_nRight; //custom entry - OUString aCustomEntry; + OUString m_aCustomEntry; // Controller Items ::sfx2::sidebar::ControllerItem maSwLRSpacingControl; diff --git a/sw/source/uibase/uiview/scroll.cxx b/sw/source/uibase/uiview/scroll.cxx index 1bd4bd1e9338..a277a5972276 100644 --- a/sw/source/uibase/uiview/scroll.cxx +++ b/sw/source/uibase/uiview/scroll.cxx @@ -24,10 +24,10 @@ SwScrollbar::SwScrollbar( vcl::Window *pWin, bool bHoriz ) : ScrollBar( pWin, WinBits( WB_3DLOOK | WB_HIDE | ( bHoriz ? WB_HSCROLL : WB_VSCROLL) ) ), - bHori( bHoriz ), - bAuto( false ), - bVisible(false), - bSizeSet(false) + m_bHori( bHoriz ), + m_bAuto( false ), + m_bVisible(false), + m_bSizeSet(false) { // No mirroring for horizontal scrollbars if( bHoriz ) @@ -41,8 +41,8 @@ SwScrollbar::SwScrollbar( vcl::Window *pWin, bool bHoriz ) : void SwScrollbar::DocSzChgd( const Size &rSize ) { - aDocSz = rSize; - SetRange( Range( 0, bHori ? rSize.Width() : rSize.Height()) ); + m_aDocSz = rSize; + SetRange( Range( 0, m_bHori ? rSize.Width() : rSize.Height()) ); const sal_uLong nVisSize = GetVisibleSize(); SetLineSize( SCROLL_LINE_SIZE ); SetPageSize( nVisSize * 77 / 100 ); @@ -53,7 +53,7 @@ void SwScrollbar::DocSzChgd( const Size &rSize ) void SwScrollbar::ViewPortChgd( const tools::Rectangle &rRect ) { tools::Long nThumb, nVisible; - if( bHori ) + if( m_bHori ) { nThumb = rRect.Left(); nVisible = rRect.GetWidth(); @@ -65,38 +65,38 @@ void SwScrollbar::ViewPortChgd( const tools::Rectangle &rRect ) } SetVisibleSize( nVisible ); - DocSzChgd(aDocSz); + DocSzChgd(m_aDocSz); SetThumbPos( nThumb ); - if(bAuto) + if(m_bAuto) AutoShow(); } void SwScrollbar::ExtendedShow( bool bSet ) { - bVisible = bSet; - if( (!bSet || !bAuto) && IsUpdateMode() && bSizeSet) + m_bVisible = bSet; + if( (!bSet || !m_bAuto) && IsUpdateMode() && m_bSizeSet) ScrollBar::Show(bSet); } void SwScrollbar::SetPosSizePixel( const Point& rNewPos, const Size& rNewSize ) { ScrollBar::SetPosSizePixel(rNewPos, rNewSize); - bSizeSet = true; - if(bVisible) + m_bSizeSet = true; + if(m_bVisible) ExtendedShow(); } void SwScrollbar::SetAuto(bool bSet) { - if(bAuto != bSet) + if(m_bAuto != bSet) { - bAuto = bSet; + m_bAuto = bSet; // hide automatically - then show - if(!bAuto && bVisible && !ScrollBar::IsVisible()) + if(!m_bAuto && m_bVisible && !ScrollBar::IsVisible()) ExtendedShow(); - else if(bAuto) + else if(m_bAuto) AutoShow(); // or hide automatically } } |