mirror of
https://github.com/yattee/yattee.git
synced 2025-08-08 11:44:06 +00:00
chore: address linter warnings
Signed-off-by: Toni Förster <toni.foerster@gmail.com>
This commit is contained in:
@@ -61,7 +61,8 @@ final class AppleAVPlayerViewController: UIViewController {
|
||||
_ sections: [NowPlayingView.ViewSection],
|
||||
title: String
|
||||
) -> UIHostingController<AnyView> {
|
||||
let controller = UIHostingController(rootView:
|
||||
let controller = UIHostingController(
|
||||
rootView:
|
||||
AnyView(
|
||||
NowPlayingView(sections: sections, inInfoViewController: true)
|
||||
.frame(maxHeight: 600)
|
||||
|
@@ -33,7 +33,7 @@ struct TimelineView: View {
|
||||
@State private var dragOffset: Double = 0
|
||||
@State private var draggedFrom: Double = 0
|
||||
|
||||
private var start: Double = 0.0
|
||||
private var start = 0.0
|
||||
private var height = 8.0
|
||||
|
||||
var cornerRadius: Double
|
||||
|
@@ -90,8 +90,9 @@ final class PlayerViewController: UIViewController {
|
||||
_ sections: [NowPlayingView.ViewSection],
|
||||
title: String
|
||||
) -> UIHostingController<AnyView> {
|
||||
let controller = UIHostingController(rootView:
|
||||
AnyView(
|
||||
let controller = UIHostingController(
|
||||
rootView:
|
||||
AnyV‚iew(
|
||||
NowPlayingView(sections: sections, inInfoViewController: true)
|
||||
.frame(maxHeight: 600)
|
||||
.environmentObject(commentsModel)
|
||||
|
@@ -208,6 +208,7 @@ struct VideoDetails: View {
|
||||
.frame(maxWidth: .infinity, alignment: .leading)
|
||||
.contentShape(Rectangle())
|
||||
.padding(.horizontal, 16)
|
||||
// swiftlint:disable trailing_closure
|
||||
#if !os(tvOS)
|
||||
.tapRecognizer(
|
||||
tapSensitivity: 0.2,
|
||||
@@ -218,6 +219,7 @@ struct VideoDetails: View {
|
||||
}
|
||||
)
|
||||
#endif
|
||||
// swiftlint:enable trailing_closure
|
||||
|
||||
VideoActions(video: player.videoForDisplay)
|
||||
.padding(.vertical, 5)
|
||||
|
@@ -281,7 +281,7 @@ struct VideoPlayerView: View {
|
||||
}
|
||||
.gesture(player.controls.presentingOverlays ? nil : playerDragGesture)
|
||||
#if os(macOS)
|
||||
.onAppear(perform: {
|
||||
.onAppear {
|
||||
NSEvent.addLocalMonitorForEvents(matching: [.mouseMoved]) {
|
||||
hoverThrottle.execute {
|
||||
if !player.currentItem.isNil, hoveringPlayer {
|
||||
@@ -291,7 +291,7 @@ struct VideoPlayerView: View {
|
||||
|
||||
return $0
|
||||
}
|
||||
})
|
||||
}
|
||||
#endif
|
||||
|
||||
.background(Color.black)
|
||||
|
Reference in New Issue
Block a user