aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDocile-Alligator <chineseperson5@gmail.com>2020-12-29 09:02:58 +0000
committerGitHub <noreply@github.com>2020-12-29 09:02:58 +0000
commit1d857eed4738a150f6dd41a1ed4d7df672c60f6a (patch)
treef1ac74e0c10b3136c9b6f72c06fc598f905f9ad9
parent7b154f4d31a59cce78007a9e1c3e44ca55465b6a (diff)
parent15048e7f1bb1620ff7981daf74ef3ae80e16a377 (diff)
downloadinfinity-for-reddit-1d857eed4738a150f6dd41a1ed4d7df672c60f6a.tar
infinity-for-reddit-1d857eed4738a150f6dd41a1ed4d7df672c60f6a.tar.gz
infinity-for-reddit-1d857eed4738a150f6dd41a1ed4d7df672c60f6a.tar.bz2
infinity-for-reddit-1d857eed4738a150f6dd41a1ed4d7df672c60f6a.tar.lz
infinity-for-reddit-1d857eed4738a150f6dd41a1ed4d7df672c60f6a.tar.xz
infinity-for-reddit-1d857eed4738a150f6dd41a1ed4d7df672c60f6a.tar.zst
infinity-for-reddit-1d857eed4738a150f6dd41a1ed4d7df672c60f6a.zip
Merge pull request #232 from Skyluker4/AutoplayVideoBackground
Autoplay video background
-rw-r--r--app/src/main/res/drawable/background_autoplay.xml11
-rw-r--r--app/src/main/res/layout/exo_autoplay_playback_control_view.xml3
-rw-r--r--app/src/main/res/layout/item_post_detail_video_autoplay.xml3
-rw-r--r--app/src/main/res/layout/item_post_video_type_autoplay.xml3
4 files changed, 17 insertions, 3 deletions
diff --git a/app/src/main/res/drawable/background_autoplay.xml b/app/src/main/res/drawable/background_autoplay.xml
new file mode 100644
index 00000000..8859f467
--- /dev/null
+++ b/app/src/main/res/drawable/background_autoplay.xml
@@ -0,0 +1,11 @@
+<?xml version="1.0" encoding="utf-8"?>
+<shape xmlns:android="http://schemas.android.com/apk/res/android" android:shape="rectangle" >
+
+ <solid
+ android:color="#80000000" />
+
+ <corners
+ android:topLeftRadius="16dp"
+ android:topRightRadius="16dp" />
+
+</shape>
diff --git a/app/src/main/res/layout/exo_autoplay_playback_control_view.xml b/app/src/main/res/layout/exo_autoplay_playback_control_view.xml
index 76cc3b86..efdd1ac4 100644
--- a/app/src/main/res/layout/exo_autoplay_playback_control_view.xml
+++ b/app/src/main/res/layout/exo_autoplay_playback_control_view.xml
@@ -5,7 +5,8 @@
android:layout_height="wrap_content"
android:paddingStart="16dp"
android:paddingEnd="8dp"
- android:layout_gravity="bottom">
+ android:layout_gravity="bottom"
+ android:background="@drawable/background_autoplay">
<TextView android:id="@id/exo_position"
android:layout_width="wrap_content"
diff --git a/app/src/main/res/layout/item_post_detail_video_autoplay.xml b/app/src/main/res/layout/item_post_detail_video_autoplay.xml
index 556a9aff..150f54d6 100644
--- a/app/src/main/res/layout/item_post_detail_video_autoplay.xml
+++ b/app/src/main/res/layout/item_post_detail_video_autoplay.xml
@@ -205,7 +205,8 @@
android:id="@+id/player_view_item_post_detail_video_autoplay"
android:layout_width="match_parent"
android:layout_height="match_parent"
- app:controller_layout_id="@layout/exo_autoplay_playback_control_view"/>
+ app:controller_layout_id="@layout/exo_autoplay_playback_control_view"
+ android:animateLayoutChanges="true" />
<pl.droidsonroids.gif.GifImageView
android:id="@+id/preview_image_view_item_post_detail_video_autoplay"
diff --git a/app/src/main/res/layout/item_post_video_type_autoplay.xml b/app/src/main/res/layout/item_post_video_type_autoplay.xml
index 0485f249..b4fcb314 100644
--- a/app/src/main/res/layout/item_post_video_type_autoplay.xml
+++ b/app/src/main/res/layout/item_post_video_type_autoplay.xml
@@ -208,7 +208,8 @@
android:id="@+id/player_view_item_post_video_type_autoplay"
android:layout_width="match_parent"
android:layout_height="match_parent"
- app:controller_layout_id="@layout/exo_autoplay_playback_control_view" />
+ app:controller_layout_id="@layout/exo_autoplay_playback_control_view"
+ android:animateLayoutChanges="true" />
<pl.droidsonroids.gif.GifImageView
android:id="@+id/preview_image_view_item_post_video_type_autoplay"