From 0f96b3f33f98ecd56f0fe55a65315d6762ff978a Mon Sep 17 00:00:00 2001 From: Noel Grandin Date: Mon, 7 Nov 2016 09:31:52 +0200 Subject: loplugin:unnecessaryvirtual in test..vbahelper Change-Id: I0e110af6eab798e11f96d0f7d282d59440d91965 Reviewed-on: https://gerrit.libreoffice.org/30649 Reviewed-by: Noel Grandin Tested-by: Noel Grandin --- vbahelper/source/msforms/vbalistcontrolhelper.hxx | 3 +-- vbahelper/source/vbahelper/vbaapplicationbase.cxx | 6 +++--- vbahelper/source/vbahelper/vbacommandbarhelper.cxx | 3 +-- 3 files changed, 5 insertions(+), 7 deletions(-) (limited to 'vbahelper/source') diff --git a/vbahelper/source/msforms/vbalistcontrolhelper.hxx b/vbahelper/source/msforms/vbalistcontrolhelper.hxx index ad580f4812da..e60b52b9a133 100644 --- a/vbahelper/source/msforms/vbalistcontrolhelper.hxx +++ b/vbahelper/source/msforms/vbalistcontrolhelper.hxx @@ -22,13 +22,12 @@ #include -class ListControlHelper +class ListControlHelper final { css::uno::Reference< css::beans::XPropertySet > m_xProps; public: explicit ListControlHelper( const css::uno::Reference< css::beans::XPropertySet >& rxControl ) : m_xProps( rxControl ){} - virtual ~ListControlHelper() {} void SAL_CALL AddItem( const css::uno::Any& pvargItem, const css::uno::Any& pvargIndex ) throw (css::uno::RuntimeException); void SAL_CALL removeItem( const css::uno::Any& index ) throw (css::uno::RuntimeException); void SAL_CALL setRowSource( const OUString& _rowsource ) throw (css::uno::RuntimeException); diff --git a/vbahelper/source/vbahelper/vbaapplicationbase.cxx b/vbahelper/source/vbahelper/vbaapplicationbase.cxx index 80ef3040a93d..d505da474560 100644 --- a/vbahelper/source/vbahelper/vbaapplicationbase.cxx +++ b/vbahelper/source/vbahelper/vbaapplicationbase.cxx @@ -69,7 +69,7 @@ public: VbaTimer() {} - virtual ~VbaTimer() + ~VbaTimer() { m_aTimer.Stop(); } @@ -151,14 +151,14 @@ struct VbaTimerInfoHash typedef std::unordered_map< VbaTimerInfo, VbaTimer*, VbaTimerInfoHash > VbaTimerHashMap; // ====VbaApplicationBase_Impl================================== -struct VbaApplicationBase_Impl +struct VbaApplicationBase_Impl final { VbaTimerHashMap m_aTimerHash; bool mbVisible; inline VbaApplicationBase_Impl() : mbVisible( true ) {} - virtual ~VbaApplicationBase_Impl() + ~VbaApplicationBase_Impl() { // remove the remaining timers for ( VbaTimerHashMap::iterator aIter = m_aTimerHash.begin(); diff --git a/vbahelper/source/vbahelper/vbacommandbarhelper.cxx b/vbahelper/source/vbahelper/vbacommandbarhelper.cxx index 8bd5fb02a6b6..5c82007317ae 100644 --- a/vbahelper/source/vbahelper/vbacommandbarhelper.cxx +++ b/vbahelper/source/vbahelper/vbacommandbarhelper.cxx @@ -38,7 +38,7 @@ using namespace ooo::vba; typedef std::map< OUString, OUString > MSO2OOCommandbarMap; -class MSO2OOCommandbarHelper +class MSO2OOCommandbarHelper final { private: static MSO2OOCommandbarHelper* pMSO2OOCommandbarHelper; @@ -61,7 +61,6 @@ private: } public: - virtual ~MSO2OOCommandbarHelper() {}; static MSO2OOCommandbarHelper* getMSO2OOCommandbarHelper() { if( pMSO2OOCommandbarHelper == nullptr ) -- cgit v1.2.3