PictureInPictureDelegate.Event


public final class PictureInPictureDelegate.Event


Represents the PiP event emitted from the system.

Summary

Public fields

static final @NonNull PictureInPictureDelegate.Event

App has fully settled in PiP mode, app usually needs to switch its Activity layout to PiP mode.

static final @NonNull PictureInPictureDelegate.Event

Entering PiP animation ends, apps usually do not need to take actions for this state.

static final @NonNull PictureInPictureDelegate.Event

Entering PiP animation starts, this offers an app the chance to hide UI elements such as the overlays upon the video player.

static final @NonNull PictureInPictureDelegate.Event

App has exited PiP mode, app usually needs to switch its Activity layout to full-screen mode.

static final @NonNull PictureInPictureDelegate.Event

PiP window is stashed.

static final @NonNull PictureInPictureDelegate.Event

PiP window is un-stashed.

Public methods

@NonNull String

Public fields

ENTERED

public static final @NonNull PictureInPictureDelegate.Event ENTERED

App has fully settled in PiP mode, app usually needs to switch its Activity layout to PiP mode. Compatibility notes: this event is available since API 24, see also PictureInPictureModeChangedInfo.isInPictureInPictureMode.

ENTER_ANIMATION_END

public static final @NonNull PictureInPictureDelegate.Event ENTER_ANIMATION_END

Entering PiP animation ends, apps usually do not need to take actions for this state. Compatibility notes: this event is available since API 35, see also PictureInPictureUiStateCompat.isTransitioningToPip

ENTER_ANIMATION_START

public static final @NonNull PictureInPictureDelegate.Event ENTER_ANIMATION_START

Entering PiP animation starts, this offers an app the chance to hide UI elements such as the overlays upon the video player. Compatibility notes: this event is available since API 35, see also PictureInPictureUiStateCompat.isTransitioningToPip.

EXITED

public static final @NonNull PictureInPictureDelegate.Event EXITED

App has exited PiP mode, app usually needs to switch its Activity layout to full-screen mode. Compatibility notes: this event is available since API 24, see also PictureInPictureModeChangedInfo.isInPictureInPictureMode.

STASHED

public static final @NonNull PictureInPictureDelegate.Event STASHED

PiP window is stashed. A stashed PiP means it is only partially visible to the user, with some parts of it being off-screen. Compatibility notes: this event is available since API 31, see also PictureInPictureUiStateCompat.isStashed.

UNSTASHED

public static final @NonNull PictureInPictureDelegate.Event UNSTASHED

PiP window is un-stashed. A stashed PiP means it is only partially visible to the user, with some parts of it being off-screen. Compatibility notes: this event is available since API 31, see also PictureInPictureUiStateCompat.isStashed.

Public methods

toString

public @NonNull String toString()