summaryrefslogtreecommitdiff
path: root/forms/source/richtext
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2016-11-08 10:38:54 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2016-11-08 09:49:48 +0000
commitbbf6c5171706e55edcf8e011a536264f4f2efd99 (patch)
tree086e73ba7bcfb3a489b3e2523708e2a088245618 /forms/source/richtext
parentbca707d0ec55c35e048405b05c9e283cf6b97239 (diff)
loplugin:expandablemethods in forms..formula
Change-Id: Idc948ad06913def28cb642c3a4e5ea9322b9fb3b Reviewed-on: https://gerrit.libreoffice.org/30688 Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> Tested-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'forms/source/richtext')
-rw-r--r--forms/source/richtext/featuredispatcher.cxx8
-rw-r--r--forms/source/richtext/featuredispatcher.hxx2
-rw-r--r--forms/source/richtext/richtextcontrol.cxx22
-rw-r--r--forms/source/richtext/richtextcontrol.hxx6
-rw-r--r--forms/source/richtext/richtextvclcontrol.cxx8
-rw-r--r--forms/source/richtext/richtextvclcontrol.hxx1
6 files changed, 6 insertions, 41 deletions
diff --git a/forms/source/richtext/featuredispatcher.cxx b/forms/source/richtext/featuredispatcher.cxx
index 30bb442ea414..6da6c8d9ba85 100644
--- a/forms/source/richtext/featuredispatcher.cxx
+++ b/forms/source/richtext/featuredispatcher.cxx
@@ -76,7 +76,7 @@ namespace frm
if ( _rxControl.is() )
{
m_aStatusListeners.addInterface( _rxControl );
- newStatusListener( _rxControl );
+ doNotify( _rxControl, buildStatusEvent() );
}
}
@@ -113,12 +113,6 @@ namespace frm
}
- void ORichTextFeatureDispatcher::newStatusListener( const Reference< XStatusListener >& _rxListener )
- {
- doNotify( _rxListener, buildStatusEvent() );
- }
-
-
void ORichTextFeatureDispatcher::doNotify( const Reference< XStatusListener >& _rxListener, const FeatureStateEvent& _rEvent )
{
OSL_PRECOND( _rxListener.is(), "ORichTextFeatureDispatcher::doNotify: invalid listener!" );
diff --git a/forms/source/richtext/featuredispatcher.hxx b/forms/source/richtext/featuredispatcher.hxx
index 425735b582ac..4fc296272bd0 100644
--- a/forms/source/richtext/featuredispatcher.hxx
+++ b/forms/source/richtext/featuredispatcher.hxx
@@ -65,7 +65,6 @@ namespace frm
void invalidate();
protected:
- void newStatusListener( const css::uno::Reference< css::frame::XStatusListener >& _rxListener );
// overridables
virtual void disposing( ::osl::ClearableMutexGuard& _rClearBeforeNotify );
virtual void invalidateFeatureState_Broadcast();
@@ -79,7 +78,6 @@ namespace frm
const css::frame::FeatureStateEvent& _rEvent
);
- protected:
// XDispatch
virtual void SAL_CALL addStatusListener( const css::uno::Reference< css::frame::XStatusListener >& _rxControl, const css::util::URL& _rURL ) throw (css::uno::RuntimeException, std::exception) override;
virtual void SAL_CALL removeStatusListener( const css::uno::Reference< css::frame::XStatusListener >& _rxControl, const css::util::URL& _rURL ) throw (css::uno::RuntimeException, std::exception) override;
diff --git a/forms/source/richtext/richtextcontrol.cxx b/forms/source/richtext/richtextcontrol.cxx
index b961a320d638..a9f8775c415e 100644
--- a/forms/source/richtext/richtextcontrol.cxx
+++ b/forms/source/richtext/richtextcontrol.cxx
@@ -215,30 +215,16 @@ namespace frm
}
}
-
OUString SAL_CALL ORichTextControl::getImplementationName() throw( RuntimeException, std::exception )
{
- return getImplementationName_Static();
- }
-
-
- Sequence< OUString > SAL_CALL ORichTextControl::getSupportedServiceNames() throw( RuntimeException, std::exception )
- {
- return getSupportedServiceNames_Static();
- }
-
- OUString SAL_CALL ORichTextControl::getImplementationName_Static()
- {
return OUString( "com.sun.star.comp.form.ORichTextControl" );
}
- Sequence< OUString > SAL_CALL ORichTextControl::getSupportedServiceNames_Static()
+ Sequence< OUString > SAL_CALL ORichTextControl::getSupportedServiceNames() throw( RuntimeException, std::exception )
{
- Sequence< OUString > aServices( 3 );
- aServices[ 0 ] = "com.sun.star.awt.UnoControl";
- aServices[ 1 ] = "com.sun.star.awt.UnoControlEdit";
- aServices[ 2 ] = FRM_SUN_CONTROL_RICHTEXTCONTROL;
- return aServices;
+ return { "com.sun.star.awt.UnoControl",
+ "com.sun.star.awt.UnoControlEdit",
+ FRM_SUN_CONTROL_RICHTEXTCONTROL };
}
Reference< XDispatch > SAL_CALL ORichTextControl::queryDispatch( const css::util::URL& _rURL, const OUString& _rTargetFrameName, sal_Int32 _nSearchFlags ) throw (RuntimeException, std::exception)
diff --git a/forms/source/richtext/richtextcontrol.hxx b/forms/source/richtext/richtextcontrol.hxx
index 993bd21edff5..f0b9cb66c775 100644
--- a/forms/source/richtext/richtextcontrol.hxx
+++ b/forms/source/richtext/richtextcontrol.hxx
@@ -51,12 +51,6 @@ namespace frm
protected:
virtual ~ORichTextControl() override;
- public:
- // XServiceInfo - static version
- static OUString SAL_CALL getImplementationName_Static();
- static css::uno::Sequence< OUString > SAL_CALL getSupportedServiceNames_Static();
-
- protected:
// UNO
DECLARE_UNO3_AGG_DEFAULTS( ORichTextControl, UnoEditControl )
virtual css::uno::Any SAL_CALL queryAggregation( const css::uno::Type& _rType ) throw ( css::uno::RuntimeException, std::exception ) override;
diff --git a/forms/source/richtext/richtextvclcontrol.cxx b/forms/source/richtext/richtextvclcontrol.cxx
index d072bad88927..5dcf54c7131f 100644
--- a/forms/source/richtext/richtextvclcontrol.cxx
+++ b/forms/source/richtext/richtextvclcontrol.cxx
@@ -160,7 +160,7 @@ namespace frm
void RichTextControl::GetFocus()
{
- getViewport().GrabFocus();
+ m_pImpl->getViewport( RichTextControlImpl::GrantAccess() )->GrabFocus();
}
@@ -320,12 +320,6 @@ namespace frm
}
- vcl::Window& RichTextControl::getViewport() const
- {
- return *m_pImpl->getViewport( RichTextControlImpl::GrantAccess() );
- }
-
-
void RichTextControl::SetReadOnly( bool _bReadOnly )
{
m_pImpl->SetReadOnly( _bReadOnly );
diff --git a/forms/source/richtext/richtextvclcontrol.hxx b/forms/source/richtext/richtextvclcontrol.hxx
index 6725ab78bd5f..00c366369f3c 100644
--- a/forms/source/richtext/richtextvclcontrol.hxx
+++ b/forms/source/richtext/richtextvclcontrol.hxx
@@ -118,7 +118,6 @@ namespace frm
private:
EditEngine& getEngine() const;
- vcl::Window& getViewport() const;
};