diff options
author | Andrew Dolgov <[email protected]> | 2014-10-16 13:53:44 +0400 |
---|---|---|
committer | Andrew Dolgov <[email protected]> | 2014-10-16 13:53:44 +0400 |
commit | 811bc035c0935d321b2cad085853580e44888f62 (patch) | |
tree | 0ba39359f2cf17e5577bed2ace480f776277b8ea /res | |
parent | 636ddc362369c7658ea40bb3f9e488db902f6408 (diff) |
use viewholder for headlines view
automatically enlarge flavor image
Diffstat (limited to 'res')
-rw-r--r-- | res/layout/headlines_row.xml | 12 | ||||
-rw-r--r-- | res/layout/headlines_row_selected.xml | 12 | ||||
-rw-r--r-- | res/layout/headlines_row_selected_unread.xml | 12 | ||||
-rw-r--r-- | res/layout/headlines_row_unread.xml | 16 |
4 files changed, 22 insertions, 30 deletions
diff --git a/res/layout/headlines_row.xml b/res/layout/headlines_row.xml index 8902a6bc..77233430 100644 --- a/res/layout/headlines_row.xml +++ b/res/layout/headlines_row.xml @@ -81,18 +81,16 @@ android:layout_gravity="center"
android:layout_height="wrap_content" >
- <ImageView
+ <org.fox.ttrss.util.EnlargingImageView
android:id="@+id/flavor_image"
- android:layout_width="wrap_content"
+ android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:adjustViewBounds="true"
android:background="@drawable/flavor_image_border"
- android:cropToPadding="true"
- android:maxHeight="256dp"
- android:padding="1dp"
- android:scaleType="centerInside"
- android:src="@null"
+ android:scaleType="fitCenter"
+ android:cropToPadding="true"
+ android:padding="2dp"
android:visibility="gone" />
</FrameLayout>
diff --git a/res/layout/headlines_row_selected.xml b/res/layout/headlines_row_selected.xml index 0e600daa..b8c4516a 100644 --- a/res/layout/headlines_row_selected.xml +++ b/res/layout/headlines_row_selected.xml @@ -79,18 +79,16 @@ android:layout_gravity="center"
android:layout_height="wrap_content" >
- <ImageView
+ <org.fox.ttrss.util.EnlargingImageView
android:id="@+id/flavor_image"
- android:layout_width="wrap_content"
+ android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:adjustViewBounds="true"
android:background="@drawable/flavor_image_border"
- android:cropToPadding="true"
- android:maxHeight="256dp"
- android:padding="1dp"
- android:scaleType="centerInside"
- android:src="@null"
+ android:scaleType="fitCenter"
+ android:cropToPadding="true"
+ android:padding="2dp"
android:visibility="gone" />
</FrameLayout>
diff --git a/res/layout/headlines_row_selected_unread.xml b/res/layout/headlines_row_selected_unread.xml index 5e4f7eeb..927793c8 100644 --- a/res/layout/headlines_row_selected_unread.xml +++ b/res/layout/headlines_row_selected_unread.xml @@ -80,18 +80,16 @@ android:layout_gravity="center"
android:layout_height="wrap_content" >
- <ImageView
+ <org.fox.ttrss.util.EnlargingImageView
android:id="@+id/flavor_image"
- android:layout_width="wrap_content"
+ android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:adjustViewBounds="true"
android:background="@drawable/flavor_image_border"
- android:cropToPadding="true"
- android:maxHeight="256dp"
- android:padding="1dp"
- android:scaleType="centerInside"
- android:src="@null"
+ android:scaleType="fitCenter"
+ android:cropToPadding="true"
+ android:padding="2dp"
android:visibility="gone" />
</FrameLayout>
diff --git a/res/layout/headlines_row_unread.xml b/res/layout/headlines_row_unread.xml index 96a65134..107056b9 100644 --- a/res/layout/headlines_row_unread.xml +++ b/res/layout/headlines_row_unread.xml @@ -76,21 +76,19 @@ <FrameLayout
android:id="@+id/flavorImageHolder"
android:layout_width="match_parent"
- android:layout_height="wrap_content"
- android:paddingTop="3dp" >
+ android:layout_height="wrap_content"
+ android:padding="10dp" >
- <ImageView
+ <org.fox.ttrss.util.EnlargingImageView
android:id="@+id/flavor_image"
- android:layout_width="wrap_content"
+ android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:adjustViewBounds="true"
android:background="@drawable/flavor_image_border"
- android:cropToPadding="true"
- android:maxHeight="256dp"
- android:padding="1dp"
- android:scaleType="centerInside"
- android:src="@null"
+ android:scaleType="fitCenter"
+ android:cropToPadding="true"
+ android:padding="2dp"
android:visibility="gone" />
</FrameLayout>
|