diff options
author | Noel Grandin <noel.grandin@collabora.co.uk> | 2018-09-11 09:39:03 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2018-09-11 14:01:00 +0200 |
commit | 7430dfe2a4a3b13ffa248bf14a3a2ca87993f48d (patch) | |
tree | 3b9607225ec2df9934b71df223c482ca7a069ff1 /include/sfx2 | |
parent | 3b835b8d546ca16d7edcb06eda017e276383ea0f (diff) |
loplugin:unusedmethods
Change-Id: I34009aabf0befb346470b5c0d96ad8fc476b7c4e
Reviewed-on: https://gerrit.libreoffice.org/60300
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'include/sfx2')
-rw-r--r-- | include/sfx2/controlwrapper.hxx | 78 | ||||
-rw-r--r-- | include/sfx2/dialoghelper.hxx | 4 | ||||
-rw-r--r-- | include/sfx2/itemwrapper.hxx | 15 |
3 files changed, 0 insertions, 97 deletions
diff --git a/include/sfx2/controlwrapper.hxx b/include/sfx2/controlwrapper.hxx index 8de68755da48..bce078a487c3 100644 --- a/include/sfx2/controlwrapper.hxx +++ b/include/sfx2/controlwrapper.hxx @@ -259,7 +259,6 @@ public: virtual ValueT GetControlValue() const SAL_OVERRIDE; virtual void SetControlValue( ValueT nValue ) SAL_OVERRIDE; - bool IsControlValueChanged() const; private: FieldUnit meUnit; @@ -332,76 +331,6 @@ public: }; -// Multi control wrappers - - -struct MultiControlWrapperHelper_Impl; - -/** A container of control wrappers. - - Derived classes should define control wrapper members and register them in - their constructor, using the function RegisterControlWrapper(). - - This wrapper implements the abstract functions of the ControlWrapperBase - base class by calling the functions of all registered wrappers. - */ -class SFX2_DLLPUBLIC MultiControlWrapperHelper : public ControlWrapperBase -{ -public: - explicit MultiControlWrapperHelper(); - virtual ~MultiControlWrapperHelper() override; - - /** Registers a control wrapper (should be a member of a derived class). */ - void RegisterControlWrapper( ControlWrapperBase& rWrapper ); - - /** Enables, disables, shows, or hides the registered controls. */ - virtual void ModifyControl( TriState eShow ) override; - - /** Returns true if all registered controls are in "don't know" state. */ - virtual bool IsControlDontKnow() const override; - /** Sets all registered controls to "don't know" state. */ - virtual void SetControlDontKnow( bool bSet ) override; - -private: - std::unique_ptr< MultiControlWrapperHelper_Impl > mxImpl; -}; - - -/** A multi control wrapper with extended interface. - - This template class extends the MultiControlWrapperHelper class by the - functions GetControlValue() and SetControlValue(), known from the - SingleControlWrapper template. This makes it possible to use this template - in item connections expecting a single control wrapper. The type ValueT - should be able to contain the values of all controls handled in this - wrapper. In most cases, the easiest way to achieve this is to use the - related item type directly, using the IdentItemWrapper template - (itemwrapper.hxx). - */ -template< typename ValueT > -class MultiControlWrapper : public MultiControlWrapperHelper -{ -public: - typedef MultiControlWrapperHelper ControlType; - typedef ValueT ControlValueType; - - MultiControlWrapper() : maDefValue( 0 ){} - - /** Returns the default value that can be used in GetControlValue(). */ - const ValueT& GetDefaultValue() const { return maDefValue; } - /** Sets a default value that can be used in GetControlValue(). */ - void SetDefaultValue( const ValueT& rDefValue ) { maDefValue = rDefValue; } - - /** Derived classes return the value the control contains. */ - virtual ValueT GetControlValue() const = 0; - /** Derived classes set the contents of the control to the passed value. */ - virtual void SetControlValue( ValueT aValue ) = 0; - -private: - ValueT maDefValue; -}; - - // *** Implementation of template functions *** @@ -482,13 +411,6 @@ void MetricFieldWrapper< ValueT >::SetControlValue( ValueT nValue ) } template< typename ValueT > -bool MetricFieldWrapper< ValueT >::IsControlValueChanged() const -{ - return this->GetControl().IsValueChangedFromSaved(); -} - - -template< typename ValueT > ValueT ListBoxWrapper< ValueT >::GetControlValue() const { return this->GetValueFromPos( this->GetControl().GetSelectedEntryPos() ); diff --git a/include/sfx2/dialoghelper.hxx b/include/sfx2/dialoghelper.hxx index ed06d76b733d..b0d9ae5b5cfe 100644 --- a/include/sfx2/dialoghelper.hxx +++ b/include/sfx2/dialoghelper.hxx @@ -25,10 +25,6 @@ class VclBuilderContainer; //the preview appears in the same place in each one so flipping between tabs //isn't distracting as it jumps around -//there has to be a "maingrid" container which contains all the widgets -//except for the preview widget -void SFX2_DLLPUBLIC setPreviewsToSamePlace(vcl::Window const *pParent, VclBuilderContainer *pPage); - Size SFX2_DLLPUBLIC getParagraphPreviewOptimalSize(const OutputDevice& rReference); Size SFX2_DLLPUBLIC getDrawPreviewOptimalSize(const vcl::Window *pReference); diff --git a/include/sfx2/itemwrapper.hxx b/include/sfx2/itemwrapper.hxx index c20f088703ce..3f1bf7c5eb9f 100644 --- a/include/sfx2/itemwrapper.hxx +++ b/include/sfx2/itemwrapper.hxx @@ -145,21 +145,6 @@ typedef ValueItemWrapper< SfxUInt16Item, sal_uInt16 > UInt16ItemWrapper; typedef ValueItemWrapper< SfxInt32Item, sal_Int32 > Int32ItemWrapper; -/** An item wrapper that uses the item itself as value. */ -template< typename ItemT > -class IdentItemWrapper : public SingleItemWrapper< ItemT, const ItemT& > -{ -public: - explicit IdentItemWrapper( sal_uInt16 nSlot ) : - SingleItemWrapper< ItemT, const ItemT& >( nSlot ) {} - - virtual const ItemT& GetItemValue( const ItemT& rItem ) const SAL_OVERRIDE - { return rItem; } - virtual void SetItemValue( ItemT& rItem, const ItemT& rValue ) const SAL_OVERRIDE - { rItem = rValue; } -}; - - // *** Implementation of template functions *** |