FullscreenHandler
@MainActor
@objc(BMPFullscreenHandler)
public protocol FullscreenHandler : NSObjectProtocol
The FullscreenHandler
implementation can be set on a PlayerView
using its fullscreenHandler
property.
The FullscreenHandler
acts as a delegate for handling the fullscreen related behaviour of the player view.
-
Is called when the UI want’s to know the current fullscreen state of the UI. Must return true if the UI is in fullscreen, otherwise false.
Declaration
Swift
@MainActor var isFullscreen: Bool { get }
-
Is called when the UI want’s to enter fullscreen. This can be the result of either calling
enterFullscreen
on aPlayerView
or tapping the fullscreen button in Bitmovin’s default UI. When a call toonFullscreenRequested
was successful,FullscreenHandler#isFullscreen
must return true after the method returned.Declaration
Swift
@MainActor func onFullscreenRequested()
-
Is called when the UI want’s to exit fullscreen. This can be the result of either calling
exitFullscreen
on aPlayerView
or tapping the fullscreen button in Bitmovin’s default UI. When a call toonFullscreenExitRequested
was successful,FullscreenHandler#isFullscreen
must return false after the method returned.Declaration
Swift
@MainActor func onFullscreenExitRequested()