mirror of
https://github.com/arichornlover/uYouEnhanced.git
synced 2026-03-11 21:26:04 +00:00
Merge pull request #597 from bhackel/feat/always-use-remaining-time
Add always show remaining time
This commit is contained in:
commit
2b207e4207
3 changed files with 19 additions and 0 deletions
|
|
@ -53,6 +53,11 @@
|
|||
#define DEFAULT_RATE 1.0f // YTSpeed
|
||||
#define LOWCONTRASTMODE_CUTOFF_VERSION @"17.38.10" // LowContrastMode (v17.33.2-17.38.10)
|
||||
|
||||
// Always show remaining time in video player - @bhackel
|
||||
@interface YTInlinePlayerBarContainerView (uYouEnhanced)
|
||||
@property(nonatomic, assign) BOOL shouldDisplayTimeRemaining;
|
||||
@end
|
||||
|
||||
// IAmYouTube
|
||||
@interface SSOConfiguration : NSObject
|
||||
@end
|
||||
|
|
|
|||
|
|
@ -944,6 +944,19 @@ BOOL isAd(YTIElementRenderer *self) {
|
|||
}
|
||||
%end
|
||||
|
||||
// Always use remaining time in the video player - @bhackel
|
||||
%hook YTInlinePlayerBarContainerView
|
||||
// Modify constructor to enable the feature when it is done
|
||||
- (instancetype)init {
|
||||
YTInlinePlayerBarContainerView *playerBar = (YTInlinePlayerBarContainerView *)%orig;
|
||||
if (playerBar && IS_ENABLED(@"alwaysShowRemainingTime_enabled")) {
|
||||
playerBar.shouldDisplayTimeRemaining = YES;
|
||||
}
|
||||
return playerBar;
|
||||
}
|
||||
%end
|
||||
|
||||
// Hide previous and next buttons in all videos - @bhackel
|
||||
%group gHidePreviousAndNextButton
|
||||
%hook YTColdConfig
|
||||
- (BOOL)removeNextPaddleForAllVideos {
|
||||
|
|
|
|||
|
|
@ -260,6 +260,7 @@ extern NSBundle *uYouPlusBundle();
|
|||
SWITCH_ITEM2(LOC(@"STOCK_VOLUME_HUD"), LOC(@"STOCK_VOLUME_HUD_DESC"), @"stockVolumeHUD_enabled");
|
||||
SWITCH_ITEM2(LOC(@"Disable pull-to-fullscreen gesture"), LOC(@"Disable the drag gesture to enter vertical fullscreen. Only applies to landscape videos."), @"disablePullToFull_enabled");
|
||||
SWITCH_ITEM(LOC(@"Disable Double tap to skip chapter"), LOC(@"Disable the 2-finger double tap gesture that skips forward/backward by a chapter"), @"disableChapterSkip_enabled");
|
||||
SWITCH_ITEM2(LOC(@"Always use remaining time"), LOC(@"Change the default to show time remaining in the player bar"), @"alwaysShowRemainingTime_enabled");
|
||||
|
||||
# pragma mark - Video controls overlay options
|
||||
SECTION_HEADER(LOC(@"VIDEO_PLAYER_OPTIONS"));
|
||||
|
|
|
|||
Loading…
Reference in a new issue