[Libreoffice-commits] core.git: 2 commits - compilerplugins/clang slideshow/source
Noel Grandin (via logerrit)
logerrit at kemper.freedesktop.org
Sat Oct 19 05:58:40 UTC 2019
compilerplugins/clang/virtualdead.unusedparams.results | 9 ---------
slideshow/source/engine/animationfactory.cxx | 9 +++------
slideshow/source/engine/animationnodes/animationcolornode.cxx | 3 +--
slideshow/source/engine/eventmultiplexer.cxx | 10 ++++------
slideshow/source/engine/slide/shapemanagerimpl.cxx | 9 +++------
slideshow/source/engine/slide/shapemanagerimpl.hxx | 6 ++----
slideshow/source/engine/slideshowimpl.cxx | 10 +++-------
slideshow/source/engine/transitions/shapetransitionfactory.cxx | 6 ++----
slideshow/source/engine/transitions/slidechangebase.cxx | 9 ++++-----
slideshow/source/engine/transitions/slidechangebase.hxx | 3 +--
slideshow/source/inc/animation.hxx | 3 +--
slideshow/source/inc/eventmultiplexer.hxx | 6 ++----
slideshow/source/inc/shapelistenereventhandler.hxx | 6 ++----
13 files changed, 28 insertions(+), 61 deletions(-)
New commits:
commit 33e176552d0f4b6d343de72433963c44fa44f9ba
Author: Noel Grandin <noel.grandin at collabora.co.uk>
AuthorDate: Thu Oct 17 14:42:29 2019 +0200
Commit: Noel Grandin <noel.grandin at collabora.co.uk>
CommitDate: Sat Oct 19 07:58:04 2019 +0200
loplugin:virtualdead unused param in Animation::prefetch
Change-Id: I7eaf01548567ce560b0e32f222880d21b966c78d
Reviewed-on: https://gerrit.libreoffice.org/81071
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin at collabora.co.uk>
diff --git a/compilerplugins/clang/virtualdead.unusedparams.results b/compilerplugins/clang/virtualdead.unusedparams.results
index 9c96c1eccf30..e512aa6ecf29 100644
--- a/compilerplugins/clang/virtualdead.unusedparams.results
+++ b/compilerplugins/clang/virtualdead.unusedparams.results
@@ -292,9 +292,6 @@ slideshow/source/engine/opengl/TransitionImpl.hxx:174
slideshow/source/engine/opengl/TransitionImpl.hxx:180
void OGLTransitionImpl::finish(double,double,double,double,double,)
00000
-slideshow/source/inc/animation.hxx:61
- void slideshow::internal::Animation::prefetch(const class std::shared_ptr<class slideshow::internal::AnimatableShape> &,const class std::shared_ptr<class slideshow::internal::ShapeAttributeLayer> &,)
- 00
starmath/source/wordexportbase.hxx:37
void SmWordExportBase::HandleText(const class SmNode *,int,)
10
diff --git a/slideshow/source/engine/animationfactory.cxx b/slideshow/source/engine/animationfactory.cxx
index 4967bdc9c519..e1a02d083760 100644
--- a/slideshow/source/engine/animationfactory.cxx
+++ b/slideshow/source/engine/animationfactory.cxx
@@ -88,8 +88,7 @@ namespace slideshow
// Animation interface
- virtual void prefetch( const AnimatableShapeSharedPtr&,
- const ShapeAttributeLayerSharedPtr& ) override
+ virtual void prefetch() override
{}
virtual void start( const AnimatableShapeSharedPtr& rShape,
@@ -242,8 +241,7 @@ namespace slideshow
// Animation interface
- virtual void prefetch( const AnimatableShapeSharedPtr&,
- const ShapeAttributeLayerSharedPtr& ) override
+ virtual void prefetch() override
{}
virtual void start( const AnimatableShapeSharedPtr& rShape,
@@ -440,8 +438,7 @@ namespace slideshow
// Animation interface
- virtual void prefetch( const AnimatableShapeSharedPtr&,
- const ShapeAttributeLayerSharedPtr& )
+ virtual void prefetch()
{}
virtual void start( const AnimatableShapeSharedPtr& rShape,
diff --git a/slideshow/source/engine/animationnodes/animationcolornode.cxx b/slideshow/source/engine/animationnodes/animationcolornode.cxx
index 79850c84b7a9..4d6daeec3a05 100644
--- a/slideshow/source/engine/animationnodes/animationcolornode.cxx
+++ b/slideshow/source/engine/animationnodes/animationcolornode.cxx
@@ -49,8 +49,7 @@ public:
"HSLWrapper::HSLWrapper(): Invalid color animation delegate" );
}
- virtual void prefetch( const AnimatableShapeSharedPtr&,
- const ShapeAttributeLayerSharedPtr& ) override
+ virtual void prefetch() override
{}
virtual void start( const AnimatableShapeSharedPtr& rShape,
diff --git a/slideshow/source/engine/slideshowimpl.cxx b/slideshow/source/engine/slideshowimpl.cxx
index a3a5dbe112ca..f81e9e9fb278 100644
--- a/slideshow/source/engine/slideshowimpl.cxx
+++ b/slideshow/source/engine/slideshowimpl.cxx
@@ -852,9 +852,7 @@ ActivitySharedPtr SlideShowImpl::createSlideTransition(
// reached final size
maEventQueue.addEvent(
makeEvent( [pTransition] () {
- pTransition->prefetch(
- AnimatableShapeSharedPtr(),
- ShapeAttributeLayerSharedPtr()); },
+ pTransition->prefetch(); },
"Animation::prefetch"));
return ActivitySharedPtr(
diff --git a/slideshow/source/engine/transitions/shapetransitionfactory.cxx b/slideshow/source/engine/transitions/shapetransitionfactory.cxx
index d3054d4b9799..ffc008191193 100644
--- a/slideshow/source/engine/transitions/shapetransitionfactory.cxx
+++ b/slideshow/source/engine/transitions/shapetransitionfactory.cxx
@@ -63,8 +63,7 @@ public:
// Animation interface
- virtual void prefetch( const AnimatableShapeSharedPtr& rShape,
- const ShapeAttributeLayerSharedPtr& rAttrLayer ) override;
+ virtual void prefetch() override;
virtual void start( const AnimatableShapeSharedPtr& rShape,
const ShapeAttributeLayerSharedPtr& rAttrLayer ) override;
virtual void end() override;
@@ -116,8 +115,7 @@ ClippingAnimation::~ClippingAnimation()
}
}
-void ClippingAnimation::prefetch( const AnimatableShapeSharedPtr&,
- const ShapeAttributeLayerSharedPtr& )
+void ClippingAnimation::prefetch()
{
}
diff --git a/slideshow/source/engine/transitions/slidechangebase.cxx b/slideshow/source/engine/transitions/slidechangebase.cxx
index c75382d994ed..d97210963c6a 100644
--- a/slideshow/source/engine/transitions/slidechangebase.cxx
+++ b/slideshow/source/engine/transitions/slidechangebase.cxx
@@ -169,8 +169,7 @@ void SlideChangeBase::renderBitmap(
pSlideBitmap->draw( pDevicePixelCanvas );
}
-void SlideChangeBase::prefetch( const AnimatableShapeSharedPtr&,
- const ShapeAttributeLayerSharedPtr& )
+void SlideChangeBase::prefetch()
{
// we're a one-shot activity, and already finished
if( mbFinished || mbPrefetched )
@@ -186,14 +185,14 @@ void SlideChangeBase::prefetch( const AnimatableShapeSharedPtr&,
mbPrefetched = true;
}
-void SlideChangeBase::start( const AnimatableShapeSharedPtr& rShape,
- const ShapeAttributeLayerSharedPtr& rLayer )
+void SlideChangeBase::start( const AnimatableShapeSharedPtr& /*rShape*/,
+ const ShapeAttributeLayerSharedPtr& /*rLayer*/ )
{
// we're a one-shot activity, and already finished
if( mbFinished )
return;
- prefetch(rShape,rLayer); // no-op, if already done
+ prefetch(); // no-op, if already done
// get the subclasses a chance to do any specific initialization before run
for ( ViewsVecT::const_iterator aCurr( beginViews() ), aEnd( endViews() ); aCurr != aEnd; ++aCurr )
diff --git a/slideshow/source/engine/transitions/slidechangebase.hxx b/slideshow/source/engine/transitions/slidechangebase.hxx
index a0b8958360d9..0cb20b1a66b4 100644
--- a/slideshow/source/engine/transitions/slidechangebase.hxx
+++ b/slideshow/source/engine/transitions/slidechangebase.hxx
@@ -57,8 +57,7 @@ public:
virtual double getUnderlyingValue() const override;
// Animation
- virtual void prefetch( const AnimatableShapeSharedPtr&,
- const ShapeAttributeLayerSharedPtr& ) override;
+ virtual void prefetch() override;
virtual void start( const AnimatableShapeSharedPtr&,
const ShapeAttributeLayerSharedPtr& ) override;
virtual void end() override;
diff --git a/slideshow/source/inc/animation.hxx b/slideshow/source/inc/animation.hxx
index b44d02dc36fc..b925e2ecf4c7 100644
--- a/slideshow/source/inc/animation.hxx
+++ b/slideshow/source/inc/animation.hxx
@@ -58,8 +58,7 @@ namespace slideshow
@param rAttrLayer
Attribute layer to play the animation on.
*/
- virtual void prefetch( const AnimatableShapeSharedPtr& rShape,
- const ShapeAttributeLayerSharedPtr& rAttrLayer ) = 0;
+ virtual void prefetch( ) = 0;
/** Notify that the animation is about to begin.
commit c66e8c7f94e0937a51a81c0c1626f349d30dd424
Author: Noel Grandin <noel.grandin at collabora.co.uk>
AuthorDate: Thu Oct 17 14:39:06 2019 +0200
Commit: Noel Grandin <noel.grandin at collabora.co.uk>
CommitDate: Sat Oct 19 07:57:51 2019 +0200
loplugin:virtualdead unused params in ShapeListenerEventHandler
Change-Id: Ied95fd01912737ba1ae73fb1fea6ddd57eb8a14d
Reviewed-on: https://gerrit.libreoffice.org/81070
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin at collabora.co.uk>
diff --git a/compilerplugins/clang/virtualdead.unusedparams.results b/compilerplugins/clang/virtualdead.unusedparams.results
index a112391a9538..9c96c1eccf30 100644
--- a/compilerplugins/clang/virtualdead.unusedparams.results
+++ b/compilerplugins/clang/virtualdead.unusedparams.results
@@ -295,12 +295,6 @@ slideshow/source/engine/opengl/TransitionImpl.hxx:180
slideshow/source/inc/animation.hxx:61
void slideshow::internal::Animation::prefetch(const class std::shared_ptr<class slideshow::internal::AnimatableShape> &,const class std::shared_ptr<class slideshow::internal::ShapeAttributeLayer> &,)
00
-slideshow/source/inc/shapelistenereventhandler.hxx:51
- _Bool slideshow::internal::ShapeListenerEventHandler::listenerAdded(const class com::sun::star::uno::Reference<class com::sun::star::presentation::XShapeEventListener> &,const class com::sun::star::uno::Reference<class com::sun::star::drawing::XShape> &,)
- 01
-slideshow/source/inc/shapelistenereventhandler.hxx:54
- _Bool slideshow::internal::ShapeListenerEventHandler::listenerRemoved(const class com::sun::star::uno::Reference<class com::sun::star::presentation::XShapeEventListener> &,const class com::sun::star::uno::Reference<class com::sun::star::drawing::XShape> &,)
- 01
starmath/source/wordexportbase.hxx:37
void SmWordExportBase::HandleText(const class SmNode *,int,)
10
diff --git a/slideshow/source/engine/eventmultiplexer.cxx b/slideshow/source/engine/eventmultiplexer.cxx
index ae915bf3a2ca..b583bd42c151 100644
--- a/slideshow/source/engine/eventmultiplexer.cxx
+++ b/slideshow/source/engine/eventmultiplexer.cxx
@@ -1027,21 +1027,19 @@ void EventMultiplexer::removeHyperlinkHandler( const HyperlinkHandlerSharedPtr&
}
void EventMultiplexer::notifyShapeListenerAdded(
- const uno::Reference<presentation::XShapeEventListener>& xListener,
const uno::Reference<drawing::XShape>& xShape )
{
mpImpl->maShapeListenerHandlers.applyAll(
- [&xListener, &xShape]( const ShapeListenerEventHandlerSharedPtr& pHandler )
- { return pHandler->listenerAdded( xListener, xShape ); } );
+ [&xShape]( const ShapeListenerEventHandlerSharedPtr& pHandler )
+ { return pHandler->listenerAdded( xShape ); } );
}
void EventMultiplexer::notifyShapeListenerRemoved(
- const uno::Reference<presentation::XShapeEventListener>& xListener,
const uno::Reference<drawing::XShape>& xShape )
{
mpImpl->maShapeListenerHandlers.applyAll(
- [&xListener, &xShape]( const ShapeListenerEventHandlerSharedPtr& pHandler )
- { return pHandler->listenerRemoved( xListener, xShape ); } );
+ [&xShape]( const ShapeListenerEventHandlerSharedPtr& pHandler )
+ { return pHandler->listenerRemoved( xShape ); } );
}
void EventMultiplexer::notifyUserPaintColor( RGBColor const& rUserColor )
diff --git a/slideshow/source/engine/slide/shapemanagerimpl.cxx b/slideshow/source/engine/slide/shapemanagerimpl.cxx
index 54be9f9daf60..dbc3e0299e1d 100644
--- a/slideshow/source/engine/slide/shapemanagerimpl.cxx
+++ b/slideshow/source/engine/slide/shapemanagerimpl.cxx
@@ -76,7 +76,7 @@ void ShapeManagerImpl::activate()
// clone listener map
uno::Reference<presentation::XShapeEventListener> xDummyListener;
for( const auto& rListener : mrGlobalListenersMap )
- listenerAdded( xDummyListener, rListener.first );
+ listenerAdded( rListener.first );
// clone cursor map
for( const auto& rListener : mrGlobalCursorMap )
@@ -291,8 +291,7 @@ void ShapeManagerImpl::revokeSubset( const AttributableShapeSharedPtr& rOrigShap
}
bool ShapeManagerImpl::listenerAdded(
- const uno::Reference<presentation::XShapeEventListener>& /*xListener*/,
- const uno::Reference<drawing::XShape>& xShape )
+ const uno::Reference<drawing::XShape>& xShape )
{
ShapeEventListenerMap::const_iterator aIter;
if( (aIter = mrGlobalListenersMap.find( xShape )) ==
@@ -313,9 +312,7 @@ bool ShapeManagerImpl::listenerAdded(
return true;
}
-bool ShapeManagerImpl::listenerRemoved(
- const uno::Reference<presentation::XShapeEventListener>& /*xListener*/,
- const uno::Reference<drawing::XShape>& xShape )
+bool ShapeManagerImpl::listenerRemoved( const uno::Reference<drawing::XShape>& xShape )
{
// shape really erased from map? maybe there are other listeners
// for the same shape pending...
diff --git a/slideshow/source/engine/slide/shapemanagerimpl.hxx b/slideshow/source/engine/slide/shapemanagerimpl.hxx
index 9da754102429..16042c2e9b5e 100644
--- a/slideshow/source/engine/slide/shapemanagerimpl.hxx
+++ b/slideshow/source/engine/slide/shapemanagerimpl.hxx
@@ -146,11 +146,9 @@ private:
// ShapeListenerEventHandler
- virtual bool listenerAdded( const css::uno::Reference< css::presentation::XShapeEventListener>& xListener,
- const css::uno::Reference< css::drawing::XShape>& xShape ) override;
+ virtual bool listenerAdded( const css::uno::Reference< css::drawing::XShape>& xShape ) override;
- virtual bool listenerRemoved( const css::uno::Reference< css::presentation::XShapeEventListener>& xListener,
- const css::uno::Reference< css::drawing::XShape>& xShape ) override;
+ virtual bool listenerRemoved( const css::uno::Reference< css::drawing::XShape>& xShape ) override;
void cursorChanged( const css::uno::Reference< css::drawing::XShape>& xShape,
sal_Int16 nCursor );
diff --git a/slideshow/source/engine/slideshowimpl.cxx b/slideshow/source/engine/slideshowimpl.cxx
index 13d03bf484e4..a3a5dbe112ca 100644
--- a/slideshow/source/engine/slideshowimpl.cxx
+++ b/slideshow/source/engine/slideshowimpl.cxx
@@ -1830,8 +1830,7 @@ void SlideShowImpl::addShapeEventListener(
if( aIter->second.get() )
aIter->second->addInterface( xListener );
- maEventMultiplexer.notifyShapeListenerAdded(xListener,
- xShape);
+ maEventMultiplexer.notifyShapeListenerAdded(xShape);
}
void SlideShowImpl::removeShapeEventListener(
@@ -1857,8 +1856,7 @@ void SlideShowImpl::removeShapeEventListener(
aIter->second->removeInterface( xListener );
}
- maEventMultiplexer.notifyShapeListenerRemoved(xListener,
- xShape);
+ maEventMultiplexer.notifyShapeListenerRemoved(xShape);
}
void SlideShowImpl::setShapeCursor(
diff --git a/slideshow/source/inc/eventmultiplexer.hxx b/slideshow/source/inc/eventmultiplexer.hxx
index 4cd3eec8bc8b..7756fe965d3b 100644
--- a/slideshow/source/inc/eventmultiplexer.hxx
+++ b/slideshow/source/inc/eventmultiplexer.hxx
@@ -496,16 +496,14 @@ public:
This method announces that the given listener was added for
the specified shape.
*/
- void notifyShapeListenerAdded( const css::uno::Reference<css::presentation::XShapeEventListener>& xListener,
- const css::uno::Reference<css::drawing::XShape>& xShape );
+ void notifyShapeListenerAdded( const css::uno::Reference<css::drawing::XShape>& xShape );
/** A shape event listener was removed
This method announces that the given listener was removed for
the specified shape.
*/
- void notifyShapeListenerRemoved( const css::uno::Reference<css::presentation::XShapeEventListener>& xListener,
- const css::uno::Reference<css::drawing::XShape>& xShape );
+ void notifyShapeListenerRemoved( const css::uno::Reference<css::drawing::XShape>& xShape );
/** Notify a new user paint color
diff --git a/slideshow/source/inc/shapelistenereventhandler.hxx b/slideshow/source/inc/shapelistenereventhandler.hxx
index fbbd6ef38ae3..81bd0c1f1b87 100644
--- a/slideshow/source/inc/shapelistenereventhandler.hxx
+++ b/slideshow/source/inc/shapelistenereventhandler.hxx
@@ -48,11 +48,9 @@ namespace slideshow
public:
virtual ~ShapeListenerEventHandler() {}
- virtual bool listenerAdded( const css::uno::Reference<css::presentation::XShapeEventListener>& xListener,
- const css::uno::Reference<css::drawing::XShape>& xShape ) = 0;
+ virtual bool listenerAdded( const css::uno::Reference<css::drawing::XShape>& xShape ) = 0;
- virtual bool listenerRemoved( const css::uno::Reference<css::presentation::XShapeEventListener>& xListener,
- const css::uno::Reference<css::drawing::XShape>& xShape ) = 0;
+ virtual bool listenerRemoved( const css::uno::Reference<css::drawing::XShape>& xShape ) = 0;
};
typedef ::std::shared_ptr< ShapeListenerEventHandler > ShapeListenerEventHandlerSharedPtr;
More information about the Libreoffice-commits
mailing list