diff options
author | Noel Grandin <noel.grandin@collabora.co.uk> | 2017-06-21 14:42:23 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2017-06-22 08:44:08 +0200 |
commit | 60f3e9b67e688e6f7f304cc7fb14fc28af83f351 (patch) | |
tree | 41e29cb2a424e38af454690c4fc9c7c7cd6f31fd /sd/source/ui | |
parent | 450bf26c23bf2bb4346236778ef066c6e215eafe (diff) |
loplugin:unusedfields in sd part3
Change-Id: Id8277e4b3dc9776715a7bd85e1a4f6610aad9b19
Reviewed-on: https://gerrit.libreoffice.org/39061
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'sd/source/ui')
-rw-r--r-- | sd/source/ui/dlg/dlgchar.cxx | 2 | ||||
-rw-r--r-- | sd/source/ui/docshell/docshel4.cxx | 6 | ||||
-rw-r--r-- | sd/source/ui/docshell/docshell.cxx | 9 | ||||
-rw-r--r-- | sd/source/ui/docshell/sdclient.cxx | 3 | ||||
-rw-r--r-- | sd/source/ui/framework/factories/BasicToolBarFactory.cxx | 11 | ||||
-rw-r--r-- | sd/source/ui/framework/factories/BasicToolBarFactory.hxx | 1 | ||||
-rw-r--r-- | sd/source/ui/func/fudraw.cxx | 11 | ||||
-rw-r--r-- | sd/source/ui/func/fupoor.cxx | 17 | ||||
-rw-r--r-- | sd/source/ui/inc/Client.hxx | 2 | ||||
-rw-r--r-- | sd/source/ui/inc/DrawDocShell.hxx | 1 | ||||
-rw-r--r-- | sd/source/ui/inc/FrameView.hxx | 3 | ||||
-rw-r--r-- | sd/source/ui/inc/dlg_char.hxx | 1 | ||||
-rw-r--r-- | sd/source/ui/inc/fupoor.hxx | 1 | ||||
-rw-r--r-- | sd/source/ui/slideshow/slideshow.cxx | 1 | ||||
-rw-r--r-- | sd/source/ui/view/Outliner.cxx | 6 | ||||
-rw-r--r-- | sd/source/ui/view/drviews1.cxx | 5 | ||||
-rw-r--r-- | sd/source/ui/view/frmview.cxx | 1 |
17 files changed, 7 insertions, 74 deletions
diff --git a/sd/source/ui/dlg/dlgchar.cxx b/sd/source/ui/dlg/dlgchar.cxx index bcf443767eea..57c7f2d18266 100644 --- a/sd/source/ui/dlg/dlgchar.cxx +++ b/sd/source/ui/dlg/dlgchar.cxx @@ -45,7 +45,7 @@ SdCharDlg::SdCharDlg( vcl::Window* pParent, const SfxItemSet* pAttr, mnCharName = AddTabPage( "RID_SVXPAGE_CHAR_NAME", pFact->GetTabPageCreatorFunc( RID_SVXPAGE_CHAR_NAME ), nullptr ); mnCharEffects = AddTabPage( "RID_SVXPAGE_CHAR_EFFECTS", pFact->GetTabPageCreatorFunc( RID_SVXPAGE_CHAR_EFFECTS ), nullptr ); - mnCharPosition = AddTabPage( "RID_SVXPAGE_CHAR_POSITION", pFact->GetTabPageCreatorFunc( RID_SVXPAGE_CHAR_POSITION ), nullptr ); + AddTabPage( "RID_SVXPAGE_CHAR_POSITION", pFact->GetTabPageCreatorFunc( RID_SVXPAGE_CHAR_POSITION ), nullptr ); mnCharBackground = AddTabPage( "RID_SVXPAGE_BACKGROUND", pFact->GetTabPageCreatorFunc( RID_SVXPAGE_BACKGROUND ), nullptr ); } diff --git a/sd/source/ui/docshell/docshel4.cxx b/sd/source/ui/docshell/docshel4.cxx index afaacaf55dec..40575d52a566 100644 --- a/sd/source/ui/docshell/docshel4.cxx +++ b/sd/source/ui/docshell/docshel4.cxx @@ -267,8 +267,6 @@ bool DrawDocShell::InitNew( const css::uno::Reference< css::embed::XStorage >& x */ bool DrawDocShell::Load( SfxMedium& rMedium ) { - mbNewDocument = false; - // If this is an ODF file being loaded, then by default, use legacy processing // for tdf#99729 (if required, it will be overridden in *::ReadUserDataSequence()) if (IsOwnStorageFormat(rMedium)) @@ -356,8 +354,6 @@ bool DrawDocShell::Load( SfxMedium& rMedium ) */ bool DrawDocShell::LoadFrom( SfxMedium& rMedium ) { - mbNewDocument = false; - WaitObject* pWait = nullptr; if( mpViewShell ) pWait = new WaitObject( static_cast<vcl::Window*>(mpViewShell->GetActiveWindow()) ); @@ -438,8 +434,6 @@ bool DrawDocShell::ImportFrom(SfxMedium &rMedium, */ bool DrawDocShell::ConvertFrom( SfxMedium& rMedium ) { - mbNewDocument = false; - const OUString aFilterName( rMedium.GetFilter()->GetFilterName() ); bool bRet = false; bool bStartPresentation = false; diff --git a/sd/source/ui/docshell/docshell.cxx b/sd/source/ui/docshell/docshell.cxx index 77d7cf641c8b..fa35e3a9808b 100644 --- a/sd/source/ui/docshell/docshell.cxx +++ b/sd/source/ui/docshell/docshell.cxx @@ -125,8 +125,7 @@ DrawDocShell::DrawDocShell(SfxObjectCreateMode eMode, mpFontList(nullptr), meDocType(eDocumentType), mbSdDataObj(bDataObject), - mbOwnPrinter(false), - mbNewDocument( true ) + mbOwnPrinter(false) { Construct( eMode == SfxObjectCreateMode::INTERNAL ); } @@ -140,8 +139,7 @@ DrawDocShell::DrawDocShell( SfxModelFlags nModelCreationFlags, bool bDataObject, mpFontList(nullptr), meDocType(eDocumentType), mbSdDataObj(bDataObject), - mbOwnPrinter(false), - mbNewDocument( true ) + mbOwnPrinter(false) { Construct( false ); } @@ -157,8 +155,7 @@ DrawDocShell::DrawDocShell(SdDrawDocument* pDoc, SfxObjectCreateMode eMode, mpFontList(nullptr), meDocType(eDocumentType), mbSdDataObj(bDataObject), - mbOwnPrinter(false), - mbNewDocument( true ) + mbOwnPrinter(false) { Construct( eMode == SfxObjectCreateMode::INTERNAL ); } diff --git a/sd/source/ui/docshell/sdclient.cxx b/sd/source/ui/docshell/sdclient.cxx index 68c7dbacb428..2f0c132fef79 100644 --- a/sd/source/ui/docshell/sdclient.cxx +++ b/sd/source/ui/docshell/sdclient.cxx @@ -40,8 +40,7 @@ namespace sd { Client::Client(SdrOle2Obj* pObj, ViewShell* pViewShell, vcl::Window* pWindow) : SfxInPlaceClient(pViewShell->GetViewShell(), pWindow, pObj->GetAspect() ), mpViewShell(pViewShell), - pSdrOle2Obj(pObj), - pSdrGrafObj(nullptr) + pSdrOle2Obj(pObj) { SetObject( pObj->GetObjRef() ); DBG_ASSERT( GetObject().is(), "No object connected!" ); diff --git a/sd/source/ui/framework/factories/BasicToolBarFactory.cxx b/sd/source/ui/framework/factories/BasicToolBarFactory.cxx index 407310085826..e3f183b0729f 100644 --- a/sd/source/ui/framework/factories/BasicToolBarFactory.cxx +++ b/sd/source/ui/framework/factories/BasicToolBarFactory.cxx @@ -40,8 +40,7 @@ BasicToolBarFactory::BasicToolBarFactory ( const Reference<XComponentContext>& rxContext) : BasicToolBarFactoryInterfaceBase(m_aMutex), mxConfigurationController(), - mxController(), - mpViewShellBase(nullptr) + mxController() { (void)rxContext; } @@ -57,7 +56,6 @@ void SAL_CALL BasicToolBarFactory::disposing() void BasicToolBarFactory::Shutdown() { - mpViewShellBase = nullptr; Reference<lang::XComponent> xComponent (mxConfigurationController, UNO_QUERY); if (xComponent.is()) xComponent->removeEventListener(static_cast<lang::XEventListener*>(this)); @@ -79,13 +77,6 @@ void SAL_CALL BasicToolBarFactory::initialize (const Sequence<Any>& aArguments) // Get the XController from the first argument. mxController.set(aArguments[0], UNO_QUERY_THROW); - // Tunnel through the controller to obtain a ViewShellBase. - Reference<lang::XUnoTunnel> xTunnel (mxController, UNO_QUERY_THROW); - ::sd::DrawController* pController = reinterpret_cast<sd::DrawController*>( - xTunnel->getSomething(sd::DrawController::getUnoTunnelId())); - if (pController != nullptr) - mpViewShellBase = pController->GetViewShellBase(); - utl::MediaDescriptor aDescriptor (mxController->getModel()->getArgs()); if ( ! aDescriptor.getUnpackedValueOrDefault( utl::MediaDescriptor::PROP_PREVIEW(), diff --git a/sd/source/ui/framework/factories/BasicToolBarFactory.hxx b/sd/source/ui/framework/factories/BasicToolBarFactory.hxx index fa5cabcb58e4..bdfecae20875 100644 --- a/sd/source/ui/framework/factories/BasicToolBarFactory.hxx +++ b/sd/source/ui/framework/factories/BasicToolBarFactory.hxx @@ -82,7 +82,6 @@ public: private: css::uno::Reference<css::drawing::framework::XConfigurationController> mxConfigurationController; css::uno::Reference<css::frame::XController> mxController; - ViewShellBase* mpViewShellBase; void Shutdown(); diff --git a/sd/source/ui/func/fudraw.cxx b/sd/source/ui/func/fudraw.cxx index 4494d8476e3e..068a3e03cb91 100644 --- a/sd/source/ui/func/fudraw.cxx +++ b/sd/source/ui/func/fudraw.cxx @@ -344,17 +344,6 @@ bool FuDraw::KeyInput(const KeyEvent& rKEvt) } else { - /* If IP-Client active, we reset the pointer to the OLE- and - to the old graphic object of SdClient. With this, we - avoid the restoration of an no more existing object in - ::SelectionHasChanged after deletion. All other OLE - objects are not affected. */ - OSL_ASSERT (mpViewShell->GetViewShell()!=nullptr); - Client* pIPClient = static_cast<Client*>( - mpViewShell->GetViewShell()->GetIPClient()); - if (pIPClient && pIPClient->IsObjectInPlaceActive()) - pIPClient->SetSdrGrafObj(nullptr); - // wait-mousepointer while deleting object WaitObject aWait( static_cast<vcl::Window*>(mpViewShell->GetActiveWindow()) ); // delete object diff --git a/sd/source/ui/func/fupoor.cxx b/sd/source/ui/func/fupoor.cxx index 5589ca9f0345..b572027769d8 100644 --- a/sd/source/ui/func/fupoor.cxx +++ b/sd/source/ui/func/fupoor.cxx @@ -72,7 +72,6 @@ FuPoor::FuPoor ( mpDocSh( pDrDoc->GetDocSh() ), mpDoc(pDrDoc), nSlotId( rReq.GetSlot() ), - nSlotValue(0), pDialog(nullptr), bIsInDragMode(false), bNoScrollUntilInside (true), @@ -1028,22 +1027,8 @@ bool FuPoor::RequestHelp(const HelpEvent& rHEvt) return bReturn; } -void FuPoor::ReceiveRequest(SfxRequest& rReq) +void FuPoor::ReceiveRequest(SfxRequest& /*rReq*/) { - const SfxItemSet* pSet = rReq.GetArgs(); - - if (pSet) - { - if( pSet->GetItemState( nSlotId ) == SfxItemState::SET ) - { - const SfxPoolItem& rItem = pSet->Get( nSlotId ); - - if( dynamic_cast< const SfxAllEnumItem *>( &rItem ) != nullptr ) - { - nSlotValue = static_cast<const SfxAllEnumItem&>( rItem ).GetValue(); - } - } - } } SdrObject* FuPoor::CreateDefaultObject(const sal_uInt16, const ::tools::Rectangle& ) diff --git a/sd/source/ui/inc/Client.hxx b/sd/source/ui/inc/Client.hxx index 65a058966d79..0c9febd660b9 100644 --- a/sd/source/ui/inc/Client.hxx +++ b/sd/source/ui/inc/Client.hxx @@ -33,7 +33,6 @@ class Client : public SfxInPlaceClient { ViewShell* mpViewShell; SdrOle2Obj* pSdrOle2Obj; - SdrGrafObj* pSdrGrafObj; virtual void ObjectAreaChanged() override; virtual void RequestNewObjectArea( ::tools::Rectangle& ) override; @@ -42,7 +41,6 @@ class Client : public SfxInPlaceClient public: Client (SdrOle2Obj* pObj, ViewShell* pSdViewShell, vcl::Window* pWindow); virtual ~Client() override; - void SetSdrGrafObj(SdrGrafObj* pObj) { pSdrGrafObj = pObj; } }; } // end of namespace sd diff --git a/sd/source/ui/inc/DrawDocShell.hxx b/sd/source/ui/inc/DrawDocShell.hxx index 3dad521b119f..640b76de4d3a 100644 --- a/sd/source/ui/inc/DrawDocShell.hxx +++ b/sd/source/ui/inc/DrawDocShell.hxx @@ -225,7 +225,6 @@ protected: bool mbSdDataObj; bool mbInDestruction; bool mbOwnPrinter; - bool mbNewDocument; bool mbOwnDocument; // if true, we own mpDoc and will delete it in our d'tor void Construct(bool bClipboard); diff --git a/sd/source/ui/inc/FrameView.hxx b/sd/source/ui/inc/FrameView.hxx index 6186a363f146..6ca75dbb04e9 100644 --- a/sd/source/ui/inc/FrameView.hxx +++ b/sd/source/ui/inc/FrameView.hxx @@ -154,8 +154,6 @@ public: { mnPresViewShellId = nId; } sal_uInt16 GetPresentationViewShellId() const { return mnPresViewShellId; } - void SetSlotId(sal_uInt16 nId) { mnSlotId = nId; } - void SetSlidesPerRow(sal_uInt16 nSlides) { mnSlidesPerRow = nSlides; } sal_uInt16 GetSlidesPerRow() const { return mnSlidesPerRow; } @@ -194,7 +192,6 @@ private: bool mbDoubleClickTextEdit; ///< text mode after double click bool mbClickChangeRotation; ///< single click switches between selection/rotation mode sal_uInt16 mnPresViewShellId; ///< ViewShell from which the presentation was started - sal_uInt16 mnSlotId; ///< SlotId, which was initial mentioned sal_uInt16 mnSlidesPerRow; ///< slides per row on the slide-desk DrawModeFlags mnDrawMode; ///< draw mode for the normal window /** Remember whether the navigator shows all shapes (<TRUE/>) or only diff --git a/sd/source/ui/inc/dlg_char.hxx b/sd/source/ui/inc/dlg_char.hxx index 62e4c9d7479e..22335ed44ee9 100644 --- a/sd/source/ui/inc/dlg_char.hxx +++ b/sd/source/ui/inc/dlg_char.hxx @@ -33,7 +33,6 @@ class SdCharDlg : public SfxTabDialog private: sal_uInt16 mnCharName; sal_uInt16 mnCharEffects; - sal_uInt16 mnCharPosition; sal_uInt16 mnCharBackground; const SfxObjectShell& rDocShell; diff --git a/sd/source/ui/inc/fupoor.hxx b/sd/source/ui/inc/fupoor.hxx index d12615240aad..be0e2163bb14 100644 --- a/sd/source/ui/inc/fupoor.hxx +++ b/sd/source/ui/inc/fupoor.hxx @@ -148,7 +148,6 @@ protected: SdDrawDocument* mpDoc; sal_uInt16 nSlotId; - sal_uInt16 nSlotValue; VclPtr<Dialog> pDialog; diff --git a/sd/source/ui/slideshow/slideshow.cxx b/sd/source/ui/slideshow/slideshow.cxx index 59e583147f9a..574db3f4b826 100644 --- a/sd/source/ui/slideshow/slideshow.cxx +++ b/sd/source/ui/slideshow/slideshow.cxx @@ -701,7 +701,6 @@ void SAL_CALL SlideShow::end() pFrameView->SetPreviousViewShellType(ViewShell::ST_NONE); pFrameView->SetPresentationViewShellId(SID_VIEWSHELL0); - pFrameView->SetSlotId(SID_OBJECT_SELECT); pFrameView->SetPreviousViewShellType(pViewShell->GetShellType()); framework::FrameworkHelper::Instance(*mpCurrentViewShellBase)->RequestView( diff --git a/sd/source/ui/view/Outliner.cxx b/sd/source/ui/view/Outliner.cxx index 002c6baf16ad..0b3c8fcdeda7 100644 --- a/sd/source/ui/view/Outliner.cxx +++ b/sd/source/ui/view/Outliner.cxx @@ -173,8 +173,6 @@ SdOutliner::SdOutliner( SdDrawDocument* pDoc, OutlinerMode nMode ) maCurrentPosition(), maSearchStartPosition(), maLastValidPosition(), - mbExpectingSelectionChangeEvent(false), - mbWholeDocumentProcessed(false), mbPrepareSpellingPending(true) { SetStyleSheetPool(static_cast<SfxStyleSheetPool*>( mpDrawDocument->GetStyleSheetPool() )); @@ -271,7 +269,6 @@ void SdOutliner::PrepareSpelling() { mbStringFound = false; - mbWholeDocumentProcessed = false; // Supposed that we are not located at the very beginning/end of // the document then there may be a match in the document // prior/after the current position. @@ -1175,8 +1172,6 @@ void SdOutliner::EndOfSearch() void SdOutliner::ShowEndOfSearchDialog() { - mbWholeDocumentProcessed = true; - if (meMode == SEARCH) { if (!mbStringFound) @@ -1420,7 +1415,6 @@ void SdOutliner::EnterEditMode (bool bGrabFocus) // object that is put into edit mode would have also to be selected. // Starting the text edit mode is not enough so we do it here by // hand. - mbExpectingSelectionChangeEvent = true; mpView->UnmarkAllObj (pPV); mpView->MarkObj (mpTextObj, pPV); diff --git a/sd/source/ui/view/drviews1.cxx b/sd/source/ui/view/drviews1.cxx index ad32c960603d..056f25ca1277 100644 --- a/sd/source/ui/view/drviews1.cxx +++ b/sd/source/ui/view/drviews1.cxx @@ -739,11 +739,6 @@ bool DrawViewShell::ActivateObject(SdrOle2Obj* pObj, long nVerb) ToolBarManager::UpdateLock aLock (GetViewShellBase().GetToolBarManager()); bActivated = ViewShell::ActivateObject(pObj, nVerb); - - OSL_ASSERT(GetViewShell()!=nullptr); - Client* pClient = static_cast<Client*>(GetViewShell()->GetIPClient()); - if (pClient) - pClient->SetSdrGrafObj(nullptr); } return bActivated; diff --git a/sd/source/ui/view/frmview.cxx b/sd/source/ui/view/frmview.cxx index 490e8c1ac536..d4e7ccdea3aa 100644 --- a/sd/source/ui/view/frmview.cxx +++ b/sd/source/ui/view/frmview.cxx @@ -54,7 +54,6 @@ FrameView::FrameView(SdDrawDocument* pDrawDoc, FrameView* pFrameView /* = NULK * : SdrView(pDrawDoc, nullptr), mnRefCount(0), mnPresViewShellId(SID_VIEWSHELL0), - mnSlotId(SID_OBJECT_SELECT), mbIsNavigatorShowingAllShapes(false) { EndListening(*pDrawDoc); |