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

Caolán McNamara caolanm at redhat.com
Sun Oct 18 13:23:46 PDT 2015


 sd/source/ui/slidesorter/view/SlideSorterView.cxx     |    4 ++--
 sd/source/ui/slidesorter/view/SlsFramePainter.hxx     |    2 +-
 sd/source/ui/slidesorter/view/SlsInsertAnimator.cxx   |    2 +-
 sd/source/ui/slidesorter/view/SlsLayeredDevice.hxx    |    2 +-
 sd/source/ui/slidesorter/view/SlsResource.hxx         |    2 +-
 sd/source/ui/slidesorter/view/SlsViewCacheContext.hxx |    2 +-
 sd/source/ui/tools/EventMultiplexer.cxx               |    2 +-
 sd/source/ui/unoidl/UnoDocumentSettings.cxx           |    2 +-
 sd/source/ui/unoidl/randomnode.cxx                    |    2 +-
 sd/source/ui/unoidl/unocpres.hxx                      |    2 +-
 sd/source/ui/unoidl/unolayer.hxx                      |    2 +-
 sd/source/ui/unoidl/unomodel.cxx                      |    2 +-
 sd/source/ui/unoidl/unomodule.hxx                     |    6 +++---
 sd/source/ui/unoidl/unopage.cxx                       |    2 +-
 sd/source/ui/unoidl/unopool.cxx                       |    4 ++--
 sd/source/ui/view/DocumentRenderer.cxx                |    2 +-
 sd/source/ui/view/ToolBarManager.cxx                  |    4 ++--
 sd/source/ui/view/ViewShellManager.cxx                |    6 +++---
 sd/source/ui/view/drviews1.cxx                        |    2 +-
 sw/source/core/inc/frame.hxx                          |    2 +-
 20 files changed, 27 insertions(+), 27 deletions(-)

New commits:
commit e08b49fa663ea50c4e712618bc1059249b7d35ba
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Sun Oct 18 20:56:40 2015 +0100

    cppcheck: noExplicitConstructor
    
    Change-Id: I187273e39759b3a3ef45b047f8cc36829a7f0b10

