Package com.vdocipher.aegis.ui.view
Class VdoPlayerUIFragment
-
- All Implemented Interfaces:
-
android.content.ComponentCallbacks,android.view.View.OnCreateContextMenuListener,androidx.activity.result.ActivityResultCaller,androidx.lifecycle.HasDefaultViewModelProviderFactory,androidx.lifecycle.LifecycleOwner,androidx.lifecycle.ViewModelStoreOwner,androidx.savedstate.SavedStateRegistryOwner
public class VdoPlayerUIFragment extends Fragment
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description public interfaceVdoPlayerUIFragment.OnSaveOfflineListenerV2public interfaceVdoPlayerUIFragment.OnSaveOfflineListener
-
Constructor Summary
Constructors Constructor Description VdoPlayerUIFragment()
-
Method Summary
Modifier and Type Method Description voidonCreate(@Nullable() Bundle savedInstanceState)voidonInflate(@NonNull() Context context, @NonNull() AttributeSet attrs, @Nullable() Bundle savedInstanceState)ViewonCreateView(@NonNull() LayoutInflater inflater, @Nullable() ViewGroup container, Bundle savedInstanceState)voidonViewCreated(@NonNull() View view, @Nullable() Bundle savedInstanceState)voidonViewStateRestored(@Nullable() Bundle savedInstanceState)voidonStart()voidonStop()voidonSaveInstanceState(@NonNull() Bundle outState)voidonConfigurationChanged(Configuration newConfig)voidonBackPressed()voidinitialize(PlayerHost.InitializationListener initializationListener)voidsetAspectRatio(float widthToHeightRatio)Set aspect ratio for the fragment view. intgetVideoStretchMode()Return currently set video stretch mode. voidsetVideoStretchMode(int videoStretchMode)Set stretch mode for video scaling inside the fragment layout. intgetResizeMode()Returns the resize mode. voidsetResizeMode(int resizeMode)Sets the resize mode. voidonResume()voidonPause()voidaddOnSavedOfflineListener(VdoPlayerUIFragment.OnSaveOfflineListener onSaveOfflineListener)voidaddOnSavedOfflineListenerV2(VdoPlayerUIFragment.OnSaveOfflineListenerV2 onSaveOfflineListenerV2)Set callback to listen save offline event and provide persistent Token to download video. voidonPictureInPictureModeChanged(boolean isInPictureInPictureMode)voidsetPictureInPictureSupport(boolean supportsPictureInPicture)Set support for picture in picture mode. voidenterFullScreen()Set support for fullscreen mode of the player. voidexitFullScreen()Set support to exit form fullscreen mode of the player. voidsetBackPressCalled()Set support to handle back press. voidsetFullscreenActionListener(FullScreenActionListener fullScreenActionListener)voidonDestroyView()voidonDestroy()-
-
Method Detail
-
onInflate
void onInflate(@NonNull() Context context, @NonNull() AttributeSet attrs, @Nullable() Bundle savedInstanceState)
-
onCreateView
@Nullable() View onCreateView(@NonNull() LayoutInflater inflater, @Nullable() ViewGroup container, Bundle savedInstanceState)
-
onViewCreated
void onViewCreated(@NonNull() View view, @Nullable() Bundle savedInstanceState)
-
onViewStateRestored
void onViewStateRestored(@Nullable() Bundle savedInstanceState)
-
onStart
void onStart()
-
onStop
void onStop()
-
onSaveInstanceState
void onSaveInstanceState(@NonNull() Bundle outState)
-
onConfigurationChanged
void onConfigurationChanged(Configuration newConfig)
-
onBackPressed
@Deprecated() void onBackPressed()
-
initialize
void initialize(PlayerHost.InitializationListener initializationListener)
-
setAspectRatio
void setAspectRatio(float widthToHeightRatio)
Set aspect ratio for the fragment view.
The dimension (width or height) that is fixed in layout will be kept and the other dimension will be increased or decreased to match the aspect ratio.
- Parameters:
widthToHeightRatio- the desired aspect ratio
-
getVideoStretchMode
@Deprecated() int getVideoStretchMode()
Return currently set video stretch mode.
-
setVideoStretchMode
@Deprecated() void setVideoStretchMode(int videoStretchMode)
Set stretch mode for video scaling inside the fragment layout.
- Parameters:
videoStretchMode- one of PlayerHost.
-
getResizeMode
int getResizeMode()
Returns the resize mode.
-
setResizeMode
void setResizeMode(int resizeMode)
Sets the resize mode.
- Parameters:
resizeMode- The resize mode.
-
onResume
void onResume()
-
onPause
void onPause()
-
addOnSavedOfflineListener
void addOnSavedOfflineListener(VdoPlayerUIFragment.OnSaveOfflineListener onSaveOfflineListener)
-
addOnSavedOfflineListenerV2
void addOnSavedOfflineListenerV2(VdoPlayerUIFragment.OnSaveOfflineListenerV2 onSaveOfflineListenerV2)
Set callback to listen save offline event and provide persistent Token to download video.
- Parameters:
onSaveOfflineListenerV2- OnSaveOfflineListenerV2
-
onPictureInPictureModeChanged
void onPictureInPictureModeChanged(boolean isInPictureInPictureMode)
-
setPictureInPictureSupport
@Deprecated() void setPictureInPictureSupport(boolean supportsPictureInPicture)
Set support for picture in picture mode.
-
enterFullScreen
void enterFullScreen()
Set support for fullscreen mode of the player.
-
exitFullScreen
void exitFullScreen()
Set support to exit form fullscreen mode of the player.
-
setBackPressCalled
void setBackPressCalled()
Set support to handle back press.
-
setFullscreenActionListener
void setFullscreenActionListener(FullScreenActionListener fullScreenActionListener)
-
onDestroyView
void onDestroyView()
-
onDestroy
void onDestroy()
-
-
-
-