[Libreoffice-commits] core.git: sfx2/source

Noel Grandin (via logerrit) logerrit at kemper.freedesktop.org
Mon Apr 6 19:42:21 UTC 2020


 sfx2/source/dialog/splitwin.cxx            |    2 +-
 sfx2/source/doc/DocumentMetadataAccess.cxx |    4 ----
 sfx2/source/notebookbar/SfxNotebookBar.cxx |    7 -------
 3 files changed, 1 insertion(+), 12 deletions(-)

New commits:
commit 1c64ecadaa7f391cf89d6f57aa798ef614b765a2
Author:     Noel Grandin <noel.grandin at collabora.co.uk>
AuthorDate: Mon Apr 6 20:54:57 2020 +0200
Commit:     Noel Grandin <noel.grandin at collabora.co.uk>
CommitDate: Mon Apr 6 21:41:43 2020 +0200

    loplugin:unusedvariableplus in sfx2
    
    Change-Id: I69471cdb274f6a9164d3b4ced4643511cce43d19
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/91778
    Tested-by: Jenkins
    Reviewed-by: Noel Grandin <noel.grandin at collabora.co.uk>

diff --git a/sfx2/source/dialog/splitwin.cxx b/sfx2/source/dialog/splitwin.cxx
index 77d175c86215..cd4be8687acb 100644
--- a/sfx2/source/dialog/splitwin.cxx
+++ b/sfx2/source/dialog/splitwin.cxx
@@ -804,7 +804,7 @@ void SfxSplitWindow::RemoveWindow( SfxDockingWindow const * pDockWin, bool bHide
 
     // Remove Windows, and if it was the last of the line, then also remove
     // the line (line = itemset)
-    std::unique_ptr<DeactivateUpdateMode> pDeactivateUpdateMode( new DeactivateUpdateMode( *this ) );
+    DeactivateUpdateMode aDeactivateUpdateMode( *this );
 
     RemoveItem( pDockWin->GetType() );
 
diff --git a/sfx2/source/doc/DocumentMetadataAccess.cxx b/sfx2/source/doc/DocumentMetadataAccess.cxx
index b1dc7f64d110..9d9ece4c82cc 100644
--- a/sfx2/source/doc/DocumentMetadataAccess.cxx
+++ b/sfx2/source/doc/DocumentMetadataAccess.cxx
@@ -773,10 +773,6 @@ retry:
         i_rImpl.m_xRepository->getGraph(xManifest));
     i_rImpl.m_xManifest.set(xManifestGraph.is() ? xManifestGraph :
         i_rImpl.m_xRepository->createGraph(xManifest), uno::UNO_SET_THROW);
-    const uno::Reference<container::XEnumeration> xEnum(
-        i_rImpl.m_xManifest->getStatements(nullptr,
-            getURI<rdf::URIs::RDF_TYPE>(i_rImpl.m_xContext),
-            getURI<rdf::URIs::PKG_DOCUMENT>(i_rImpl.m_xContext).get()));
 
     // document statement
     i_rImpl.m_xManifest->addStatement(i_rImpl.m_xBaseURI.get(),
diff --git a/sfx2/source/notebookbar/SfxNotebookBar.cxx b/sfx2/source/notebookbar/SfxNotebookBar.cxx
index a784ffb5e100..674caf4b0bb0 100644
--- a/sfx2/source/notebookbar/SfxNotebookBar.cxx
+++ b/sfx2/source/notebookbar/SfxNotebookBar.cxx
@@ -415,10 +415,6 @@ bool SfxNotebookBar::StateMethod(SystemWindow* pSysWindow,
 
 void SfxNotebookBar::RemoveListeners(SystemWindow const * pSysWindow)
 {
-    Reference<XContextChangeEventMultiplexer> xMultiplexer
-                        = ContextChangeEventMultiplexer::get(
-                                ::comphelper::getProcessComponentContext());
-
     if (auto pNotebookBar = pSysWindow->GetNotebookBar())
     {
         pNotebookBar->StopListeningAllControllers();
@@ -486,9 +482,6 @@ void SfxNotebookBar::ShowMenubar(SfxViewFrame const * pViewFrame, bool bShow)
 
     m_bLock = true;
 
-    uno::Reference<uno::XComponentContext> xContext = comphelper::getProcessComponentContext();
-    const Reference<frame::XModuleManager> xModuleManager = frame::ModuleManager::create(xContext);
-
     Reference<frame::XFrame> xFrame = pViewFrame->GetFrame().GetFrameInterface();
     if (xFrame.is())
     {


More information about the Libreoffice-commits mailing list