From 36a43c356e33ce97017801dc25f711b576486a11 Mon Sep 17 00:00:00 2001 From: brainbreaker Date: Sun, 12 Feb 2017 22:29:21 +0530 Subject: [PATCH] Fixed the margins of list items of File Recycler View MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Screenshots of the change:- Before: 1. https://s19.postimg.org/bbs91keyr/Screenshot_20170212_182941.png 2. https://s19.postimg.org/k5j5io1xf/Screenshot_20170212_183334.png Now: 1. https://s19.postimg.org/4o08spkub/Screenshot_20170212_222359.png 2. https://s19.postimg.org/5p0hhu1tv/Screenshot_20170212_222406.png Change-Id: I3137ce2648c4dda30d7bbe93245618a83e9048c0 Reviewed-on: https://gerrit.libreoffice.org/34175 Tested-by: Jenkins Reviewed-by: Aleksandar Stefanović Tested-by: Aleksandar Stefanović --- android/source/res/layout/file_list_item.xml | 19 ++++++++++++++----- .../source/res/layout/item_recent_files.xml | 16 ++++++++++------ android/source/res/values/dimens.xml | 3 +++ android/source/res/values/themes.xml | 2 +- 4 files changed, 28 insertions(+), 12 deletions(-) diff --git a/android/source/res/layout/file_list_item.xml b/android/source/res/layout/file_list_item.xml index 7d703befb233..a2dcfdbaba59 100644 --- a/android/source/res/layout/file_list_item.xml +++ b/android/source/res/layout/file_list_item.xml @@ -9,14 +9,19 @@ xmlns:tools="http://schemas.android.com/tools" android:layout_width="match_parent" android:layout_height="48dp" - android:orientation="horizontal" > + android:orientation="horizontal" + android:layout_marginStart="@dimen/list_item_margin" + android:layout_marginLeft="@dimen/list_item_margin" + android:layout_marginEnd="@dimen/list_item_margin" + android:layout_marginRight="@dimen/list_item_margin"> + android:layout_weight="2" + android:ellipsize="end" + android:maxLines="1"/> + android:layout_weight="2" + android:ellipsize="end" + android:maxLines="1"/> diff --git a/android/source/res/layout/item_recent_files.xml b/android/source/res/layout/item_recent_files.xml index fa966d8b554c..b374ba56f04f 100644 --- a/android/source/res/layout/item_recent_files.xml +++ b/android/source/res/layout/item_recent_files.xml @@ -12,23 +12,27 @@ android:layout_height="48dp" android:orientation="horizontal" android:background="?android:attr/selectableItemBackground" + android:layout_marginStart="@dimen/list_item_margin" + android:layout_marginLeft="@dimen/list_item_margin" + android:layout_marginEnd="@dimen/list_item_margin" + android:layout_marginRight="@dimen/list_item_margin" tools:ignore="UseCompoundDrawables"> - - - - \ No newline at end of file + style="@style/ListItemText" + android:maxLines="1" + android:ellipsize="end"/> + diff --git a/android/source/res/values/dimens.xml b/android/source/res/values/dimens.xml index 1e5d7716f192..7c48f2bc14f3 100644 --- a/android/source/res/values/dimens.xml +++ b/android/source/res/values/dimens.xml @@ -5,4 +5,7 @@ 30dp 44dp 2dp + 8dp + 8dp + 32dp diff --git a/android/source/res/values/themes.xml b/android/source/res/values/themes.xml index e5287a832ed6..4036d97e57ba 100644 --- a/android/source/res/values/themes.xml +++ b/android/source/res/values/themes.xml @@ -8,7 +8,7 @@