diff --git a/sd/source/ui/slidesorter/view/SlideSorterView.cxx b/sd/source/ui/slidesorter/view/SlideSorterView.cxx
index 24e5697..f6f96e0 100644
--- a/sd/source/ui/slidesorter/view/SlideSorterView.cxx
+++ b/sd/source/ui/slidesorter/view/SlideSorterView.cxx
@@ -89,7 +89,7 @@ namespace {
     class Painter : public ILayerPainter
     {
     public:
-        Painter (SlideSorterView& rView) : mrView(rView) {}
+        explicit Painter (SlideSorterView& rView) : mrView(rView) {}
         virtual ~Painter() {}
 
         virtual void Paint (OutputDevice& rDevice, const Rectangle& rRepaintArea) override
@@ -109,7 +109,7 @@ class BackgroundPainter
       public ::boost::noncopyable
 {
 public:
-    BackgroundPainter (const Color& rBackgroundColor) : maBackgroundColor(rBackgroundColor) {}
+    explicit BackgroundPainter (const Color& rBackgroundColor) : maBackgroundColor(rBackgroundColor) {}
     virtual ~BackgroundPainter() {}
 
     virtual void Paint (OutputDevice& rDevice, const Rectangle& rRepaintArea) override
diff --git a/sd/source/ui/slidesorter/view/SlsFramePainter.hxx b/sd/source/ui/slidesorter/view/SlsFramePainter.hxx
index cc3a93c..614ec0a 100644
--- a/sd/source/ui/slidesorter/view/SlsFramePainter.hxx
+++ b/sd/source/ui/slidesorter/view/SlsFramePainter.hxx
@@ -27,7 +27,7 @@ namespace sd { namespace slidesorter { namespace view {
 class FramePainter
 {
 public:
-    FramePainter (const BitmapEx& rBitmap);
+    explicit FramePainter (const BitmapEx& rBitmap);
     ~FramePainter();
 
     /** Paint a border around the given box by using a set of bitmaps for
diff --git a/sd/source/ui/slidesorter/view/SlsInsertAnimator.cxx b/sd/source/ui/slidesorter/view/SlsInsertAnimator.cxx
index 98dd95b..c5d118635 100644
--- a/sd/source/ui/slidesorter/view/SlsInsertAnimator.cxx
+++ b/sd/source/ui/slidesorter/view/SlsInsertAnimator.cxx
@@ -115,7 +115,7 @@ Point Blend (const Point& rPointA, const Point& rPointB, const double nT)
 class InsertAnimator::Implementation : public AnimatorAccess
 {
 public:
-    Implementation (SlideSorter& rSlideSorter);
+    explicit Implementation (SlideSorter& rSlideSorter);
     virtual ~Implementation();
 
     void SetInsertPosition (
diff --git a/sd/source/ui/slidesorter/view/SlsLayeredDevice.hxx b/sd/source/ui/slidesorter/view/SlsLayeredDevice.hxx
index 989dadb..0a6ac66 100644
--- a/sd/source/ui/slidesorter/view/SlsLayeredDevice.hxx
+++ b/sd/source/ui/slidesorter/view/SlsLayeredDevice.hxx
@@ -43,7 +43,7 @@ class LayeredDevice
 
 {
 public:
-    LayeredDevice (VclPtr<sd::Window> pTargetWindow);
+    explicit LayeredDevice (VclPtr<sd::Window> pTargetWindow);
     ~LayeredDevice ();
 
     void Invalidate (
diff --git a/sd/source/ui/slidesorter/view/SlsResource.hxx b/sd/source/ui/slidesorter/view/SlsResource.hxx
index 6695c00..e1d6426 100644
--- a/sd/source/ui/slidesorter/view/SlsResource.hxx
+++ b/sd/source/ui/slidesorter/view/SlsResource.hxx
@@ -29,7 +29,7 @@ namespace sd { namespace slidesorter { namespace view {
 class LocalResource : public Resource
 {
 public:
-    LocalResource (const sal_uInt16 nResourceId) : Resource(SdResId(nResourceId)){}
+    explicit LocalResource (const sal_uInt16 nResourceId) : Resource(SdResId(nResourceId)){}
     ~LocalResource() { FreeResource(); }
 };
 
diff --git a/sd/source/ui/slidesorter/view/SlsViewCacheContext.hxx b/sd/source/ui/slidesorter/view/SlsViewCacheContext.hxx
index 5b05190..fe994e5 100644
--- a/sd/source/ui/slidesorter/view/SlsViewCacheContext.hxx
+++ b/sd/source/ui/slidesorter/view/SlsViewCacheContext.hxx
@@ -39,7 +39,7 @@ namespace sd { namespace slidesorter { namespace view {
 class ViewCacheContext : public cache::CacheContext
 {
 public:
-    ViewCacheContext (SlideSorter& rSlideSorter);
+    explicit ViewCacheContext (SlideSorter& rSlideSorter);
     virtual ~ViewCacheContext();
     virtual void NotifyPreviewCreation (cache::CacheKey aKey, const Bitmap& rPreview) override;
     virtual bool IsIdle() override;
diff --git a/sd/source/ui/tools/EventMultiplexer.cxx b/sd/source/ui/tools/EventMultiplexer.cxx
index 466428d..13e8360 100644
--- a/sd/source/ui/tools/EventMultiplexer.cxx
+++ b/sd/source/ui/tools/EventMultiplexer.cxx
@@ -64,7 +64,7 @@ class EventMultiplexer::Implementation
       public SfxListener
 {
 public:
-    Implementation (ViewShellBase& rBase);
+    explicit Implementation (ViewShellBase& rBase);
     virtual ~Implementation();
 
     void AddEventListener (
diff --git a/sd/source/ui/unoidl/UnoDocumentSettings.cxx b/sd/source/ui/unoidl/UnoDocumentSettings.cxx
index 675050a..cc7680e 100644
--- a/sd/source/ui/unoidl/UnoDocumentSettings.cxx
+++ b/sd/source/ui/unoidl/UnoDocumentSettings.cxx
@@ -71,7 +71,7 @@ namespace sd
                              public DocumentSettingsSerializer
     {
     public:
-        DocumentSettings( SdXImpressDocument* pModel );
+        explicit DocumentSettings( SdXImpressDocument* pModel );
         virtual ~DocumentSettings() throw();
 
         // XInterface
diff --git a/sd/source/ui/unoidl/randomnode.cxx b/sd/source/ui/unoidl/randomnode.cxx
index 7e7b9ce7..a920518 100644
--- a/sd/source/ui/unoidl/randomnode.cxx
+++ b/sd/source/ui/unoidl/randomnode.cxx
@@ -72,7 +72,7 @@ class RandomAnimationNode : public RandomAnimationNodeBase
 {
 public:
     RandomAnimationNode( const RandomAnimationNode& rNode );
-    RandomAnimationNode( sal_Int16 nPresetClass );
+    explicit RandomAnimationNode( sal_Int16 nPresetClass );
     RandomAnimationNode();
 
     void init( sal_Int16 nPresetClass );
diff --git a/sd/source/ui/unoidl/unocpres.hxx b/sd/source/ui/unoidl/unocpres.hxx
index 569872c..67ebea3 100644
--- a/sd/source/ui/unoidl/unocpres.hxx
+++ b/sd/source/ui/unoidl/unocpres.hxx
@@ -111,7 +111,7 @@ private:
     SdCustomShow * getSdCustomShow( const OUString& Name ) const throw();
 
 public:
-    SdXCustomPresentationAccess(SdXImpressDocument& rMyModel) throw();
+    explicit SdXCustomPresentationAccess(SdXImpressDocument& rMyModel) throw();
     virtual ~SdXCustomPresentationAccess() throw();
 
     // XServiceInfo
diff --git a/sd/source/ui/unoidl/unolayer.hxx b/sd/source/ui/unoidl/unolayer.hxx
index 3a8d454..f977bad 100644
--- a/sd/source/ui/unoidl/unolayer.hxx
+++ b/sd/source/ui/unoidl/unolayer.hxx
@@ -115,7 +115,7 @@ class SdLayerManager : public ::cppu::WeakImplHelper< ::com::sun::star::drawing:
     friend class SdLayer;
 
 public:
-    SdLayerManager( SdXImpressDocument& rMyModel ) throw();
+    explicit SdLayerManager( SdXImpressDocument& rMyModel ) throw();
     virtual ~SdLayerManager() throw();
 
     // uno helper
diff --git a/sd/source/ui/unoidl/unomodel.cxx b/sd/source/ui/unoidl/unomodel.cxx
index c9a729e..434bf1a 100644
--- a/sd/source/ui/unoidl/unomodel.cxx
+++ b/sd/source/ui/unoidl/unomodel.cxx
@@ -118,7 +118,7 @@ class SdUnoForbiddenCharsTable : public SvxUnoForbiddenCharsTable,
                                  public SfxListener
 {
 public:
-    SdUnoForbiddenCharsTable( SdrModel* pModel );
+    explicit SdUnoForbiddenCharsTable(SdrModel* pModel);
     virtual ~SdUnoForbiddenCharsTable();
 
     // SfxListener
diff --git a/sd/source/ui/unoidl/unomodule.hxx b/sd/source/ui/unoidl/unomodule.hxx
index 2f9f011..63df606 100644
--- a/sd/source/ui/unoidl/unomodule.hxx
+++ b/sd/source/ui/unoidl/unomodule.hxx
@@ -53,9 +53,9 @@ class SdUnoModule : public ::cppu::WeakImplHelper< css::frame::XDispatchProvider
     css::uno::Reference < css::lang::XMultiServiceFactory > m_xFactory;
 
 public:
-                            SdUnoModule( const css::uno::Reference < css::lang::XMultiServiceFactory >& xFactory )
-                                : m_xFactory( xFactory )
-                            {}
+    explicit SdUnoModule( const css::uno::Reference < css::lang::XMultiServiceFactory >& xFactory )
+        : m_xFactory( xFactory )
+    {}
 
     // XnotifyingDispatch
     virtual void SAL_CALL dispatchWithNotification( const css::util::URL& URL, const css::uno::Sequence< css::beans::PropertyValue >& Arguments, const css::uno::Reference< css::frame::XDispatchResultListener >& Listener )
diff --git a/sd/source/ui/unoidl/unopage.cxx b/sd/source/ui/unoidl/unopage.cxx
index 8be6a58..6261bb6 100644
--- a/sd/source/ui/unoidl/unopage.cxx
+++ b/sd/source/ui/unoidl/unopage.cxx
@@ -2613,7 +2613,7 @@ void SdGenericDrawPage::setNavigationOrder( const Any& rValue )
 class SdNavigationOrderAccess : public ::cppu::WeakImplHelper< XIndexAccess >
 {
 public:
-    SdNavigationOrderAccess( SdrPage* pPage );
+    explicit SdNavigationOrderAccess(SdrPage* pPage);
 
     // XIndexAccess
     virtual sal_Int32 SAL_CALL getCount(  ) throw (RuntimeException, std::exception) override;
diff --git a/sd/source/ui/unoidl/unopool.cxx b/sd/source/ui/unoidl/unopool.cxx
index a2f57c0..6ae35e5 100644
--- a/sd/source/ui/unoidl/unopool.cxx
+++ b/sd/source/ui/unoidl/unopool.cxx
@@ -42,10 +42,10 @@ LanguageType SdUnoGetLanguage( const lang::Locale& rLocale )
     return eRet;
 }
 
-class SdUnoDrawPool :   public SvxUnoDrawPool
+class SdUnoDrawPool : public SvxUnoDrawPool
 {
 public:
-    SdUnoDrawPool( SdDrawDocument* pModel ) throw();
+    explicit SdUnoDrawPool(SdDrawDocument* pModel) throw();
     virtual ~SdUnoDrawPool() throw();
 
 protected:
diff --git a/sd/source/ui/view/DocumentRenderer.cxx b/sd/source/ui/view/DocumentRenderer.cxx
index 31b88b0..a92c3df 100644
--- a/sd/source/ui/view/DocumentRenderer.cxx
+++ b/sd/source/ui/view/DocumentRenderer.cxx
@@ -1130,7 +1130,7 @@ class DocumentRenderer::Implementation
       public vcl::PrinterOptionsHelper
 {
 public:
-    Implementation (ViewShellBase& rBase)
+    explicit Implementation (ViewShellBase& rBase)
         : mxObjectShell(rBase.GetDocShell())
         , mrBase(rBase)
         , mbIsDisposed(false)
diff --git a/sd/source/ui/view/ToolBarManager.cxx b/sd/source/ui/view/ToolBarManager.cxx
index 57ad96d..8058cff 100644
--- a/sd/source/ui/view/ToolBarManager.cxx
+++ b/sd/source/ui/view/ToolBarManager.cxx
@@ -59,7 +59,7 @@ class ToolBarRules;
 class LayouterLock
 {
 public:
-    LayouterLock (const Reference<frame::XLayoutManager>& rxLayouter);
+    explicit LayouterLock (const Reference<frame::XLayoutManager>& rxLayouter);
     ~LayouterLock();
 private:
     Reference<frame::XLayoutManager> mxLayouter;
@@ -282,7 +282,7 @@ public:
     class UpdateLockImplementation
     {
     public:
-        UpdateLockImplementation (Implementation& rImplementation)
+        explicit UpdateLockImplementation (Implementation& rImplementation)
             : mrImplementation(rImplementation) { mrImplementation.LockUpdate();  }
         ~UpdateLockImplementation() { mrImplementation.UnlockUpdate(); }
     private:
diff --git a/sd/source/ui/view/ViewShellManager.cxx b/sd/source/ui/view/ViewShellManager.cxx
index 5c015b3..6b20957 100644
--- a/sd/source/ui/view/ViewShellManager.cxx
+++ b/sd/source/ui/view/ViewShellManager.cxx
@@ -68,7 +68,7 @@ public:
 class IsShell : public ::std::unary_function<ShellDescriptor,bool>
 {
 public:
-    IsShell (const SfxShell* pShell) : mpShell(pShell) {}
+    explicit IsShell (const SfxShell* pShell) : mpShell(pShell) {}
     bool operator() (const ShellDescriptor& rDescriptor)
     { return rDescriptor.mpShell == mpShell; }
 private:
@@ -81,7 +81,7 @@ private:
 class IsId : public ::std::unary_function<ShellDescriptor,bool>
 {
 public:
-    IsId (ShellId nId) : mnId(nId) {}
+    explicit IsId (ShellId nId) : mnId(nId) {}
     bool operator() (const ShellDescriptor& rDescriptor)
     { return rDescriptor.mnId == mnId; }
 private:
@@ -128,7 +128,7 @@ public:
     class UpdateLock
     {
     public:
-        UpdateLock (Implementation& rImpl) : mrImpl(rImpl) {mrImpl.LockUpdate();}
+        explicit UpdateLock (Implementation& rImpl) : mrImpl(rImpl) {mrImpl.LockUpdate();}
         ~UpdateLock() {mrImpl.UnlockUpdate();};
     private:
         Implementation& mrImpl;
diff --git a/sd/source/ui/view/drviews1.cxx b/sd/source/ui/view/drviews1.cxx
index cf146ae..da93cdd 100644
--- a/sd/source/ui/view/drviews1.cxx
+++ b/sd/source/ui/view/drviews1.cxx
@@ -139,7 +139,7 @@ namespace
         void Lock(bool bLock);
         SfxViewFrame *mpFrame;
     public:
-        LockUI(SfxViewFrame *pFrame) : mpFrame(pFrame) { Lock(true); }
+        explicit LockUI(SfxViewFrame *pFrame) : mpFrame(pFrame) { Lock(true); }
         ~LockUI() { Lock(false); }
 
     };
diff --git a/sw/source/core/inc/frame.hxx b/sw/source/core/inc/frame.hxx
index e6c245e..5acb1f0 100644
--- a/sw/source/core/inc/frame.hxx
+++ b/sw/source/core/inc/frame.hxx
@@ -1161,7 +1161,7 @@ public:
     //Flag pFrm for SwFrmDeleteGuard lifetime that we shouldn't delete
     //it in e.g. SwSectionFrm::MergeNext etc because we will need it
     //again after the SwFrmDeleteGuard dtor
-    SwFrmDeleteGuard(SwFrm* pFrm)
+    explicit SwFrmDeleteGuard(SwFrm* pFrm)
         : m_pFrm(pFrm)
     {
         m_bOldDeleteAllowed = m_pFrm && !m_pFrm->IsDeleteForbidden();


More information about the Libreoffice-commits mailing list