fedilab-Android-App/app/src/main/res/layouts/mastodon/layout/fragment_slide_media.xml

98 lines
3.7 KiB
XML
Raw Normal View History

2022-04-27 15:20:42 +02:00
<?xml version="1.0" encoding="utf-8"?>
<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
2022-04-27 15:20:42 +02:00
android:id="@+id/main_container"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="@android:color/transparent">
2023-01-14 16:21:16 +01:00
<RelativeLayout
android:id="@+id/media_fragment_container"
2022-04-27 15:20:42 +02:00
android:layout_width="match_parent"
android:layout_height="match_parent"
2023-01-14 16:21:16 +01:00
android:background="@color/black">
<!-- Main Loader -->
2022-04-27 15:20:42 +02:00
<RelativeLayout
2023-01-14 16:21:16 +01:00
android:id="@+id/loader"
2022-04-27 15:20:42 +02:00
android:layout_width="match_parent"
2023-01-14 16:21:16 +01:00
android:layout_height="wrap_content"
android:layout_alignParentTop="true"
android:gravity="center">
2022-09-26 17:08:00 +02:00
2023-01-14 16:21:16 +01:00
<ProgressBar
android:id="@+id/pbar_inf"
style="@style/Base.Widget.AppCompat.ProgressBar.Horizontal"
2022-04-27 15:20:42 +02:00
android:layout_width="match_parent"
2023-01-14 16:21:16 +01:00
android:layout_height="wrap_content"
android:indeterminate="false"
android:max="100"
android:progress="0" />
2022-04-27 15:20:42 +02:00
2023-01-14 16:21:16 +01:00
<TextView
android:id="@+id/loader_progress"
2022-09-26 17:08:00 +02:00
android:layout_width="match_parent"
2023-01-14 16:21:16 +01:00
android:layout_height="wrap_content"
android:layout_gravity="center"
android:gravity="center"
android:textSize="12sp" />
</RelativeLayout>
2022-09-26 17:08:00 +02:00
2023-01-14 16:21:16 +01:00
<RelativeLayout
android:id="@+id/videoLayout"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="@color/black"
android:visibility="gone" />
2022-09-26 17:08:00 +02:00
2023-01-14 16:21:16 +01:00
<FrameLayout
android:id="@+id/media_picture_container"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_centerInParent="true">
<!-- Description is set dynamically -->
<com.github.chrisbanes.photoview.PhotoView
android:id="@+id/media_picture"
2022-04-27 15:20:42 +02:00
android:layout_width="match_parent"
android:layout_height="match_parent"
2023-01-14 16:21:16 +01:00
android:adjustViewBounds="true"
2022-04-27 15:20:42 +02:00
android:visibility="gone" />
2023-01-14 16:21:16 +01:00
</FrameLayout>
2022-04-27 15:20:42 +02:00
<FrameLayout xmlns:app="http://schemas.android.com/apk/res-auto"
android:id="@+id/video_view_container"
2023-01-14 16:21:16 +01:00
android:layout_width="match_parent"
android:layout_height="match_parent"
android:visibility="gone">
2024-01-20 18:10:05 +01:00
<androidx.media3.ui.PlayerView
android:id="@+id/media_video"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_gravity="center"
app:use_controller="false" />
2024-01-20 18:10:05 +01:00
<androidx.media3.ui.PlayerControlView
android:id="@+id/controls"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_gravity="bottom"
android:layout_marginBottom="50dp"
2024-01-23 10:03:20 +01:00
app:show_timeout="0" />
</FrameLayout>
2022-09-26 17:08:00 +02:00
<com.google.android.material.button.MaterialButton
android:id="@+id/load_remote"
style="@style/Widget.Material3.Button"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
2024-01-23 10:07:43 +01:00
android:layout_centerInParent="true"
android:text="@string/load_media_remotely"
android:visibility="gone"
tools:visibility="visible" />
2023-01-14 16:21:16 +01:00
</RelativeLayout>
2022-04-27 15:20:42 +02:00
</FrameLayout>