summaryrefslogtreecommitdiff
path: root/sfx2
diff options
context:
space:
mode:
authorStephan Bergmann <sbergman@redhat.com>2015-02-07 12:28:22 +0100
committerStephan Bergmann <sbergman@redhat.com>2015-02-07 12:36:02 +0100
commit68adf20e1e89d6e19e8122b600c0fb675eaebdbd (patch)
tree19e09bef0cd43236230e79fc8acbb79fa0b13a78 /sfx2
parentb48874cd54deaacd858f9eaf0557d2b01bc25806 (diff)
loplugin:deletedspecial
Change-Id: Ib9e704c3b27dad81eea44583c99ecdbc5449dd13
Diffstat (limited to 'sfx2')
-rw-r--r--sfx2/source/appl/imestatuswindow.hxx4
-rw-r--r--sfx2/source/doc/doctemplateslocal.hxx2
-rw-r--r--sfx2/source/inc/statcach.hxx2
-rw-r--r--sfx2/source/menu/thessubmenu.hxx6
-rw-r--r--sfx2/source/sidebar/DeckLayouter.cxx79
-rw-r--r--sfx2/source/sidebar/DeckLayouter.hxx72
6 files changed, 78 insertions, 87 deletions
diff --git a/sfx2/source/appl/imestatuswindow.hxx b/sfx2/source/appl/imestatuswindow.hxx
index 116812defaee..df8fe533b0c5 100644
--- a/sfx2/source/appl/imestatuswindow.hxx
+++ b/sfx2/source/appl/imestatuswindow.hxx
@@ -88,8 +88,8 @@ public:
using ImeStatusWindow_Impl::operator delete;
private:
- ImeStatusWindow(ImeStatusWindow &); // not implemented
- void operator =(const ImeStatusWindow&); // not implemented
+ ImeStatusWindow(ImeStatusWindow &) SAL_DELETED_FUNCTION;
+ void operator =(const ImeStatusWindow&) SAL_DELETED_FUNCTION;
virtual ~ImeStatusWindow();
diff --git a/sfx2/source/doc/doctemplateslocal.hxx b/sfx2/source/doc/doctemplateslocal.hxx
index d0890e070362..626f15e7d2f7 100644
--- a/sfx2/source/doc/doctemplateslocal.hxx
+++ b/sfx2/source/doc/doctemplateslocal.hxx
@@ -38,7 +38,7 @@ class DocTemplLocaleHelper : public cppu::WeakImplHelper1 < com::sun::star::xml:
::com::sun::star::uno::Sequence< ::com::sun::star::beans::StringPair > m_aResultSeq;
::com::sun::star::uno::Sequence< OUString > m_aElementsSeq; // stack of elements being parsed
- DocTemplLocaleHelper(); // must not be created directly
+ DocTemplLocaleHelper();
::com::sun::star::uno::Sequence< ::com::sun::star::beans::StringPair > GetParsingResult();
static ::com::sun::star::uno::Sequence< ::com::sun::star::beans::StringPair > SAL_CALL ReadLocalizationSequence_Impl( const ::com::sun::star::uno::Reference< ::com::sun::star::io::XInputStream >& xInStream, const OUString& aStringID, const ::com::sun::star::uno::Reference< ::com::sun::star::uno::XComponentContext > xContext )
diff --git a/sfx2/source/inc/statcach.hxx b/sfx2/source/inc/statcach.hxx
index 65fdb57c5e60..f2fb797edf15 100644
--- a/sfx2/source/inc/statcach.hxx
+++ b/sfx2/source/inc/statcach.hxx
@@ -76,7 +76,7 @@ friend class BindDispatch_Impl;
bool bItemDirty; // Validity of pLastItem
private:
- SfxStateCache( const SfxStateCache& rOrig ); // inward
+ SfxStateCache( const SfxStateCache& rOrig ) SAL_DELETED_FUNCTION;
void SetState_Impl( SfxItemState, const SfxPoolItem*, bool bMaybeDirty=false );
public:
diff --git a/sfx2/source/menu/thessubmenu.hxx b/sfx2/source/menu/thessubmenu.hxx
index 94af27e0b5c6..226e9b103af5 100644
--- a/sfx2/source/menu/thessubmenu.hxx
+++ b/sfx2/source/menu/thessubmenu.hxx
@@ -33,10 +33,8 @@ class SfxThesSubMenuHelper
css::uno::Reference< css::linguistic2::XThesaurus > m_xThesarus;
private:
-
- // don't use copy constructor and assignment operator
- SfxThesSubMenuHelper( const SfxThesSubMenuHelper & );
- SfxThesSubMenuHelper & operator = ( const SfxThesSubMenuHelper & );
+ SfxThesSubMenuHelper( const SfxThesSubMenuHelper & ) SAL_DELETED_FUNCTION;
+ SfxThesSubMenuHelper & operator = ( const SfxThesSubMenuHelper & ) SAL_DELETED_FUNCTION;
public:
SfxThesSubMenuHelper();
diff --git a/sfx2/source/sidebar/DeckLayouter.cxx b/sfx2/source/sidebar/DeckLayouter.cxx
index a7639fbd6aac..9d831a7628df 100644
--- a/sfx2/source/sidebar/DeckLayouter.cxx
+++ b/sfx2/source/sidebar/DeckLayouter.cxx
@@ -35,6 +35,64 @@ namespace sfx2 { namespace sidebar {
namespace {
static const sal_Int32 MinimalPanelHeight (25);
+
+ enum LayoutMode
+ {
+ MinimumOrLarger,
+ PreferredOrLarger,
+ Preferred
+ };
+ class LayoutItem
+ {
+ public:
+ SharedPanel mpPanel;
+ css::ui::LayoutSize maLayoutSize;
+ sal_Int32 mnDistributedHeight;
+ sal_Int32 mnWeight;
+ sal_Int32 mnPanelIndex;
+ bool mbShowTitleBar;
+
+ LayoutItem (void)
+ : mpPanel(),maLayoutSize(0,0,0),mnDistributedHeight(0),mnWeight(0),mnPanelIndex(0),mbShowTitleBar(true)
+ {}
+ };
+ Rectangle LayoutPanels (
+ const Rectangle aContentArea,
+ sal_Int32& rMinimalWidth,
+ ::std::vector<LayoutItem>& rLayoutItems,
+ vcl::Window& rScrollClipWindow,
+ vcl::Window& rScrollContainer,
+ ScrollBar& pVerticalScrollBar,
+ const bool bShowVerticalScrollBar);
+ void GetRequestedSizes (
+ ::std::vector<LayoutItem>& rLayoutItem,
+ sal_Int32& rAvailableHeight,
+ sal_Int32& rMinimalWidth,
+ const Rectangle& rContentBox);
+ void DistributeHeights (
+ ::std::vector<LayoutItem>& rLayoutItems,
+ const sal_Int32 nHeightToDistribute,
+ const sal_Int32 nContainerHeight,
+ const bool bMinimumHeightIsBase);
+ sal_Int32 PlacePanels (
+ ::std::vector<LayoutItem>& rLayoutItems,
+ const sal_Int32 nWidth,
+ const LayoutMode eMode,
+ vcl::Window& rScrollContainer);
+ Rectangle PlaceDeckTitle (
+ vcl::Window& rTittleBar,
+ const Rectangle& rAvailableSpace);
+ Rectangle PlaceVerticalScrollBar (
+ ScrollBar& rVerticalScrollBar,
+ const Rectangle& rAvailableSpace,
+ const bool bShowVerticalScrollBar);
+ void SetupVerticalScrollBar(
+ ScrollBar& rVerticalScrollBar,
+ const sal_Int32 nContentHeight,
+ const sal_Int32 nVisibleHeight);
+ void UpdateFiller (
+ vcl::Window& rFiller,
+ const Rectangle& rBox);
}
#define IterateLayoutItems(iterator_name,container) \
@@ -82,10 +140,9 @@ void DeckLayouter::LayoutDeck (
UpdateFiller(rFiller, aBox);
}
+namespace {
-
-
-Rectangle DeckLayouter::LayoutPanels (
+Rectangle LayoutPanels (
const Rectangle aContentArea,
sal_Int32& rMinimalWidth,
::std::vector<LayoutItem>& rLayoutItems,
@@ -193,7 +250,7 @@ Rectangle DeckLayouter::LayoutPanels (
-sal_Int32 DeckLayouter::PlacePanels (
+sal_Int32 PlacePanels (
::std::vector<LayoutItem>& rLayoutItems,
const sal_Int32 nWidth,
const LayoutMode eMode,
@@ -288,7 +345,7 @@ sal_Int32 DeckLayouter::PlacePanels (
-void DeckLayouter::GetRequestedSizes (
+void GetRequestedSizes (
::std::vector<LayoutItem>& rLayoutItems,
sal_Int32& rAvailableHeight,
sal_Int32& rMinimalWidth,
@@ -343,7 +400,7 @@ void DeckLayouter::GetRequestedSizes (
-void DeckLayouter::DistributeHeights (
+void DistributeHeights (
::std::vector<LayoutItem>& rLayoutItems,
const sal_Int32 nHeightToDistribute,
const sal_Int32 nContainerHeight,
@@ -428,7 +485,7 @@ void DeckLayouter::DistributeHeights (
-Rectangle DeckLayouter::PlaceDeckTitle (
+Rectangle PlaceDeckTitle (
vcl::Window& rDeckTitleBar,
const Rectangle& rAvailableSpace)
{
@@ -458,7 +515,7 @@ Rectangle DeckLayouter::PlaceDeckTitle (
-Rectangle DeckLayouter::PlaceVerticalScrollBar (
+Rectangle PlaceVerticalScrollBar (
ScrollBar& rVerticalScrollBar,
const Rectangle& rAvailableSpace,
const bool bShowVerticalScrollBar)
@@ -488,7 +545,7 @@ Rectangle DeckLayouter::PlaceVerticalScrollBar (
-void DeckLayouter::SetupVerticalScrollBar(
+void SetupVerticalScrollBar(
ScrollBar& rVerticalScrollBar,
const sal_Int32 nContentHeight,
const sal_Int32 nVisibleHeight)
@@ -503,7 +560,7 @@ void DeckLayouter::SetupVerticalScrollBar(
-void DeckLayouter::UpdateFiller (
+void UpdateFiller (
vcl::Window& rFiller,
const Rectangle& rBox)
{
@@ -521,7 +578,7 @@ void DeckLayouter::UpdateFiller (
}
}
-
+}
} } // end of namespace sfx2::sidebar
diff --git a/sfx2/source/sidebar/DeckLayouter.hxx b/sfx2/source/sidebar/DeckLayouter.hxx
index fa2b5ea8bcda..9421829e33b0 100644
--- a/sfx2/source/sidebar/DeckLayouter.hxx
+++ b/sfx2/source/sidebar/DeckLayouter.hxx
@@ -35,13 +35,12 @@ namespace sfx2 { namespace sidebar {
class Panel;
-/** Helper class for layouting the direct and indirect children of a
+/** Helper for layouting the direct and indirect children of a
deck like title bars, panels, and scroll bars.
*/
-class DeckLayouter
+namespace DeckLayouter
{
-public:
- static void LayoutDeck (
+ void LayoutDeck (
const Rectangle aContentArea,
sal_Int32& rMinimalWidth,
SharedPanelContainer& rPanels,
@@ -50,70 +49,7 @@ public:
vcl::Window& pScrollContainer,
vcl::Window& pFiller,
ScrollBar& pVerticalScrollBar);
-
-private:
- // Do not use constructor or destructor.
- DeckLayouter (void);
- ~DeckLayouter (void);
-
- enum LayoutMode
- {
- MinimumOrLarger,
- PreferredOrLarger,
- Preferred
- };
- class LayoutItem
- {
- public:
- SharedPanel mpPanel;
- css::ui::LayoutSize maLayoutSize;
- sal_Int32 mnDistributedHeight;
- sal_Int32 mnWeight;
- sal_Int32 mnPanelIndex;
- bool mbShowTitleBar;
-
- LayoutItem (void)
- : mpPanel(),maLayoutSize(0,0,0),mnDistributedHeight(0),mnWeight(0),mnPanelIndex(0),mbShowTitleBar(true)
- {}
- };
- static Rectangle LayoutPanels (
- const Rectangle aContentArea,
- sal_Int32& rMinimalWidth,
- ::std::vector<LayoutItem>& rLayoutItems,
- vcl::Window& rScrollClipWindow,
- vcl::Window& rScrollContainer,
- ScrollBar& pVerticalScrollBar,
- const bool bShowVerticalScrollBar);
- static void GetRequestedSizes (
- ::std::vector<LayoutItem>& rLayoutItem,
- sal_Int32& rAvailableHeight,
- sal_Int32& rMinimalWidth,
- const Rectangle& rContentBox);
- static void DistributeHeights (
- ::std::vector<LayoutItem>& rLayoutItems,
- const sal_Int32 nHeightToDistribute,
- const sal_Int32 nContainerHeight,
- const bool bMinimumHeightIsBase);
- static sal_Int32 PlacePanels (
- ::std::vector<LayoutItem>& rLayoutItems,
- const sal_Int32 nWidth,
- const LayoutMode eMode,
- vcl::Window& rScrollContainer);
- static Rectangle PlaceDeckTitle (
- vcl::Window& rTittleBar,
- const Rectangle& rAvailableSpace);
- static Rectangle PlaceVerticalScrollBar (
- ScrollBar& rVerticalScrollBar,
- const Rectangle& rAvailableSpace,
- const bool bShowVerticalScrollBar);
- static void SetupVerticalScrollBar(
- ScrollBar& rVerticalScrollBar,
- const sal_Int32 nContentHeight,
- const sal_Int32 nVisibleHeight);
- static void UpdateFiller (
- vcl::Window& rFiller,
- const Rectangle& rBox);
-};
+}
} } // end of namespace sfx2::sidebar