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

181 lines
6.4 KiB
XML
Raw Normal View History

2019-10-09 18:49:33 +02:00
<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
2019-10-10 19:28:16 +02:00
xmlns:tools="http://schemas.android.com/tools"
2019-10-09 18:49:33 +02:00
android:layout_width="match_parent"
android:layout_height="match_parent"
android:id="@+id/main_container_media">
<!-- Main Loader -->
<RelativeLayout
android:id="@+id/loader"
android:layout_alignParentTop="true"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:gravity="center">
<ProgressBar
style="@style/Base.Widget.AppCompat.ProgressBar.Horizontal"
android:indeterminate="false"
android:id="@+id/pbar_inf"
android:layout_width="match_parent"
android:max="100"
android:progress="0"
android:layout_height="wrap_content" />
<TextView
android:id="@+id/loader_progress"
android:layout_width="match_parent"
android:textColor="@color/dark_text"
android:gravity="center"
android:textSize="12sp"
android:layout_gravity="center"
android:layout_height="wrap_content" />
</RelativeLayout>
<FrameLayout
android:layout_centerInParent="true"
android:id="@+id/media_webview_container"
android:layout_width="match_parent"
android:layout_height="match_parent">
<WebView
android:layout_width="match_parent"
android:visibility="gone"
android:id="@+id/webview_video"
android:layout_height="match_parent" />
</FrameLayout>
<FrameLayout
android:layout_centerInParent="true"
android:id="@+id/media_picture_container"
android:layout_width="match_parent"
android:layout_height="match_parent">
<!-- Description is set dynamically -->
<com.github.chrisbanes.photoview.PhotoView
android:visibility="gone"
android:id="@+id/media_picture"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:adjustViewBounds="true" />
</FrameLayout>
<RelativeLayout
android:id="@+id/content_audio"
android:visibility="gone"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical"
android:gravity="center">
<LinearLayout
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentTop="true"
android:layout_centerHorizontal="true"
android:layout_marginTop="50dp"
android:orientation="vertical">
<TextView
android:id="@+id/status"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginBottom="-10dp"
android:textSize="20sp"
android:textColor="@android:color/white"
android:fontFamily="sans-serif-light"
android:visibility="invisible" />
<TextView
android:id="@+id/timer"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:textSize="60sp"
android:textColor="@android:color/white"
android:fontFamily="sans-serif-thin"
2019-10-10 19:28:16 +02:00
android:text="00:00:00"
tools:ignore="HardcodedText" />
2019-10-09 18:49:33 +02:00
</LinearLayout>
<RelativeLayout
android:layout_width="match_parent"
android:layout_height="@dimen/aar_footer_height"
android:layout_alignParentBottom="true">
<ImageButton
android:id="@+id/play"
android:layout_width="80dp"
android:layout_height="80dp"
android:layout_centerVertical="true"
android:layout_centerInParent="true"
android:layout_marginTop="50dp"
android:padding="10dp"
android:scaleType="fitCenter"
android:src="@drawable/aar_ic_play"
android:onClick="togglePlaying"
2019-10-10 19:28:16 +02:00
style="@style/Widget.AppCompat.Button.Borderless"
android:contentDescription="@string/play_video" />
2019-10-09 18:49:33 +02:00
</RelativeLayout>
</RelativeLayout>
<com.google.android.exoplayer2.ui.SimpleExoPlayerView
android:visibility="gone"
android:id="@+id/media_video"
android:layout_centerInParent="true"
android:layout_width="match_parent"
android:layout_height="match_parent" />
<ImageView
android:id="@+id/media_prev"
android:layout_width="30dp"
android:layout_height="50dp"
android:layout_alignParentStart="true"
android:layout_centerVertical="true"
android:layout_marginStart="5dp"
android:layout_marginLeft="5dp"
android:layout_marginTop="5dp"
android:layout_marginEnd="5dp"
android:layout_marginRight="5dp"
android:layout_marginBottom="5dp"
android:background="@color/transparent_grey"
android:tint="@color/white"
android:contentDescription="@string/previous"
android:src="@drawable/ic_first_page"
android:visibility="gone" />
<ImageView
android:id="@+id/media_next"
android:layout_width="30dp"
android:layout_height="50dp"
android:layout_alignParentEnd="true"
android:layout_centerVertical="true"
android:layout_marginStart="5dp"
android:layout_marginLeft="5dp"
android:layout_marginTop="5dp"
android:layout_marginEnd="5dp"
android:layout_marginRight="5dp"
android:layout_marginBottom="5dp"
android:background="@color/transparent_grey"
android:contentDescription="@string/next"
android:src="@drawable/ic_last_page"
android:visibility="gone" />
<TextView
android:visibility="gone"
android:background="@drawable/media_message_border"
android:id="@+id/message_ready"
android:textColor="@color/dark_text"
android:text="@string/media_ready"
android:gravity="center"
android:textSize="14sp"
android:layout_alignBottom="@+id/media_picture_container"
android:layout_marginBottom="40dp"
android:layout_width="match_parent"
android:layout_height="40dp" />
</RelativeLayout>