summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFrank Elias <francois.elias@livio.io>2020-10-05 11:22:53 -0400
committerFrank Elias <francois.elias@livio.io>2020-10-05 11:22:53 -0400
commitb7c2b9d61653b6d918ec736b108f78ed0569fd65 (patch)
treea64cd3cf9e33aaab54fced36d0e164f3a8d9a722
parent924c510363f406ba3527458e9e13581a4890b6f7 (diff)
downloadsdl_ios-b7c2b9d61653b6d918ec736b108f78ed0569fd65.tar.gz
Added suggested changes
Added suggested changes
-rw-r--r--SmartDeviceLink/public/SDLTouchManager.m16
1 files changed, 10 insertions, 6 deletions
diff --git a/SmartDeviceLink/public/SDLTouchManager.m b/SmartDeviceLink/public/SDLTouchManager.m
index ad9eb4703..25b88d6fa 100644
--- a/SmartDeviceLink/public/SDLTouchManager.m
+++ b/SmartDeviceLink/public/SDLTouchManager.m
@@ -434,12 +434,16 @@ static NSUInteger const MaximumNumberOfTouches = 2;
[self sdl_cancelSingleTapTimer];
}
- __weak typeof(self) weakSelf = self;
- self.singleTapTimer = [[SDLTimer alloc] initWithDuration:self.tapTimeThreshold];
- self.singleTapTimer.elapsedBlock = ^{
- [weakSelf sdl_singleTapTimerCallbackWithPoint:point];
- };
- [self.singleTapTimer start];
+ if (self.tapTimeThreshold == 0.0) {
+ [self sdl_singleTapTimerCallbackWithPoint:point];
+ } else {
+ __weak typeof(self) weakSelf = self;
+ self.singleTapTimer = [[SDLTimer alloc] initWithDuration:self.tapTimeThreshold];
+ self.singleTapTimer.elapsedBlock = ^{
+ [weakSelf sdl_singleTapTimerCallbackWithPoint:point];
+ };
+ [self.singleTapTimer start];
+ }
}
/**