summaryrefslogtreecommitdiff
path: root/slideshow
diff options
context:
space:
mode:
authorNoel Grandin <noel@peralex.com>2016-03-22 12:26:38 +0200
committerNoel Grandin <noel@peralex.com>2016-03-23 09:13:13 +0200
commit4b37994a02a3fd371dc039ebd932c7d65c144871 (patch)
treecf3855b2ae5b3a9a324c998ffe8d4b7add78dcf9 /slideshow
parentb4e3f5e9a733694ea0b810984c54ef9aca5e432a (diff)
loplugin:constantparam in slideshow
Change-Id: I36215c1e5c698b1dd2a984163639b024739b3113
Diffstat (limited to 'slideshow')
-rw-r--r--slideshow/source/engine/screenupdater.cxx9
-rw-r--r--slideshow/source/engine/slide/layermanager.cxx24
-rw-r--r--slideshow/source/engine/slide/layermanager.hxx9
-rw-r--r--slideshow/source/engine/slide/shapemanagerimpl.cxx2
4 files changed, 11 insertions, 33 deletions
diff --git a/slideshow/source/engine/screenupdater.cxx b/slideshow/source/engine/screenupdater.cxx
index 781277fe5a36..c4fb585c9d2e 100644
--- a/slideshow/source/engine/screenupdater.cxx
+++ b/slideshow/source/engine/screenupdater.cxx
@@ -31,7 +31,7 @@ namespace {
class UpdateLock : public ::slideshow::internal::ScreenUpdater::UpdateLock
{
public:
- UpdateLock (::slideshow::internal::ScreenUpdater& rUpdater, const bool bStartLocked);
+ UpdateLock (::slideshow::internal::ScreenUpdater& rUpdater);
virtual ~UpdateLock();
virtual void Activate() override;
private:
@@ -214,7 +214,7 @@ namespace internal
::std::shared_ptr<ScreenUpdater::UpdateLock> ScreenUpdater::createLock()
{
- return ::std::shared_ptr<ScreenUpdater::UpdateLock>(new ::UpdateLock(*this, false/*bStartLocked*/));
+ return ::std::shared_ptr<ScreenUpdater::UpdateLock>(new ::UpdateLock(*this));
}
@@ -224,13 +224,10 @@ namespace internal
namespace {
UpdateLock::UpdateLock (
- ::slideshow::internal::ScreenUpdater& rUpdater,
- const bool bStartLocked)
+ ::slideshow::internal::ScreenUpdater& rUpdater)
: mrUpdater(rUpdater),
mbIsActivated(false)
{
- if (bStartLocked)
- Activate();
}
diff --git a/slideshow/source/engine/slide/layermanager.cxx b/slideshow/source/engine/slide/layermanager.cxx
index 861e8f5a4d63..34603d8a9528 100644
--- a/slideshow/source/engine/slide/layermanager.cxx
+++ b/slideshow/source/engine/slide/layermanager.cxx
@@ -93,30 +93,18 @@ namespace slideshow
this->viewAdded( rView );
}
- void LayerManager::activate( bool bSlideBackgoundPainted )
+ void LayerManager::activate()
{
mbActive = true;
maUpdateShapes.clear(); // update gets forced via area, or
// has happened outside already
- if( !bSlideBackgoundPainted )
- {
- for( const auto& pView : mrViews )
- pView->clearAll();
-
- // force update of whole slide area
- for( const auto& pLayer : maLayers )
- pLayer->addUpdateRange( maPageBounds );
- }
- else
- {
- // clear all possibly pending update areas - content
- // is there, already
- for( const auto& pLayer : maLayers )
- pLayer->clearUpdateRanges();
- }
+ // clear all possibly pending update areas - content
+ // is there, already
+ for( const auto& pLayer : maLayers )
+ pLayer->clearUpdateRanges();
- updateShapeLayers( bSlideBackgoundPainted );
+ updateShapeLayers( true/*bSlideBackgoundPainted*/ );
}
void LayerManager::deactivate()
diff --git a/slideshow/source/engine/slide/layermanager.hxx b/slideshow/source/engine/slide/layermanager.hxx
index 13fc4ac20f52..f15c5fe835a6 100644
--- a/slideshow/source/engine/slide/layermanager.hxx
+++ b/slideshow/source/engine/slide/layermanager.hxx
@@ -84,15 +84,8 @@ namespace slideshow
This method activates the LayerManager. Prior to
activation, this instance will be passive, i.e. won't
render anything to any view.
-
- @param bSlideBackgoundPainted
- When true, the initial slide content on the background
- layer is already rendered (e.g. from a previous slide
- transition). When false, LayerManager also renders
- initial content of background layer on next update()
- call.
*/
- void activate( bool bSlideBackgoundPainted );
+ void activate();
/** Deactivate the LayerManager
diff --git a/slideshow/source/engine/slide/shapemanagerimpl.cxx b/slideshow/source/engine/slide/shapemanagerimpl.cxx
index 6b655769e90d..ceb0db898511 100644
--- a/slideshow/source/engine/slide/shapemanagerimpl.cxx
+++ b/slideshow/source/engine/slide/shapemanagerimpl.cxx
@@ -72,7 +72,7 @@ void ShapeManagerImpl::activate()
this->cursorChanged( rListener.first, rListener.second );
if( mpLayerManager )
- mpLayerManager->activate( true/*bSlideBackgoundPainted*/ );
+ mpLayerManager->activate();
}
}