Skip to content

Commit

Permalink
fix(tvOS): fix tvos compile error for rotation handler
Browse files Browse the repository at this point in the history
  • Loading branch information
Duell10111 committed Feb 16, 2025
1 parent 451bafe commit 01367ac
Showing 1 changed file with 8 additions and 6 deletions.
14 changes: 8 additions & 6 deletions ios/Video/RCTVideo.swift
Original file line number Diff line number Diff line change
Expand Up @@ -257,12 +257,14 @@ class RCTVideo: UIView, RCTVideoPlayerViewControllerDelegate, RCTPlayerObserverH
object: nil
)

NotificationCenter.default.addObserver(
self,
selector: #selector(handleRotation),
name: UIDevice.orientationDidChangeNotification,
object: nil
)
#if os(iOS)
NotificationCenter.default.addObserver(
self,
selector: #selector(handleRotation),
name: UIDevice.orientationDidChangeNotification,
object: nil
)
#endif

_playerObserver._handlers = self
#if USE_VIDEO_CACHING
Expand Down

0 comments on commit 01367ac

Please sign in to comment.