You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
feat: Use custom controls for video previews - #2073
The reason will be displayed to describe this comment to others. Learn more.
🟡 Changes recommended
Compilation is blocked by an implicit-self access in an escaping closure and a nonconforming test delegate, with additional playback and control-state defects unresolved.
This PR replaces native video preview controls with custom UIKit controls, integrating playback controls into kDrive’s preview layout and sharing visual styling with audio previews.
Changes:
Adds layer-based video rendering, custom playback and seeking controls, AirPlay, and picture-in-picture setup.
Connects control visibility to fullscreen preview state.
Shares media control styling and remaining-time formatting between audio and video.
File
Description
kDriveCore/VideoPlayer/VideoPlayer.swift
Exposes the underlying player for custom rendering.
kDriveCore/AudioPlayer/SingleTrackPlayer.swift
Extracts remaining-time formatting with duration handling.
The reason will be displayed to describe this comment to others. Learn more.
🟡 Changes recommended
Unresolved issues cause incorrect remaining-time labels at playback completion, stale playback controls after reversed swipes, and VoiceOver slider adjustments that fail to seek while paused.
didEndDisplaying clears isCurrentPage before pausing, so this guard drops the pause-state update. If the user reverses a swipe and returns to the video before its cell leaves the collection view, the controls can retain the pause icon even though startFromBeginning leaves playback paused. Update the controls for the attached player even when its cell is not the current page.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.