2019-09-06 17:55:14 +02:00
|
|
|
<?xml version="1.0" encoding="utf-8"?><!--
|
2018-10-14 15:20:05 +02:00
|
|
|
Copyright 2018 Thomas Schneider
|
|
|
|
|
2019-05-18 11:10:30 +02:00
|
|
|
This file is a part of Fedilab
|
2018-10-14 15:20:05 +02:00
|
|
|
|
|
|
|
This program is free software; you can redistribute it and/or modify it under the terms of the
|
|
|
|
GNU General Public License as published by the Free Software Foundation; either version 3 of the
|
|
|
|
License, or (at your option) any later version.
|
|
|
|
|
2019-05-18 11:10:30 +02:00
|
|
|
Fedilab is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even
|
2018-10-14 15:20:05 +02:00
|
|
|
the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General
|
|
|
|
Public License for more details.
|
|
|
|
|
2019-05-18 11:10:30 +02:00
|
|
|
You should have received a copy of the GNU General Public License along with Fedilab; if not,
|
2018-10-14 15:20:05 +02:00
|
|
|
see <http://www.gnu.org/licenses>.
|
|
|
|
-->
|
|
|
|
|
2019-09-06 17:55:14 +02:00
|
|
|
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
2018-10-14 15:20:05 +02:00
|
|
|
xmlns:tools="http://schemas.android.com/tools"
|
|
|
|
xmlns:app="http://schemas.android.com/apk/res-auto"
|
|
|
|
android:layout_width="match_parent"
|
|
|
|
android:layout_height="match_parent"
|
2019-01-25 16:15:35 +01:00
|
|
|
android:keepScreenOn="true"
|
2019-05-18 11:10:30 +02:00
|
|
|
tools:context="app.fedilab.android.activities.PeertubeActivity">
|
2018-10-14 16:17:25 +02:00
|
|
|
|
2018-10-17 11:32:16 +02:00
|
|
|
<LinearLayout
|
2018-10-14 16:17:25 +02:00
|
|
|
android:layout_width="match_parent"
|
|
|
|
android:layout_height="match_parent"
|
2018-10-17 11:32:16 +02:00
|
|
|
android:orientation="vertical">
|
2019-09-06 17:55:14 +02:00
|
|
|
|
2018-10-17 11:32:16 +02:00
|
|
|
<RelativeLayout
|
|
|
|
android:layout_width="match_parent"
|
|
|
|
android:layout_height="0dp"
|
|
|
|
android:layout_weight="1">
|
2019-09-06 17:55:14 +02:00
|
|
|
|
2019-01-06 13:20:06 +01:00
|
|
|
<FrameLayout
|
|
|
|
android:id="@+id/main_media_frame"
|
2018-10-17 11:32:16 +02:00
|
|
|
android:layout_width="match_parent"
|
2019-01-06 13:20:06 +01:00
|
|
|
android:layout_centerInParent="true"
|
2018-10-17 11:32:16 +02:00
|
|
|
android:layout_height="match_parent"
|
|
|
|
android:layout_gravity="center"
|
|
|
|
app:layout_constraintLeft_toLeftOf="parent"
|
|
|
|
app:layout_constraintRight_toRightOf="parent"
|
|
|
|
app:layout_constraintTop_toTopOf="parent"
|
2019-01-06 13:20:06 +01:00
|
|
|
app:layout_constraintBottom_toBottomOf="parent"
|
|
|
|
android:background="#000000">
|
2019-09-06 17:55:14 +02:00
|
|
|
|
2019-01-06 13:20:06 +01:00
|
|
|
<com.google.android.exoplayer2.ui.SimpleExoPlayerView
|
|
|
|
android:id="@+id/media_video"
|
|
|
|
android:layout_width="match_parent"
|
|
|
|
android:layout_height="match_parent"
|
|
|
|
android:gravity="center" />
|
2019-09-06 17:55:14 +02:00
|
|
|
|
2019-01-06 16:06:18 +01:00
|
|
|
<WebView
|
|
|
|
android:layout_width="match_parent"
|
|
|
|
android:visibility="gone"
|
|
|
|
android:id="@+id/webview_video"
|
2019-09-06 17:55:14 +02:00
|
|
|
android:layout_height="match_parent" />
|
2019-01-06 13:20:06 +01:00
|
|
|
|
|
|
|
</FrameLayout>
|
|
|
|
|
2018-10-17 11:32:16 +02:00
|
|
|
<!-- Main Loader -->
|
2019-05-27 19:22:54 +02:00
|
|
|
<RelativeLayout
|
2018-10-17 11:32:16 +02:00
|
|
|
android:id="@+id/loader"
|
|
|
|
android:visibility="gone"
|
|
|
|
android:layout_width="match_parent"
|
|
|
|
android:layout_height="match_parent"
|
2019-09-06 17:55:14 +02:00
|
|
|
android:gravity="center">
|
|
|
|
|
2018-10-17 11:32:16 +02:00
|
|
|
<ProgressBar
|
|
|
|
android:layout_width="wrap_content"
|
|
|
|
android:layout_height="wrap_content"
|
|
|
|
android:indeterminate="true" />
|
|
|
|
</RelativeLayout>
|
|
|
|
</RelativeLayout>
|
2019-09-06 17:55:14 +02:00
|
|
|
|
2018-10-17 11:32:16 +02:00
|
|
|
<ScrollView
|
|
|
|
android:id="@+id/peertube_information_container"
|
|
|
|
android:layout_width="match_parent"
|
|
|
|
android:layout_height="0dp"
|
|
|
|
android:layout_weight="2">
|
2019-09-06 17:55:14 +02:00
|
|
|
|
2018-10-17 11:32:16 +02:00
|
|
|
<LinearLayout
|
|
|
|
android:layout_width="match_parent"
|
|
|
|
android:layout_height="wrap_content"
|
|
|
|
android:layout_marginRight="20dp"
|
|
|
|
android:layout_marginStart="20dp"
|
|
|
|
android:layout_marginLeft="20dp"
|
|
|
|
android:layout_marginEnd="20dp"
|
|
|
|
android:orientation="vertical">
|
2019-09-06 17:55:14 +02:00
|
|
|
|
2018-10-17 11:32:16 +02:00
|
|
|
<TextView
|
|
|
|
android:layout_marginTop="5dp"
|
|
|
|
android:id="@+id/peertube_title"
|
|
|
|
android:layout_width="match_parent"
|
|
|
|
android:layout_height="wrap_content" />
|
2019-09-06 17:55:14 +02:00
|
|
|
|
2018-10-17 11:32:16 +02:00
|
|
|
<LinearLayout
|
|
|
|
android:layout_width="match_parent"
|
|
|
|
android:layout_height="wrap_content"
|
|
|
|
android:layout_marginTop="5dp"
|
|
|
|
android:orientation="horizontal">
|
2019-09-06 17:55:14 +02:00
|
|
|
|
2018-10-17 11:32:16 +02:00
|
|
|
<TextView
|
|
|
|
android:id="@+id/peertube_view_count"
|
|
|
|
android:layout_gravity="center_horizontal"
|
|
|
|
android:gravity="center_horizontal"
|
|
|
|
android:drawableTop="@drawable/ic_visibility_peertube"
|
|
|
|
android:drawablePadding="5dp"
|
|
|
|
android:layout_width="wrap_content"
|
|
|
|
android:layout_marginRight="10dp"
|
|
|
|
android:layout_marginEnd="10dp"
|
|
|
|
android:layout_marginLeft="10dp"
|
|
|
|
android:layout_marginStart="10dp"
|
|
|
|
android:text="0"
|
|
|
|
android:layout_height="wrap_content"
|
|
|
|
tools:ignore="HardcodedText" />
|
2019-09-06 17:55:14 +02:00
|
|
|
|
2018-10-17 11:32:16 +02:00
|
|
|
<TextView
|
|
|
|
android:id="@+id/peertube_like_count"
|
|
|
|
android:layout_gravity="center_horizontal"
|
|
|
|
android:gravity="center_horizontal"
|
|
|
|
android:drawablePadding="5dp"
|
|
|
|
android:layout_width="wrap_content"
|
|
|
|
android:layout_marginRight="10dp"
|
|
|
|
android:layout_marginEnd="10dp"
|
|
|
|
android:layout_marginLeft="10dp"
|
|
|
|
android:layout_marginStart="20dp"
|
|
|
|
android:text="0"
|
|
|
|
android:layout_height="wrap_content"
|
|
|
|
tools:ignore="HardcodedText" />
|
2019-09-06 17:55:14 +02:00
|
|
|
|
2018-10-17 11:32:16 +02:00
|
|
|
<TextView
|
|
|
|
android:id="@+id/peertube_dislike_count"
|
|
|
|
android:layout_gravity="center_horizontal"
|
|
|
|
android:gravity="center_horizontal"
|
|
|
|
android:drawablePadding="5dp"
|
|
|
|
android:layout_width="wrap_content"
|
|
|
|
android:layout_marginRight="10dp"
|
|
|
|
android:layout_marginEnd="10dp"
|
|
|
|
android:layout_marginLeft="10dp"
|
|
|
|
android:layout_marginStart="10dp"
|
|
|
|
android:text="0"
|
|
|
|
android:layout_height="wrap_content"
|
|
|
|
tools:ignore="HardcodedText" />
|
2019-09-06 17:55:14 +02:00
|
|
|
|
2018-10-21 18:43:57 +02:00
|
|
|
<TextView
|
|
|
|
android:id="@+id/peertube_bookmark"
|
|
|
|
android:layout_gravity="center_horizontal"
|
|
|
|
android:gravity="center_horizontal"
|
|
|
|
android:drawableTop="@drawable/ic_bookmark_peertube_border"
|
|
|
|
android:drawablePadding="5dp"
|
|
|
|
android:layout_width="wrap_content"
|
2019-05-27 19:22:54 +02:00
|
|
|
android:layout_marginRight="10dp"
|
|
|
|
android:layout_marginEnd="10dp"
|
|
|
|
android:layout_marginLeft="10dp"
|
|
|
|
android:layout_marginStart="10dp"
|
|
|
|
android:text=""
|
2019-09-06 17:55:14 +02:00
|
|
|
android:layout_height="wrap_content" />
|
|
|
|
|
2019-05-27 19:22:54 +02:00
|
|
|
<TextView
|
|
|
|
android:visibility="gone"
|
|
|
|
android:id="@+id/peertube_playlist"
|
|
|
|
android:layout_gravity="center_horizontal"
|
|
|
|
android:gravity="center_horizontal"
|
|
|
|
android:drawableTop="@drawable/ic_list_peertube_activity"
|
|
|
|
android:drawablePadding="5dp"
|
|
|
|
android:layout_width="wrap_content"
|
2018-10-21 18:43:57 +02:00
|
|
|
android:layout_marginRight="10dp"
|
|
|
|
android:layout_marginEnd="10dp"
|
|
|
|
android:layout_marginLeft="10dp"
|
|
|
|
android:layout_marginStart="10dp"
|
|
|
|
android:text=""
|
2019-09-06 17:55:14 +02:00
|
|
|
android:layout_height="wrap_content" />
|
|
|
|
|
2018-10-17 11:32:16 +02:00
|
|
|
<LinearLayout
|
|
|
|
android:layout_weight="1"
|
|
|
|
android:layout_width="0dp"
|
|
|
|
android:layout_height="wrap_content"
|
|
|
|
tools:ignore="UselessLeaf" />
|
2019-09-06 17:55:14 +02:00
|
|
|
|
2018-10-17 11:32:16 +02:00
|
|
|
<TextView
|
|
|
|
android:id="@+id/peertube_share"
|
|
|
|
android:layout_gravity="center_horizontal"
|
|
|
|
android:gravity="center_horizontal"
|
|
|
|
android:drawableTop="@drawable/ic_share_peertube"
|
|
|
|
android:drawablePadding="5dp"
|
|
|
|
android:layout_width="wrap_content"
|
|
|
|
android:layout_marginRight="10dp"
|
|
|
|
android:layout_marginEnd="10dp"
|
|
|
|
android:layout_marginLeft="10dp"
|
|
|
|
android:layout_marginStart="10dp"
|
|
|
|
android:textSize="12sp"
|
|
|
|
android:text="@string/more_action_6"
|
2019-09-06 17:55:14 +02:00
|
|
|
android:layout_height="wrap_content" />
|
|
|
|
|
2018-10-17 11:32:16 +02:00
|
|
|
<TextView
|
|
|
|
android:id="@+id/peertube_download"
|
|
|
|
android:layout_gravity="center_horizontal"
|
|
|
|
android:gravity="center_horizontal"
|
|
|
|
android:drawableTop="@drawable/ic_cloud_download_peertube"
|
|
|
|
android:drawablePadding="5dp"
|
|
|
|
android:layout_width="wrap_content"
|
|
|
|
android:textSize="12sp"
|
|
|
|
android:layout_marginRight="10dp"
|
|
|
|
android:layout_marginEnd="10dp"
|
|
|
|
android:layout_marginLeft="10dp"
|
|
|
|
android:layout_marginStart="10dp"
|
|
|
|
android:text="@string/download"
|
2019-09-06 17:55:14 +02:00
|
|
|
android:layout_height="wrap_content" />
|
2018-10-17 11:32:16 +02:00
|
|
|
</LinearLayout>
|
2019-09-06 17:55:14 +02:00
|
|
|
|
2018-10-17 11:32:16 +02:00
|
|
|
<TextView
|
|
|
|
android:layout_marginTop="10dp"
|
|
|
|
android:id="@+id/peertube_description"
|
|
|
|
android:layout_width="match_parent"
|
|
|
|
android:layout_height="wrap_content" />
|
2019-09-06 17:55:14 +02:00
|
|
|
|
2019-01-25 16:15:35 +01:00
|
|
|
<LinearLayout
|
|
|
|
android:id="@+id/write_comment_container"
|
|
|
|
android:layout_width="match_parent"
|
|
|
|
android:layout_marginTop="10dp"
|
|
|
|
android:visibility="gone"
|
|
|
|
android:layout_gravity="center_vertical"
|
|
|
|
android:orientation="horizontal"
|
|
|
|
android:layout_height="wrap_content">
|
2019-09-06 17:55:14 +02:00
|
|
|
|
2019-01-25 16:15:35 +01:00
|
|
|
<LinearLayout
|
|
|
|
android:orientation="vertical"
|
|
|
|
android:layout_width="wrap_content"
|
|
|
|
android:layout_height="wrap_content">
|
2019-09-06 17:55:14 +02:00
|
|
|
|
2019-01-25 16:15:35 +01:00
|
|
|
<ImageView
|
|
|
|
android:contentDescription="@string/profile_picture"
|
|
|
|
android:id="@+id/my_pp"
|
|
|
|
android:layout_width="40dp"
|
|
|
|
android:layout_height="40dp" />
|
2019-09-06 17:55:14 +02:00
|
|
|
|
2019-01-25 16:15:35 +01:00
|
|
|
<ImageView
|
|
|
|
android:contentDescription="@string/send_comment"
|
|
|
|
android:id="@+id/send"
|
|
|
|
android:layout_marginTop="5dp"
|
|
|
|
android:visibility="gone"
|
|
|
|
android:src="@drawable/ic_send"
|
|
|
|
android:layout_width="30dp"
|
|
|
|
android:layout_height="30dp" />
|
|
|
|
</LinearLayout>
|
|
|
|
|
|
|
|
<LinearLayout
|
|
|
|
android:orientation="vertical"
|
|
|
|
android:layout_width="0dp"
|
|
|
|
android:layout_weight="1"
|
|
|
|
android:layout_gravity="center_vertical"
|
|
|
|
android:layout_marginLeft="10dp"
|
|
|
|
android:layout_marginStart="10dp"
|
|
|
|
android:layout_marginTop="5dp"
|
|
|
|
android:layout_marginBottom="5dp"
|
|
|
|
android:layout_height="wrap_content">
|
2019-09-06 17:55:14 +02:00
|
|
|
|
2019-01-25 16:15:35 +01:00
|
|
|
<TextView
|
|
|
|
android:id="@+id/add_comment_read"
|
|
|
|
android:text="@string/add_public_comment"
|
|
|
|
android:layout_width="match_parent"
|
|
|
|
android:layout_height="wrap_content" />
|
2019-09-06 17:55:14 +02:00
|
|
|
|
2019-01-25 16:15:35 +01:00
|
|
|
<EditText
|
|
|
|
android:visibility="gone"
|
|
|
|
android:hint="@string/add_public_comment"
|
|
|
|
android:id="@+id/add_comment_write"
|
|
|
|
android:layout_width="match_parent"
|
|
|
|
android:layout_height="wrap_content"
|
|
|
|
android:overScrollMode="always"
|
|
|
|
android:scrollbarStyle="insideInset"
|
|
|
|
android:scrollbars="vertical"
|
|
|
|
android:focusable="true"
|
|
|
|
android:focusableInTouchMode="true"
|
|
|
|
android:maxLines="4"
|
|
|
|
android:inputType="textMultiLine" />
|
|
|
|
</LinearLayout>
|
|
|
|
|
|
|
|
</LinearLayout>
|
2019-09-06 17:55:14 +02:00
|
|
|
|
2019-06-11 19:38:26 +02:00
|
|
|
<androidx.recyclerview.widget.RecyclerView
|
2018-10-17 11:32:16 +02:00
|
|
|
android:id="@+id/peertube_comments"
|
|
|
|
android:layout_width="match_parent"
|
2019-09-06 17:55:14 +02:00
|
|
|
android:layout_height="wrap_content" />
|
|
|
|
|
2018-10-17 11:32:16 +02:00
|
|
|
<RelativeLayout
|
|
|
|
android:id="@+id/no_action"
|
|
|
|
android:visibility="gone"
|
|
|
|
android:layout_width="match_parent"
|
|
|
|
android:layout_height="wrap_content">
|
2019-09-06 17:55:14 +02:00
|
|
|
|
2018-10-17 11:32:16 +02:00
|
|
|
<TextView
|
|
|
|
android:padding="10dp"
|
2018-10-20 15:16:57 +02:00
|
|
|
android:id="@+id/no_action_text"
|
2018-10-17 11:32:16 +02:00
|
|
|
android:gravity="center"
|
|
|
|
android:textSize="25sp"
|
|
|
|
android:layout_gravity="center"
|
|
|
|
android:textStyle="italic|bold"
|
|
|
|
android:typeface="serif"
|
|
|
|
android:text="@string/no_comments"
|
|
|
|
android:layout_width="match_parent"
|
|
|
|
android:layout_height="match_parent" />
|
|
|
|
</RelativeLayout>
|
|
|
|
</LinearLayout>
|
|
|
|
</ScrollView>
|
2019-01-06 16:06:18 +01:00
|
|
|
<!-- View where the video will be shown when video goes fullscreen -->
|
|
|
|
<RelativeLayout
|
|
|
|
android:id="@+id/videoLayout"
|
|
|
|
android:visibility="gone"
|
|
|
|
android:background="@color/black"
|
|
|
|
android:layout_width="match_parent"
|
|
|
|
android:layout_height="match_parent" />
|
2018-10-17 11:32:16 +02:00
|
|
|
</LinearLayout>
|
2019-06-11 19:38:26 +02:00
|
|
|
</androidx.constraintlayout.widget.ConstraintLayout>
|