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

Noel Grandin noel.grandin at collabora.co.uk
Fri May 11 07:19:34 UTC 2018


 sd/source/ui/inc/unopage.hxx    |    2 +-
 sd/source/ui/unoidl/unopage.cxx |   18 +++++++++---------
 2 files changed, 10 insertions(+), 10 deletions(-)

New commits:
commit 1b0b0f3c64bf8e551a70c2067f4fe87fd29e81d4
Author: Noel Grandin <noel.grandin at collabora.co.uk>
Date:   Thu May 10 11:54:31 2018 +0200

    loplugin:datamembershadow in SdGenericDrawPage
    
    Change-Id: I0c7a08206b6480ba954464be1782d4577483b15e
    Reviewed-on: https://gerrit.libreoffice.org/54106
    Tested-by: Jenkins <ci at libreoffice.org>
    Reviewed-by: Noel Grandin <noel.grandin at collabora.co.uk>

diff --git a/sd/source/ui/inc/unopage.hxx b/sd/source/ui/inc/unopage.hxx
index eb49638d7ec1..6b1f2a211f13 100644
--- a/sd/source/ui/inc/unopage.hxx
+++ b/sd/source/ui/inc/unopage.hxx
@@ -59,7 +59,7 @@ class SdGenericDrawPage : public SvxFmDrawPage,
                           public css::document::XLinkTargetSupplier
 {
 private:
-    SdXImpressDocument* mpModel;
+    SdXImpressDocument* mpDocModel;
     SdrModel* mpSdrModel;
     bool      mbIsImpressDocument;
     sal_Int16 mnTempPageNumber; // for printing handouts
diff --git a/sd/source/ui/unoidl/unopage.cxx b/sd/source/ui/unoidl/unopage.cxx
index 4def39c4a18e..657a23ddc7ce 100644
--- a/sd/source/ui/unoidl/unopage.cxx
+++ b/sd/source/ui/unoidl/unopage.cxx
@@ -341,15 +341,15 @@ sal_Int64 SAL_CALL SdGenericDrawPage::getSomething( const css::uno::Sequence< sa
 SdGenericDrawPage::SdGenericDrawPage(SdXImpressDocument* _pModel, SdPage* pInPage, const SvxItemPropertySet* _pSet)
 :       SvxFmDrawPage( static_cast<SdrPage*>(pInPage) ),
         SdUnoSearchReplaceShape(this),
-        mpModel     ( _pModel ),
+        mpDocModel( _pModel ),
         mpSdrModel(nullptr),
         mbIsImpressDocument(false),
         mnTempPageNumber(0),
         mpPropSet   ( _pSet )
 {
     mpSdrModel = SvxFmDrawPage::mpModel;
-    if( mpModel )
-        mbIsImpressDocument = mpModel->IsImpressDocument();
+    if( mpDocModel )
+        mbIsImpressDocument = mpDocModel->IsImpressDocument();
 
 }
 
@@ -359,7 +359,7 @@ SdGenericDrawPage::~SdGenericDrawPage() throw()
 
 void SdGenericDrawPage::throwIfDisposed() const
 {
-    if( (SvxFmDrawPage::mpModel == nullptr) || (mpModel == nullptr) || (SvxFmDrawPage::mpPage == nullptr) )
+    if( (SvxFmDrawPage::mpModel == nullptr) || (mpDocModel == nullptr) || (SvxFmDrawPage::mpPage == nullptr) )
         throw lang::DisposedException();
 }
 
@@ -367,7 +367,7 @@ SdXImpressDocument* SdGenericDrawPage::GetModel() const
 {
     if( mpSdrModel != SvxFmDrawPage::mpModel )
         const_cast<SdGenericDrawPage*>(this)->UpdateModel();
-    return mpModel;
+    return mpDocModel;
 }
 
 bool SdGenericDrawPage::IsImpressDocument() const
@@ -384,13 +384,13 @@ void SdGenericDrawPage::UpdateModel()
     if( mpSdrModel )
     {
         uno::Reference< uno::XInterface > xModel( SvxFmDrawPage::mpModel->getUnoModel() );
-        mpModel = SdXImpressDocument::getImplementation( xModel );
+        mpDocModel = SdXImpressDocument::getImplementation( xModel );
     }
     else
     {
-        mpModel = nullptr;
+        mpDocModel = nullptr;
     }
-    mbIsImpressDocument = mpModel && mpModel->IsImpressDocument();
+    mbIsImpressDocument = mpDocModel && mpDocModel->IsImpressDocument();
 }
 
 // this is called whenever a SdrObject must be created for a empty api shape wrapper
@@ -1862,7 +1862,7 @@ void SdGenericDrawPage::release() throw()
 // XComponent
 void SdGenericDrawPage::disposing() throw()
 {
-    mpModel = nullptr;
+    mpDocModel = nullptr;
     SvxFmDrawPage::disposing();
 }
 


More information about the Libreoffice-commits mailing list