mirror of
https://github.com/signalapp/Signal-Android.git
synced 2026-04-21 17:29:32 +01:00
Media Preview V2 Visual Redesign
This commit is contained in:
@@ -90,8 +90,7 @@ public class VideoPlayer extends FrameLayout {
|
||||
this.mediaSourceFactory = new DefaultMediaSourceFactory(context);
|
||||
|
||||
this.exoView = findViewById(R.id.video_view);
|
||||
this.exoControls = new PlayerControlView(getContext());
|
||||
this.exoControls.setShowTimeoutMs(-1);
|
||||
this.exoControls = createPlayerControls(getContext());
|
||||
|
||||
this.exoPlayerListener = new ExoPlayerListener();
|
||||
this.playerListener = new Player.Listener() {
|
||||
@@ -129,6 +128,14 @@ public class VideoPlayer extends FrameLayout {
|
||||
};
|
||||
}
|
||||
|
||||
private PlayerControlView createPlayerControls(Context context) {
|
||||
final PlayerControlView playerControlView = new PlayerControlView(context);
|
||||
playerControlView.setShowTimeoutMs(-1);
|
||||
playerControlView.setShowNextButton(false);
|
||||
playerControlView.setShowPreviousButton(false);
|
||||
return playerControlView;
|
||||
}
|
||||
|
||||
private MediaItem mediaItem;
|
||||
|
||||
public void setVideoSource(@NonNull VideoSlide videoSource, boolean autoplay, String poolTag) {
|
||||
|
||||
Reference in New Issue
Block a user