[Android] Fix RTL support in history + indentation
Geoffrey Métais
git at videolan.org
Sun Feb 5 18:08:25 CET 2017
vlc-android | branch: master | Geoffrey Métais <geoffrey.metais at gmail.com> | Sun Feb 5 18:03:53 2017 +0100| [b35dfc9c93208e11758d0c488fe701027ca9ad10] | committer: Geoffrey Métais
Fix RTL support in history + indentation
> https://code.videolan.org/videolan/vlc-android/commit/b35dfc9c93208e11758d0c488fe701027ca9ad10
---
vlc-android/res/layout/history_item.xml | 85 ++++++++++++++++-----------------
1 file changed, 42 insertions(+), 43 deletions(-)
diff --git a/vlc-android/res/layout/history_item.xml b/vlc-android/res/layout/history_item.xml
index ffef665..31fffd4 100644
--- a/vlc-android/res/layout/history_item.xml
+++ b/vlc-android/res/layout/history_item.xml
@@ -1,6 +1,5 @@
<?xml version="1.0" encoding="utf-8"?>
<layout xmlns:app="http://schemas.android.com/apk/res-auto"
- xmlns:tools="http://schemas.android.com/tools"
xmlns:android="http://schemas.android.com/apk/res/android" >
<data>
<import type="org.videolan.medialibrary.media.MediaWrapper"/>
@@ -16,50 +15,50 @@
name="bgColor"
type="int" />
</data>
-<android.support.constraint.ConstraintLayout
- android:layout_width="match_parent"
- android:layout_height="wrap_content"
- android:background="@{bgColor}"
- android:clickable="true"
- android:onClick="@{holder::onClick}"
- android:onLongClick="@{holder::onLongClick}" >
- <ImageView
- android:id="@+id/icon"
- android:layout_width="wrap_content"
+ <android.support.constraint.ConstraintLayout
+ android:layout_width="match_parent"
android:layout_height="wrap_content"
- android:scaleType="centerCrop"
- android:src="@{media.type == MediaWrapper.TYPE_VIDEO ? @drawable/ic_browser_video_normal : @drawable/ic_browser_audio_normal}"
- app:layout_constraintLeft_toLeftOf="parent" />
+ android:background="@{bgColor}"
+ android:clickable="true"
+ android:onClick="@{holder::onClick}"
+ android:onLongClick="@{holder::onLongClick}" >
+ <ImageView
+ android:id="@+id/icon"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:scaleType="centerCrop"
+ android:src="@{media.type == MediaWrapper.TYPE_VIDEO ? @drawable/ic_browser_video_normal : @drawable/ic_browser_audio_normal}"
+ app:layout_constraintStart_toStartOf="parent" />
- <TextView
- android:id="@+id/title"
- android:layout_width="0dp"
- android:layout_height="wrap_content"
- android:text="@{media.title}"
- android:fontFamily="sans-serif-light"
- android:textColor="?attr/list_title"
- android:textSize="16sp"
- android:maxLines="1"
- app:layout_constraintBottom_toTopOf="@+id/subtitle"
- app:layout_constraintTop_toTopOf="parent"
- app:layout_constraintStart_toEndOf="@id/icon"
- app:layout_constraintEnd_toEndOf="parent"
- app:layout_constraintVertical_chainStyle="packed" />
+ <TextView
+ android:id="@+id/title"
+ android:layout_width="0dp"
+ android:layout_height="wrap_content"
+ android:text="@{media.title}"
+ android:fontFamily="sans-serif-light"
+ android:textColor="?attr/list_title"
+ android:textSize="16sp"
+ android:maxLines="1"
+ app:layout_constraintBottom_toTopOf="@+id/subtitle"
+ app:layout_constraintTop_toTopOf="parent"
+ app:layout_constraintStart_toEndOf="@id/icon"
+ app:layout_constraintEnd_toEndOf="parent"
+ app:layout_constraintVertical_chainStyle="packed" />
- <TextView
- android:id="@+id/subtitle"
- android:layout_width="0dp"
- android:layout_height="wrap_content"
- android:text="@{media.artist}"
- android:fontFamily="sans-serif-light"
- android:textColor="?attr/list_subtitle"
- android:maxLines="1"
- android:ellipsize="start"
- android:visibility="@{TextUtils.isEmpty(media.artist) ? View.GONE : View.VISIBLE}"
- app:layout_constraintBottom_toBottomOf="parent"
- app:layout_constraintTop_toBottomOf="@id/title"
- app:layout_constraintStart_toEndOf="@id/icon"
- app:layout_constraintEnd_toEndOf="parent"/>
+ <TextView
+ android:id="@+id/subtitle"
+ android:layout_width="0dp"
+ android:layout_height="wrap_content"
+ android:text="@{media.artist}"
+ android:fontFamily="sans-serif-light"
+ android:textColor="?attr/list_subtitle"
+ android:maxLines="1"
+ android:ellipsize="start"
+ android:visibility="@{TextUtils.isEmpty(media.artist) ? View.GONE : View.VISIBLE}"
+ app:layout_constraintBottom_toBottomOf="parent"
+ app:layout_constraintTop_toBottomOf="@id/title"
+ app:layout_constraintStart_toEndOf="@id/icon"
+ app:layout_constraintEnd_toEndOf="parent"/>
-</android.support.constraint.ConstraintLayout>
+ </android.support.constraint.ConstraintLayout>
</layout>
\ No newline at end of file
More information about the Android
mailing list