a7c1345085
* Resolving some issues with media playback. * Changing ViewVideoFragment so that it fully handles autohiding the media controller, allowing consistency between it and the toolbar * Fixed an issue where the toolbar and description were not fading in * Do not hide the toolbar/media player if the video is loading or paused * Created "ExposedPlayPausedVideoView" to allow hooking play/pause * Fix back button when viewing videos * Back button did not work if video controls were visible. * Tweak audio player * Always show the controls when audio begins playing * Do not auto-hide the controls if the player is playing audio * Address PR comments * Use overloaded constructor * Remove m prefix * Fix subtle media player issues * Fix audio player incorrectly auto-hiding after hiding/showing toolbar * Only subscribe touch listener once content is ready - Prevents top toolbar visibility from getting out of phase with audio player visibility if hidden during load
44 lines
No EOL
1.8 KiB
XML
44 lines
No EOL
1.8 KiB
XML
<?xml version="1.0" encoding="utf-8"?>
|
|
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
|
xmlns:app="http://schemas.android.com/apk/res-auto"
|
|
xmlns:tools="http://schemas.android.com/tools"
|
|
android:id="@+id/videoContainer"
|
|
android:layout_width="match_parent"
|
|
android:layout_height="match_parent"
|
|
android:clickable="true"
|
|
android:focusable="true">
|
|
|
|
<TextView
|
|
android:id="@+id/mediaDescription"
|
|
android:layout_width="match_parent"
|
|
android:layout_height="wrap_content"
|
|
android:layout_marginTop="?attr/actionBarSize"
|
|
android:background="#60000000"
|
|
android:hyphenationFrequency="full"
|
|
android:lineSpacingMultiplier="1.1"
|
|
android:padding="8dp"
|
|
android:textAlignment="center"
|
|
android:textColor="#eee"
|
|
android:textSize="?attr/status_text_medium"
|
|
app:layout_constraintTop_toTopOf="parent"
|
|
tools:text="Some media description" />
|
|
|
|
<com.keylesspalace.tusky.view.ExposedPlayPauseVideoView
|
|
android:id="@+id/videoView"
|
|
android:layout_width="wrap_content"
|
|
android:layout_height="match_parent"
|
|
app:layout_constraintBottom_toBottomOf="parent"
|
|
app:layout_constraintLeft_toLeftOf="parent"
|
|
app:layout_constraintRight_toRightOf="parent"
|
|
app:layout_constraintTop_toTopOf="parent" />
|
|
|
|
<ProgressBar
|
|
android:id="@+id/progressBar"
|
|
android:layout_width="wrap_content"
|
|
android:layout_height="wrap_content"
|
|
app:layout_constraintBottom_toBottomOf="parent"
|
|
app:layout_constraintLeft_toLeftOf="parent"
|
|
app:layout_constraintRight_toRightOf="parent"
|
|
app:layout_constraintTop_toTopOf="parent" />
|
|
|
|
</androidx.constraintlayout.widget.ConstraintLayout> |