Minor macOS performance improvement

This commit is contained in:
Arkadiusz Fal 2022-06-29 23:51:03 +02:00
parent b7c3eb0248
commit 125b8cc89a

View File

@ -226,7 +226,7 @@ struct VideoPlayerView: View {
#else
.onAppear(perform: {
NSEvent.addLocalMonitorForEvents(matching: [.mouseMoved]) {
if hoveringPlayer {
if !player.currentItem.isNil, hoveringPlayer {
playerControls.resetTimer()
}