From baaa1fa9aba3e2a2cc668bf53cbd72495080b591 Mon Sep 17 00:00:00 2001 From: Charles Powell Date: Sat, 12 Dec 2015 11:52:32 -0700 Subject: [PATCH] Only allow pausing when conditions are appropriate --- MarqueeLabel.m | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/MarqueeLabel.m b/MarqueeLabel.m index de1cffc4..a248840f 100755 --- a/MarqueeLabel.m +++ b/MarqueeLabel.m @@ -981,7 +981,8 @@ - (void)shutdownLabel { -(void)pauseLabel { - if (!self.isPaused) { + // Only pause if label is not already paused, and already in a scrolling animation + if (!self.isPaused && self.awayFromHome) { // Pause sublabel position animation CFTimeInterval labelPauseTime = [self.subLabel.layer convertTime:CACurrentMediaTime() fromLayer:nil]; self.subLabel.layer.speed = 0.0;