/** * Moves the current video progress to the specified location. * * @param milliSeconds The time to move the playback to */ public void seekTo(int milliSeconds) { if (videoControls != null) { videoControls.showLoading(false); } videoViewImpl.seekTo(milliSeconds); }
/** * Sets the Uri location for the video to play * * @param uri The video's Uri * @param renderBuilder RenderBuilder that should be used */ public void setVideoURI(@Nullable Uri uri, @Nullable RenderBuilder renderBuilder) { videoUri = uri; videoViewImpl.setVideoUri(uri, renderBuilder); if (videoControls != null) { videoControls.showLoading(true); } }
/** * Sets the Uri location for the video to play * * @param uri The video's Uri */ public void setVideoURI(@Nullable Uri uri) { videoUri = uri; videoViewImpl.setVideoUri(uri); if (videoControls != null) { videoControls.showLoading(true); } }
/** * If the video has completed playback, calling {@code restart} will seek to the beginning of the * video, and play it. * * @return {@code true} if the video was successfully restarted, otherwise {@code false} */ public boolean restart() { if (videoUri == null) { return false; } if (videoViewImpl.restart()) { if (videoControls != null) { videoControls.showLoading(true); } return true; } else { return false; } }