Skip to content

Commit

Permalink
When scrolling is disabled, reject the pan gesture recognizer entirel…
Browse files Browse the repository at this point in the history
…y (so that the carousel doesn't take control when other pan gesture recognizers are involved)
  • Loading branch information
alleus committed Mar 8, 2012
1 parent 01c0351 commit 4a4b515
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion iCarousel/iCarousel.m
Expand Up @@ -1841,7 +1841,8 @@ - (BOOL)gestureRecognizer:(UIGestureRecognizer *)gesture shouldReceiveTouch:(UIT
else if ([gesture isKindOfClass:[UIPanGestureRecognizer class]])
{
if ([self viewOrSuperview:touch.view isKindOfClass:[UISlider class]] ||
[self viewOrSuperview:touch.view isKindOfClass:[UISwitch class]])
[self viewOrSuperview:touch.view isKindOfClass:[UISwitch class]] ||
!scrollEnabled)
{
return NO;
}
Expand Down

0 comments on commit 4a4b515

Please sign in to comment.