Package com.jwplayer.pub.api.fullscreen
Class ExtensibleFullscreenHandler
java.lang.Object
com.jwplayer.pub.api.fullscreen.ExtensibleFullscreenHandler
- All Implemented Interfaces:
FullscreenHandler
-
Constructor Summary
ConstructorsConstructorDescriptionExtensibleFullscreenHandler(LayoutDelegate layoutDelegate, DeviceOrientationDelegate deviceOrientationDelegate, SystemUiDelegate systemUiDelegate) -
Method Summary
Modifier and TypeMethodDescriptionvoidonAllowFullscreenPortraitChanged(boolean allowFullscreenPortrait) Called when the `allowFullscreenPortrait` property is changed on the player, and then passed down to the FullscreenHandler.voidonAllowRotationChanged(boolean allowRotation) Called when the "allow rotation" property of the fullscreen handler is being updated.voidCalled when the JWPlayerView wants to exit fullscreen.voidCalled when the JWPlayerView wants to enter fullscreen.voidsetUseFullscreenLayoutFlags(boolean useFullscreenLayoutFlags) Determines whether View.SYSTEM_UI_FLAG_LAYOUT_FULLSCREEN and View.SYSTEM_UI_FLAG_LAYOUT_HIDE_NAVIGATION flags are used during fullscreen.voidupdateLayoutParams(ViewGroup.LayoutParams layoutParams) Called by the JWPlayerView when it's LayoutParameters have been updated.
-
Constructor Details
-
ExtensibleFullscreenHandler
public ExtensibleFullscreenHandler(LayoutDelegate layoutDelegate, DeviceOrientationDelegate deviceOrientationDelegate, SystemUiDelegate systemUiDelegate)
-
-
Method Details
-
onFullscreenRequested
public void onFullscreenRequested()Called when the JWPlayerView wants to enter fullscreen.- Specified by:
onFullscreenRequestedin interfaceFullscreenHandler
-
onFullscreenExitRequested
public void onFullscreenExitRequested()Called when the JWPlayerView wants to exit fullscreen.- Specified by:
onFullscreenExitRequestedin interfaceFullscreenHandler
-
onAllowRotationChanged
public void onAllowRotationChanged(boolean allowRotation) Called when the "allow rotation" property of the fullscreen handler is being updated. Use this to enable or disable your rotation listener.- Specified by:
onAllowRotationChangedin interfaceFullscreenHandler- Parameters:
allowRotation- whether the fullscreen handler should listen for rotation changes, true if it should listen for changes.
-
onAllowFullscreenPortraitChanged
public void onAllowFullscreenPortraitChanged(boolean allowFullscreenPortrait) Description copied from interface:FullscreenHandlerCalled when the `allowFullscreenPortrait` property is changed on the player, and then passed down to the FullscreenHandler.Use this to update the handler to be respective of fullscreen portrait triggered by player
- Specified by:
onAllowFullscreenPortraitChangedin interfaceFullscreenHandler- Parameters:
allowFullscreenPortrait- the state of allowing fullscreen portrait
-
updateLayoutParams
public void updateLayoutParams(ViewGroup.LayoutParams layoutParams) Called by the JWPlayerView when it's LayoutParameters have been updated. Use these layout parameters when returning from fullscreen.- Specified by:
updateLayoutParamsin interfaceFullscreenHandler- Parameters:
layoutParams- the new Layout Parameters for the JWPlayerView.
-
setUseFullscreenLayoutFlags
public void setUseFullscreenLayoutFlags(boolean useFullscreenLayoutFlags) Determines whether View.SYSTEM_UI_FLAG_LAYOUT_FULLSCREEN and View.SYSTEM_UI_FLAG_LAYOUT_HIDE_NAVIGATION flags are used during fullscreen.These flags create an issue on Android 4.1, 4.2, and 4.3 devices when using the SupportActionBar, set this to false to disable using these flags.
- Specified by:
setUseFullscreenLayoutFlagsin interfaceFullscreenHandler- Parameters:
useFullscreenLayoutFlags- true if the FullscreenHandler should use the SYSTEM_UI_FLAG_FULLSCREEN and SYSTEM_UI_FLAG_HIDE_NAVIGATION flag.
-