diff options
author | Noel Grandin <noel@peralex.com> | 2015-01-20 12:38:10 +0200 |
---|---|---|
committer | Noel Grandin <noel@peralex.com> | 2015-01-26 08:42:28 +0200 |
commit | b44cbb26efe1d0b0950b1e1613e131b506dc3876 (patch) | |
tree | 9b4d5d99e5dad0971079b997a02a6d96536709ca /svtools | |
parent | 26ad60aec69310fecd918f1c2e09056aa4782320 (diff) |
new loplugin: change virtual methods to non-virtual
Where we can prove that the virtual method is never overriden.
In the case of pure-virtual methods, we remove the method entirely.
Sometimes this leads to entire methods and fields being
eliminated.
Change-Id: I138ef81c95f115dbd8c023a83cfc7e9d5d6d14ae
Diffstat (limited to 'svtools')
-rw-r--r-- | svtools/inc/roadmap.hxx | 2 | ||||
-rw-r--r-- | svtools/inc/table/tablecontrol.hxx | 2 | ||||
-rw-r--r-- | svtools/inc/vclxaccessibleheaderbaritem.hxx | 4 | ||||
-rw-r--r-- | svtools/source/brwbox/datwin.hxx | 2 | ||||
-rw-r--r-- | svtools/source/control/toolbarmenuimp.hxx | 4 | ||||
-rw-r--r-- | svtools/source/control/valueimp.hxx | 4 | ||||
-rw-r--r-- | svtools/source/dialogs/addresstemplate.cxx | 2 | ||||
-rw-r--r-- | svtools/source/table/tablecontrol_impl.cxx | 4 | ||||
-rw-r--r-- | svtools/source/table/tablecontrol_impl.hxx | 4 | ||||
-rw-r--r-- | svtools/source/table/tabledatawindow.hxx | 4 |
10 files changed, 14 insertions, 18 deletions
diff --git a/svtools/inc/roadmap.hxx b/svtools/inc/roadmap.hxx index 362f797e5a09..c12e7449a725 100644 --- a/svtools/inc/roadmap.hxx +++ b/svtools/inc/roadmap.hxx @@ -93,7 +93,7 @@ namespace svt protected: /// called when an item has been selected by any means - virtual void Select(); + void Select(); private: DECL_LINK(ImplClickHdl, HyperLabel*); diff --git a/svtools/inc/table/tablecontrol.hxx b/svtools/inc/table/tablecontrol.hxx index 7b0e01bf0b8d..cde9465ed222 100644 --- a/svtools/inc/table/tablecontrol.hxx +++ b/svtools/inc/table/tablecontrol.hxx @@ -135,7 +135,7 @@ namespace svt { namespace table } SVT_DLLPRIVATE virtual void Resize() SAL_OVERRIDE; - virtual void Select(); + void Select(); /**after removing a row, updates the vector which contains the selected rows if the row, which should be removed, is selected, it will be erased from the vector diff --git a/svtools/inc/vclxaccessibleheaderbaritem.hxx b/svtools/inc/vclxaccessibleheaderbaritem.hxx index 144364f9f495..3274c7e72b36 100644 --- a/svtools/inc/vclxaccessibleheaderbaritem.hxx +++ b/svtools/inc/vclxaccessibleheaderbaritem.hxx @@ -58,8 +58,8 @@ private: protected: - virtual void ProcessWindowEvent( const VclWindowEvent& rVclWindowEvent ); - virtual void FillAccessibleStateSet( utl::AccessibleStateSetHelper& rStateSet ); + void ProcessWindowEvent( const VclWindowEvent& rVclWindowEvent ); + void FillAccessibleStateSet( utl::AccessibleStateSetHelper& rStateSet ); // OCommonAccessibleComponent virtual ::com::sun::star::awt::Rectangle implGetBounds( ) throw (::com::sun::star::uno::RuntimeException) SAL_OVERRIDE; diff --git a/svtools/source/brwbox/datwin.hxx b/svtools/source/brwbox/datwin.hxx index bff17665e392..d6d69910425d 100644 --- a/svtools/source/brwbox/datwin.hxx +++ b/svtools/source/brwbox/datwin.hxx @@ -88,7 +88,7 @@ public: bool IsFrozen() const { return _bFrozen; } void Freeze( bool bFreeze = true ) { _bFrozen = bFreeze; } - virtual void Draw( BrowseBox& rBox, OutputDevice& rDev, + void Draw( BrowseBox& rBox, OutputDevice& rDev, const Point& rPos, bool bCurs ); void SetWidth(sal_uLong nNewWidthPixel, const Fraction& rCurrentZoom); diff --git a/svtools/source/control/toolbarmenuimp.hxx b/svtools/source/control/toolbarmenuimp.hxx index 9a32d694fff4..55aca40b9cf4 100644 --- a/svtools/source/control/toolbarmenuimp.hxx +++ b/svtools/source/control/toolbarmenuimp.hxx @@ -162,7 +162,7 @@ public: virtual ::com::sun::star::awt::Point SAL_CALL getLocationOnScreen( ) throw (::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE; virtual ::com::sun::star::awt::Size SAL_CALL getSize( ) throw (::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE; virtual void SAL_CALL grabFocus( ) throw (::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE; - virtual ::com::sun::star::uno::Any SAL_CALL getAccessibleKeyBinding( ) throw (::com::sun::star::uno::RuntimeException); + ::com::sun::star::uno::Any SAL_CALL getAccessibleKeyBinding( ) throw (::com::sun::star::uno::RuntimeException); virtual sal_Int32 SAL_CALL getForeground( ) throw (::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE; virtual sal_Int32 SAL_CALL getBackground( ) throw (::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE; @@ -250,7 +250,7 @@ public: virtual ::com::sun::star::awt::Point SAL_CALL getLocationOnScreen( ) throw (::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE; virtual ::com::sun::star::awt::Size SAL_CALL getSize( ) throw (::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE; virtual void SAL_CALL grabFocus( ) throw (::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE; - virtual ::com::sun::star::uno::Any SAL_CALL getAccessibleKeyBinding( ) throw (::com::sun::star::uno::RuntimeException); + ::com::sun::star::uno::Any SAL_CALL getAccessibleKeyBinding( ) throw (::com::sun::star::uno::RuntimeException); virtual sal_Int32 SAL_CALL getForeground( ) throw (::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE; virtual sal_Int32 SAL_CALL getBackground( ) throw (::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE; diff --git a/svtools/source/control/valueimp.hxx b/svtools/source/control/valueimp.hxx index 4b2cf9f54ebf..9773363eb213 100644 --- a/svtools/source/control/valueimp.hxx +++ b/svtools/source/control/valueimp.hxx @@ -138,7 +138,7 @@ public: virtual ::com::sun::star::awt::Point SAL_CALL getLocationOnScreen( ) throw (::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE; virtual ::com::sun::star::awt::Size SAL_CALL getSize( ) throw (::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE; virtual void SAL_CALL grabFocus( ) throw (::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE; - virtual ::com::sun::star::uno::Any SAL_CALL getAccessibleKeyBinding( ) throw (::com::sun::star::uno::RuntimeException); + ::com::sun::star::uno::Any SAL_CALL getAccessibleKeyBinding( ) throw (::com::sun::star::uno::RuntimeException); virtual sal_Int32 SAL_CALL getForeground( ) throw (::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE; virtual sal_Int32 SAL_CALL getBackground( ) throw (::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE; @@ -258,7 +258,7 @@ public: virtual ::com::sun::star::awt::Point SAL_CALL getLocationOnScreen( ) throw (::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE; virtual ::com::sun::star::awt::Size SAL_CALL getSize( ) throw (::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE; virtual void SAL_CALL grabFocus( ) throw (::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE; - virtual ::com::sun::star::uno::Any SAL_CALL getAccessibleKeyBinding( ) throw (::com::sun::star::uno::RuntimeException); + ::com::sun::star::uno::Any SAL_CALL getAccessibleKeyBinding( ) throw (::com::sun::star::uno::RuntimeException); virtual sal_Int32 SAL_CALL getForeground( ) throw (::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE; virtual sal_Int32 SAL_CALL getBackground( ) throw (::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE; diff --git a/svtools/source/dialogs/addresstemplate.cxx b/svtools/source/dialogs/addresstemplate.cxx index f94ec3041bd2..7b07a9d3186a 100644 --- a/svtools/source/dialogs/addresstemplate.cxx +++ b/svtools/source/dialogs/addresstemplate.cxx @@ -283,7 +283,7 @@ public: virtual void Commit() SAL_OVERRIDE; private: - virtual void clearFieldAssignment(const OUString& _rLogicalName); + void clearFieldAssignment(const OUString& _rLogicalName); }; diff --git a/svtools/source/table/tablecontrol_impl.cxx b/svtools/source/table/tablecontrol_impl.cxx index fc52b5441e68..a9a7607a5c93 100644 --- a/svtools/source/table/tablecontrol_impl.cxx +++ b/svtools/source/table/tablecontrol_impl.cxx @@ -136,10 +136,6 @@ namespace svt { namespace table { return 5 * 100; } - virtual void setRowHeight(TableMetrics _nRowHeight) - { - (void)_nRowHeight; - } virtual TableMetrics getColumnHeaderHeight() const SAL_OVERRIDE { return 0; diff --git a/svtools/source/table/tablecontrol_impl.hxx b/svtools/source/table/tablecontrol_impl.hxx index 0c2da1f191ab..f905504d111e 100644 --- a/svtools/source/table/tablecontrol_impl.hxx +++ b/svtools/source/table/tablecontrol_impl.hxx @@ -276,8 +276,8 @@ namespace svt { namespace table virtual long pixelWidthToAppFont( long const i_pixels ) const SAL_OVERRIDE; virtual void hideTracking() SAL_OVERRIDE; virtual void showTracking( Rectangle const & i_location, sal_uInt16 const i_flags ) SAL_OVERRIDE; - virtual RowPos getRowAtPoint( const Point& rPoint ) const; - virtual ColPos getColAtPoint( const Point& rPoint ) const; + RowPos getRowAtPoint( const Point& rPoint ) const; + ColPos getColAtPoint( const Point& rPoint ) const; virtual TableCell hitTest( const Point& rPoint ) const SAL_OVERRIDE; virtual ColumnMetrics getColumnMetrics( ColPos const i_column ) const SAL_OVERRIDE; virtual bool isRowSelected( RowPos i_row ) const SAL_OVERRIDE; diff --git a/svtools/source/table/tabledatawindow.hxx b/svtools/source/table/tabledatawindow.hxx index c606d6a4b205..2b9b7c6c9507 100644 --- a/svtools/source/table/tabledatawindow.hxx +++ b/svtools/source/table/tabledatawindow.hxx @@ -59,8 +59,8 @@ namespace svt { namespace table virtual void MouseButtonDown( const MouseEvent& rMEvt) SAL_OVERRIDE; virtual void MouseButtonUp( const MouseEvent& rMEvt) SAL_OVERRIDE; virtual bool Notify(NotifyEvent& rNEvt) SAL_OVERRIDE; - virtual void SetControlBackground(const Color& rColor); - virtual void SetControlBackground(); + void SetControlBackground(const Color& rColor); + void SetControlBackground(); virtual void RequestHelp( const HelpEvent& rHEvt ) SAL_OVERRIDE; void SetBackground(const Wallpaper& rColor); |