summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authordaniel oeh <daniel.oeh@gmail.com>2013-04-09 12:21:49 +0200
committerdaniel oeh <daniel.oeh@gmail.com>2013-04-09 12:21:49 +0200
commita6d68205a5e511097496a8c2c5f2600f99677d94 (patch)
tree027291e6918d375135aaf1574311166fe40e80ea
parent5da3b934ab148bddd25c67a922a46d73f949dd9c (diff)
downloadAntennaPod-a6d68205a5e511097496a8c2c5f2600f99677d94.zip
Improved external itemlist layout
-rw-r--r--res/layout/episodes_fragment.xml6
-rw-r--r--res/layout/external_itemlist_item.xml43
-rw-r--r--res/layout/feeditemlist_header.xml69
-rw-r--r--res/values/dimens.xml2
-rw-r--r--src/de/danoeh/antennapod/adapter/ExternalEpisodesListAdapter.java2
5 files changed, 68 insertions, 54 deletions
diff --git a/res/layout/episodes_fragment.xml b/res/layout/episodes_fragment.xml
index 5536a5545..da350af15 100644
--- a/res/layout/episodes_fragment.xml
+++ b/res/layout/episodes_fragment.xml
@@ -6,7 +6,11 @@
<ExpandableListView
android:id="@android:id/list"
android:layout_width="match_parent"
- android:layout_height="match_parent" >
+ android:layout_height="match_parent"
+ android:childDivider="@android:color/transparent"
+ android:divider="@android:color/transparent"
+ android:dividerHeight="3dp"
+ android:paddingLeft="8dp" >
</ExpandableListView>
</LinearLayout> \ No newline at end of file
diff --git a/res/layout/external_itemlist_item.xml b/res/layout/external_itemlist_item.xml
index 6f2405abc..a2d496128 100644
--- a/res/layout/external_itemlist_item.xml
+++ b/res/layout/external_itemlist_item.xml
@@ -37,30 +37,16 @@
android:layout_toLeftOf="@id/butAction"
android:layout_toRightOf="@id/imgvFeedimage"
android:ellipsize="end"
- android:maxLines="1"
+ android:lines="2"
android:textColor="?android:attr/textColorPrimary"
android:textSize="@dimen/text_size_small" />
<TextView
- android:id="@+id/txtvFeedname"
- android:layout_width="0dp"
- android:layout_height="wrap_content"
- android:layout_below="@id/txtvTitle"
- android:layout_marginLeft="8dp"
- android:layout_marginRight="8dp"
- android:layout_toLeftOf="@id/butAction"
- android:layout_toRightOf="@id/imgvFeedimage"
- android:ellipsize="end"
- android:maxLines="1"
- android:textColor="?android:attr/textColorSecondary"
- android:textSize="@dimen/text_size_micro" />
-
- <TextView
android:id="@+id/txtvLenSize"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
- android:layout_below="@id/txtvFeedname"
- android:layout_marginBottom="8dp"
+ android:layout_alignParentBottom="true"
+ android:layout_marginBottom="16dp"
android:layout_marginLeft="8dp"
android:layout_marginRight="8dp"
android:layout_marginTop="4dp"
@@ -74,8 +60,8 @@
android:id="@+id/imgvDownloadStatus"
android:layout_width="@dimen/enc_icons_size"
android:layout_height="@dimen/enc_icons_size"
- android:layout_below="@id/txtvFeedname"
- android:layout_marginBottom="8dp"
+ android:layout_alignParentBottom="true"
+ android:layout_marginBottom="16dp"
android:layout_marginLeft="8dp"
android:layout_marginRight="8dp"
android:layout_marginTop="4dp"
@@ -86,7 +72,8 @@
style="?android:attr/progressBarStyleHorizontal"
android:layout_width="0dp"
android:layout_height="wrap_content"
- android:layout_below="@id/txtvFeedname"
+ android:layout_alignParentBottom="true"
+ android:layout_marginBottom="8dp"
android:layout_marginTop="4dp"
android:layout_toLeftOf="@id/imgvDownloadStatus"
android:layout_toRightOf="@id/txtvLenSize" />
@@ -103,4 +90,20 @@
android:padding="2dp"
android:src="@drawable/av_play_dark" />
+ <TextView
+ android:id="@+id/txtvFeedname"
+ android:layout_width="0dp"
+ android:layout_height="wrap_content"
+ android:layout_below="@id/txtvTitle"
+ android:layout_marginTop="4dp"
+ android:layout_marginBottom="4dp"
+ android:layout_marginLeft="8dp"
+ android:layout_marginRight="8dp"
+ android:layout_toLeftOf="@id/butAction"
+ android:layout_toRightOf="@id/imgvFeedimage"
+ android:ellipsize="end"
+ android:maxLines="1"
+ android:textColor="?android:attr/textColorSecondary"
+ android:textSize="@dimen/text_size_micro" />
+
</RelativeLayout> \ No newline at end of file
diff --git a/res/layout/feeditemlist_header.xml b/res/layout/feeditemlist_header.xml
index 4dbeae28b..e03f22e4a 100644
--- a/res/layout/feeditemlist_header.xml
+++ b/res/layout/feeditemlist_header.xml
@@ -1,38 +1,45 @@
<?xml version="1.0" encoding="utf-8"?>
-<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
+<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="match_parent"
- android:background="?attr/borderless_button" >
+ android:background="?attr/borderless_button"
+ android:orientation="vertical" >
- <TextView
- android:id="@+id/txtvHeaderTitle"
+ <RelativeLayout
android:layout_width="wrap_content"
- android:layout_height="wrap_content"
- android:layout_alignParentLeft="true"
- android:layout_centerVertical="true"
- android:layout_marginBottom="24dp"
- android:layout_marginLeft="@dimen/thumbnail_length_itemlist"
- android:layout_marginRight="16dp"
- android:layout_marginTop="24dp"
- android:paddingLeft="8dp"
- android:textColor="@color/dark_blue"
- android:textSize="@dimen/text_size_large"
- android:textStyle="bold" />
+ android:layout_height="match_parent" >
- <ImageButton
- android:id="@+id/butAction"
- android:layout_width="48dp"
- android:layout_height="match_parent"
- android:layout_alignParentBottom="true"
- android:layout_alignParentRight="true"
- android:background="?attr/borderless_button"
- android:clickable="false"
- android:focusable="false"
- android:focusableInTouchMode="false"
- android:paddingLeft="24dp"
- android:paddingRight="8dp"
- android:paddingTop="16dp"
- android:scaleType="fitEnd"
- android:src="?attr/spinner_button" />
+ <TextView
+ android:id="@+id/txtvHeaderTitle"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:layout_alignParentLeft="true"
+ android:layout_centerVertical="true"
+ android:layout_marginBottom="24dp"
+ android:layout_marginLeft="28dp"
+ android:layout_marginRight="16dp"
+ android:layout_marginTop="24dp"
+ android:paddingLeft="8dp"
+ android:textAllCaps="true"
+ android:textColor="@color/dark_blue"
+ android:textSize="@dimen/text_size_large"
+ android:typeface="sans" />
-</RelativeLayout> \ No newline at end of file
+ <ImageButton
+ android:id="@+id/butAction"
+ android:layout_width="48dp"
+ android:layout_height="match_parent"
+ android:layout_alignParentBottom="true"
+ android:layout_alignParentRight="true"
+ android:background="?attr/borderless_button"
+ android:clickable="false"
+ android:focusable="false"
+ android:focusableInTouchMode="false"
+ android:paddingLeft="24dp"
+ android:paddingRight="8dp"
+ android:paddingTop="16dp"
+ android:scaleType="fitEnd"
+ android:src="?attr/spinner_button" />
+ </RelativeLayout>
+
+</LinearLayout> \ No newline at end of file
diff --git a/res/values/dimens.xml b/res/values/dimens.xml
index a74ccf1a9..3b7e7475a 100644
--- a/res/values/dimens.xml
+++ b/res/values/dimens.xml
@@ -11,5 +11,5 @@
<dimen name="text_size_medium">18sp</dimen>
<dimen name="text_size_large">22sp</dimen>
<dimen name="status_indicator_width">36dp</dimen>
- <dimen name="thumbnail_length_itemlist">70dp</dimen>
+ <dimen name="thumbnail_length_itemlist">80dp</dimen>
</resources> \ No newline at end of file
diff --git a/src/de/danoeh/antennapod/adapter/ExternalEpisodesListAdapter.java b/src/de/danoeh/antennapod/adapter/ExternalEpisodesListAdapter.java
index 9989fb283..cde21895f 100644
--- a/src/de/danoeh/antennapod/adapter/ExternalEpisodesListAdapter.java
+++ b/src/de/danoeh/antennapod/adapter/ExternalEpisodesListAdapter.java
@@ -231,7 +231,7 @@ public class ExternalEpisodesListAdapter extends BaseExpandableListAdapter {
TextView headerTitle = (TextView) convertView
.findViewById(R.id.txtvHeaderTitle);
ImageButton actionButton = (ImageButton) convertView
- .findViewById(R.id.butAction);
+ .findViewById(R.id.butAction);
String headerString = null;
if (groupPosition == 0) {
headerString = context.getString(R.string.queue_label);