mirror of
				https://github.com/SoPat712/YTLitePlus.git
				synced 2025-10-30 12:33:57 -04:00 
			
		
		
		
	Ignore fine scrubber gesture overlap
This commit is contained in:
		| @@ -154,6 +154,10 @@ typedef NS_ENUM(NSUInteger, GestureSection) { | ||||
| @end | ||||
|  | ||||
| // Player Gestures - @bhackel | ||||
| @interface YTFineScrubberFilmstripView : UIView | ||||
| @end | ||||
| @interface YTFineScrubberFilmstripCollectionView : UICollectionView | ||||
| @end | ||||
| @interface YTPlayerViewController (YTLitePlus) <UIGestureRecognizerDelegate> | ||||
| @property (nonatomic, retain) UIPanGestureRecognizer *YTLitePlusPanGesture; | ||||
| - (BOOL)gestureRecognizer:(UIGestureRecognizer *)gestureRecognizer shouldRecognizeSimultaneouslyWithGestureRecognizer:(UIGestureRecognizer *)otherGestureRecognizer; | ||||
| @@ -174,10 +178,10 @@ typedef NS_ENUM(NSUInteger, GestureSection) { | ||||
| @end | ||||
| @interface YTInlinePlayerBarContainerView (YTLitePlus) | ||||
| @property UIPanGestureRecognizer *scrubGestureRecognizer; | ||||
| @property (nonatomic, strong, readwrite) YTFineScrubberFilmstripView *fineScrubberFilmstrip; | ||||
| - (CGFloat)scrubXForScrubRange:(CGFloat)scrubRange; | ||||
| @end | ||||
|  | ||||
|  | ||||
| // Hide Collapse Button - @arichornlover | ||||
| @interface YTMainAppControlsOverlayView (YTLitePlus) | ||||
| @property (nonatomic, assign, readwrite) YTQTMButton *watchCollapseButton; | ||||
|   | ||||
| @@ -977,6 +977,16 @@ BOOL isTabSelected = NO; | ||||
|         if (otherGestureRecognizer == playerBar.scrubGestureRecognizer) { | ||||
|             return NO; | ||||
|         } | ||||
|         // Do not allow this gesture to activate with the fine scrubber gesture | ||||
|         YTFineScrubberFilmstripView *fineScrubberFilmstrip = playerBar.fineScrubberFilmstrip; | ||||
|         if (!fineScrubberFilmstrip) { | ||||
|             return YES; | ||||
|         } | ||||
|         YTFineScrubberFilmstripCollectionView *filmstripCollectionView = [fineScrubberFilmstrip valueForKey:@"_filmstripCollectionView"]; | ||||
|         if (filmstripCollectionView && otherGestureRecognizer == filmstripCollectionView.panGestureRecognizer) { | ||||
|             return NO; | ||||
|         } | ||||
|  | ||||
|     } | ||||
|     return YES; | ||||
| } | ||||
|   | ||||
		Reference in New Issue
	
	Block a user
	 Bryce Hackel
					Bryce Hackel