Various improvements

This commit is contained in:
Ilya Laktyushin
2024-07-26 20:59:48 +02:00
parent 8e219193d0
commit 40d40dd8e7
24 changed files with 1117 additions and 970 deletions

View File

@@ -678,9 +678,9 @@ public final class TelegramRootController: NavigationController, TelegramRootCon
var coverTime: Double?
if let coverImageTimestamp = values.coverImageTimestamp {
if let trimRange = values.videoTrimRange {
coverTime = coverImageTimestamp - trimRange.lowerBound
coverTime = min(duration, coverImageTimestamp - trimRange.lowerBound)
} else {
coverTime = coverImageTimestamp
coverTime = min(duration, coverImageTimestamp)
}
}