From c4cd079b8f613084a99a83b95c3968b65cbd8900 Mon Sep 17 00:00:00 2001 From: Noel Grandin Date: Thu, 22 Sep 2016 15:08:42 +0200 Subject: loplugin:unusedmethods in sc..vcl Change-Id: I70fcf95dfd3db05b4fd6e5cee37866f673d3afa8 Reviewed-on: https://gerrit.libreoffice.org/29183 Reviewed-by: Noel Grandin Tested-by: Noel Grandin --- sw/inc/IDocumentUndoRedo.hxx | 4 ---- sw/inc/docary.hxx | 3 --- sw/inc/tblafmt.hxx | 1 - sw/inc/unodraw.hxx | 3 --- sw/source/core/doc/docfmt.cxx | 16 ---------------- sw/source/core/inc/layfrm.hxx | 5 ----- sw/source/core/unocore/unodraw.cxx | 6 ------ sw/source/uibase/inc/navipi.hxx | 2 -- sw/source/uibase/sidebar/PagePropertyPanel.cxx | 17 ----------------- sw/source/uibase/sidebar/PagePropertyPanel.hxx | 5 ----- sw/source/uibase/utlui/navipi.cxx | 10 ---------- 11 files changed, 72 deletions(-) (limited to 'sw') diff --git a/sw/inc/IDocumentUndoRedo.hxx b/sw/inc/IDocumentUndoRedo.hxx index 15e3d0aa7842..d05eafda20e2 100644 --- a/sw/inc/IDocumentUndoRedo.hxx +++ b/sw/inc/IDocumentUndoRedo.hxx @@ -207,10 +207,6 @@ public: */ virtual size_t GetUndoActionCount(const bool bCurrentLevel = true) const = 0; - /** Get the number of Redo actions. - */ - virtual size_t GetRedoActionCount(const bool bCurrentLevel = true) const = 0; - /** Return undo/redo info for this view. */ virtual void SetView(SwView* pView) = 0; diff --git a/sw/inc/docary.hxx b/sw/inc/docary.hxx index c98f143983bd..105cae3786f8 100644 --- a/sw/inc/docary.hxx +++ b/sw/inc/docary.hxx @@ -235,11 +235,8 @@ public: bool Contains( const value_type& x ) const; inline bool Contains( const SwFormat* p ) const; - void DeleteAndDestroy( int aStartIdx, int aEndIdx ); void DeleteAndDestroyAll( bool keepDefault = false ); - size_t GetPos( const value_type& x ) const; - bool newDefault( const value_type& x ); void newDefault( const_iterator const& position ); }; diff --git a/sw/inc/tblafmt.hxx b/sw/inc/tblafmt.hxx index c403cb0d0435..5092eddb6cc1 100644 --- a/sw/inc/tblafmt.hxx +++ b/sw/inc/tblafmt.hxx @@ -375,7 +375,6 @@ public: SwCellStyleDescriptor(const std::pair& rCellStyleDesc) : m_rCellStyleDesc(rCellStyleDesc) { } const OUString& GetName() { return m_rCellStyleDesc.first; } - SwBoxAutoFormat* GetFormat() { return m_rCellStyleDesc.second; } }; class SwCellStyleTable diff --git a/sw/inc/unodraw.hxx b/sw/inc/unodraw.hxx index 64facb537236..b7ef5beaa4ec 100644 --- a/sw/inc/unodraw.hxx +++ b/sw/inc/unodraw.hxx @@ -109,9 +109,6 @@ public: SwFmDrawPage* GetSvxPage(); // renamed and outlined to detect where it's called void InvalidateSwDoc(); // {pDoc = 0;} - SwDoc* GetDoc(); - /// Same as getByIndex(nIndex), except that it also takes a set of formats to ignore, so the method itself doesn't have to generate such a list. - css::uno::Any getByIndex(sal_Int32 nIndex, std::set* pTextBoxes) throw(css::lang::IndexOutOfBoundsException, css::lang::WrappedTargetException, css::uno::RuntimeException, std::exception); }; class SwShapeDescriptor_Impl; diff --git a/sw/source/core/doc/docfmt.cxx b/sw/source/core/doc/docfmt.cxx index ffc932bae57f..3393d13ff379 100644 --- a/sw/source/core/doc/docfmt.cxx +++ b/sw/source/core/doc/docfmt.cxx @@ -2061,16 +2061,6 @@ SwFrameFormats::rangeFind( const value_type& x ) const return rangeFind( x->Which(), x->GetName() ); } -void SwFrameFormats::DeleteAndDestroy(int aStartIdx, int aEndIdx) -{ - if (aEndIdx < aStartIdx) - return; - for (const_iterator it = begin() + aStartIdx; - it != begin() + aEndIdx; ++it) - delete *it; - m_PosIndex.erase( begin() + aStartIdx, begin() + aEndIdx); -} - void SwFrameFormats::DeleteAndDestroyAll( bool keepDefault ) { if ( empty() ) @@ -2084,12 +2074,6 @@ void SwFrameFormats::DeleteAndDestroyAll( bool keepDefault ) clear(); } -size_t SwFrameFormats::GetPos( const value_type& x ) const -{ - const_iterator const it = find( x ); - return it == end() ? SIZE_MAX : it - begin(); -} - std::pair SwFrameFormats::push_back( const value_type& x ) { SAL_WARN_IF(x->m_ffList != nullptr, "sw", "Inserting already assigned item"); diff --git a/sw/source/core/inc/layfrm.hxx b/sw/source/core/inc/layfrm.hxx index 1c7e3324ca43..125bb6ebf6c8 100644 --- a/sw/source/core/inc/layfrm.hxx +++ b/sw/source/core/inc/layfrm.hxx @@ -41,11 +41,6 @@ class SwLayoutFrame: public SwFrame friend SwFrame* SaveContent( SwLayoutFrame *, SwFrame * ); friend void RestoreContent( SwFrame *, SwLayoutFrame *, SwFrame *pSibling, bool bGrow ); -#ifdef DBG_UTIL - //removes empty SwSectionFrames from a chain - friend SwFrame* SwClearDummies( SwFrame* pFrame ); -#endif - protected: virtual void DestroyImpl() override; diff --git a/sw/source/core/unocore/unodraw.cxx b/sw/source/core/unocore/unodraw.cxx index e89ed1433831..7aa7bceb0370 100644 --- a/sw/source/core/unocore/unodraw.cxx +++ b/sw/source/core/unocore/unodraw.cxx @@ -844,12 +844,6 @@ void SwXDrawPage::InvalidateSwDoc() pDoc = nullptr; } -SwDoc* SwXDrawPage::GetDoc() -{ - return pDoc; -} - - namespace { class theSwXShapeUnoTunnelId : public rtl::Static< UnoTunnelIdInit, theSwXShapeUnoTunnelId > {}; diff --git a/sw/source/uibase/inc/navipi.hxx b/sw/source/uibase/inc/navipi.hxx index b1635c94421c..daeed3fc94f1 100644 --- a/sw/source/uibase/inc/navipi.hxx +++ b/sw/source/uibase/inc/navipi.hxx @@ -138,8 +138,6 @@ public: virtual ~SwNavigationPI() override; virtual void dispose() override; - void GotoPage(); // jump to page; bindable function - void UpdateListBox(); void MoveOutline(sal_uInt16 nSource, sal_uInt16 nTarget, bool bWithCilds); diff --git a/sw/source/uibase/sidebar/PagePropertyPanel.cxx b/sw/source/uibase/sidebar/PagePropertyPanel.cxx index f754118a8844..9094088b250e 100644 --- a/sw/source/uibase/sidebar/PagePropertyPanel.cxx +++ b/sw/source/uibase/sidebar/PagePropertyPanel.cxx @@ -75,23 +75,6 @@ namespace { namespace sw { namespace sidebar { -VclPtr PagePropertyPanel::Create ( - vcl::Window* pParent, - const css::uno::Reference< css::frame::XFrame>& rxFrame, - SfxBindings* pBindings) -{ - if (pParent == nullptr) - throw css::lang::IllegalArgumentException("no parent Window given to PagePropertyPanel::Create", nullptr, 0); - if ( ! rxFrame.is()) - throw css::lang::IllegalArgumentException("no XFrame given to PagePropertyPanel::Create", nullptr, 1); - if (pBindings == nullptr) - throw css::lang::IllegalArgumentException("no SfxBindings given to PagePropertyPanel::Create", nullptr, 2); - - return VclPtr::Create( pParent, - rxFrame, - pBindings); -} - PagePropertyPanel::PagePropertyPanel( vcl::Window* pParent, const css::uno::Reference< css::frame::XFrame>& rxFrame, diff --git a/sw/source/uibase/sidebar/PagePropertyPanel.hxx b/sw/source/uibase/sidebar/PagePropertyPanel.hxx index a798c43cfc09..a9bded236ef1 100644 --- a/sw/source/uibase/sidebar/PagePropertyPanel.hxx +++ b/sw/source/uibase/sidebar/PagePropertyPanel.hxx @@ -54,11 +54,6 @@ namespace sw { namespace sidebar { public ::sfx2::sidebar::ControllerItem::ItemUpdateReceiverInterface { public: - static VclPtr Create( - vcl::Window* pParent, - const css::uno::Reference< css::frame::XFrame>& rxFrame, - SfxBindings* pBindings ); - // interface of ::sfx2::sidebar::ControllerItem::ItemUpdateReceiverInterface virtual void NotifyItemUpdate( const sal_uInt16 nSId, diff --git a/sw/source/uibase/utlui/navipi.cxx b/sw/source/uibase/utlui/navipi.cxx index 31827aec353d..9212c076ae47 100644 --- a/sw/source/uibase/utlui/navipi.cxx +++ b/sw/source/uibase/utlui/navipi.cxx @@ -525,16 +525,6 @@ void SwNavigationPI::MakeMark() m_nAutoMarkIdx = 0; } -void SwNavigationPI::GotoPage() -{ - if (m_pContextWin && m_pContextWin->GetFloatingWindow() && m_pContextWin->GetFloatingWindow()->IsRollUp()) - ZoomIn(); - if(IsGlobalMode()) - ToggleTree(); - UsePage(); - GetPageEdit().GrabFocus(); -} - void SwNavigationPI::ZoomOut() { if (IsZoomedIn()) -- cgit