[Android] History: add missing icon to missing media

Duncan McNamara git at videolan.org
Wed Feb 16 14:15:50 UTC 2022


vlc-android | branch: master | Duncan McNamara <dcn.mcnamara at gmail.com> | Tue Feb 15 13:58:07 2022 +0100| [c240a550f6a7b6f6fcdf6adfd0e4486891107f3b] | committer: Duncan McNamara

History: add missing icon to missing media

Fixes #2279

> https://code.videolan.org/videolan/vlc-android/commit/c240a550f6a7b6f6fcdf6adfd0e4486891107f3b
---

 application/vlc-android/res/layout/history_item.xml      | 14 ++++++++++++++
 application/vlc-android/res/layout/history_item_card.xml | 14 ++++++++++++++
 2 files changed, 28 insertions(+)

diff --git a/application/vlc-android/res/layout/history_item.xml b/application/vlc-android/res/layout/history_item.xml
index df10ad42b..5fa9f13d6 100644
--- a/application/vlc-android/res/layout/history_item.xml
+++ b/application/vlc-android/res/layout/history_item.xml
@@ -93,6 +93,20 @@
                 vlc:layout_constraintStart_toStartOf="@+id/song_marker"
                 vlc:layout_goneMarginBottom="4dp"
                 vlc:srcCompat="@drawable/ic_network_media" />
+
+            <ImageView
+                android:id="@+id/missing_media"
+                android:layout_width="wrap_content"
+                android:layout_height="wrap_content"
+                android:layout_marginStart="4dp"
+                android:layout_marginBottom="4dp"
+                android:background="@drawable/rounded_corners_black_more_transparent"
+                android:padding="3dp"
+                android:visibility="@{media.isPresent ?  View.GONE : View.VISIBLE}"
+                vlc:layout_constraintBottom_toBottomOf="@+id/song_marker"
+                vlc:layout_constraintStart_toStartOf="@+id/song_marker"
+                vlc:layout_goneMarginBottom="4dp"
+                vlc:srcCompat="@drawable/ic_network_media_off" />
         </androidx.constraintlayout.widget.ConstraintLayout>
 
 
diff --git a/application/vlc-android/res/layout/history_item_card.xml b/application/vlc-android/res/layout/history_item_card.xml
index fa1f7627f..568ee7329 100644
--- a/application/vlc-android/res/layout/history_item_card.xml
+++ b/application/vlc-android/res/layout/history_item_card.xml
@@ -115,6 +115,20 @@
                     vlc:layout_goneMarginBottom="4dp"
                     vlc:srcCompat="@drawable/ic_network_media" />
 
+                <ImageView
+                    android:id="@+id/missing_media"
+                    android:layout_width="wrap_content"
+                    android:layout_height="wrap_content"
+                    android:layout_marginStart="4dp"
+                    android:layout_marginBottom="4dp"
+                    android:background="@drawable/rounded_corners_black_more_transparent"
+                    android:padding="3dp"
+                    android:visibility="@{media.isPresent ?  View.GONE : View.VISIBLE}"
+                    vlc:layout_constraintBottom_toBottomOf="@+id/song_marker"
+                    vlc:layout_constraintStart_toStartOf="@+id/song_marker"
+                    vlc:layout_goneMarginBottom="4dp"
+                    vlc:srcCompat="@drawable/ic_network_media_off" />
+
             </androidx.constraintlayout.widget.ConstraintLayout>
 
 



More information about the Android mailing list