mirror of
				https://github.com/SoPat712/YTLitePlus.git
				synced 2025-10-30 20:34:03 -04:00 
			
		
		
		
	Ignore fine scrubber gesture overlap
This commit is contained in:
		| @@ -154,6 +154,10 @@ typedef NS_ENUM(NSUInteger, GestureSection) { | |||||||
| @end | @end | ||||||
|  |  | ||||||
| // Player Gestures - @bhackel | // Player Gestures - @bhackel | ||||||
|  | @interface YTFineScrubberFilmstripView : UIView | ||||||
|  | @end | ||||||
|  | @interface YTFineScrubberFilmstripCollectionView : UICollectionView | ||||||
|  | @end | ||||||
| @interface YTPlayerViewController (YTLitePlus) <UIGestureRecognizerDelegate> | @interface YTPlayerViewController (YTLitePlus) <UIGestureRecognizerDelegate> | ||||||
| @property (nonatomic, retain) UIPanGestureRecognizer *YTLitePlusPanGesture; | @property (nonatomic, retain) UIPanGestureRecognizer *YTLitePlusPanGesture; | ||||||
| - (BOOL)gestureRecognizer:(UIGestureRecognizer *)gestureRecognizer shouldRecognizeSimultaneouslyWithGestureRecognizer:(UIGestureRecognizer *)otherGestureRecognizer; | - (BOOL)gestureRecognizer:(UIGestureRecognizer *)gestureRecognizer shouldRecognizeSimultaneouslyWithGestureRecognizer:(UIGestureRecognizer *)otherGestureRecognizer; | ||||||
| @@ -174,10 +178,10 @@ typedef NS_ENUM(NSUInteger, GestureSection) { | |||||||
| @end | @end | ||||||
| @interface YTInlinePlayerBarContainerView (YTLitePlus) | @interface YTInlinePlayerBarContainerView (YTLitePlus) | ||||||
| @property UIPanGestureRecognizer *scrubGestureRecognizer; | @property UIPanGestureRecognizer *scrubGestureRecognizer; | ||||||
|  | @property (nonatomic, strong, readwrite) YTFineScrubberFilmstripView *fineScrubberFilmstrip; | ||||||
| - (CGFloat)scrubXForScrubRange:(CGFloat)scrubRange; | - (CGFloat)scrubXForScrubRange:(CGFloat)scrubRange; | ||||||
| @end | @end | ||||||
|  |  | ||||||
|  |  | ||||||
| // Hide Collapse Button - @arichornlover | // Hide Collapse Button - @arichornlover | ||||||
| @interface YTMainAppControlsOverlayView (YTLitePlus) | @interface YTMainAppControlsOverlayView (YTLitePlus) | ||||||
| @property (nonatomic, assign, readwrite) YTQTMButton *watchCollapseButton; | @property (nonatomic, assign, readwrite) YTQTMButton *watchCollapseButton; | ||||||
|   | |||||||
| @@ -977,6 +977,16 @@ BOOL isTabSelected = NO; | |||||||
|         if (otherGestureRecognizer == playerBar.scrubGestureRecognizer) { |         if (otherGestureRecognizer == playerBar.scrubGestureRecognizer) { | ||||||
|             return NO; |             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; |     return YES; | ||||||
| } | } | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user
	 Bryce Hackel
					Bryce Hackel