From 7427f266a7fb886ec36fd3e02d7436ddca33f97e Mon Sep 17 00:00:00 2001 From: tibbi Date: Fri, 15 Jul 2016 23:07:21 +0200 Subject: [PATCH] properly highlight the items that are going to be deleted --- .../gallery/adapters/MediaAdapter.java | 2 +- app/src/main/res/layout-v21/photo_video_tmb.xml | 7 +++++++ .../{video_item.xml => photo_video_item.xml} | 8 ++------ app/src/main/res/layout/photo_video_tmb.xml | 17 +++++++++++++++++ 4 files changed, 27 insertions(+), 7 deletions(-) create mode 100644 app/src/main/res/layout-v21/photo_video_tmb.xml rename app/src/main/res/layout/{video_item.xml => photo_video_item.xml} (67%) create mode 100644 app/src/main/res/layout/photo_video_tmb.xml diff --git a/app/src/main/java/com/simplemobiletools/gallery/adapters/MediaAdapter.java b/app/src/main/java/com/simplemobiletools/gallery/adapters/MediaAdapter.java index 7a28d8e25..5e811429e 100644 --- a/app/src/main/java/com/simplemobiletools/gallery/adapters/MediaAdapter.java +++ b/app/src/main/java/com/simplemobiletools/gallery/adapters/MediaAdapter.java @@ -33,7 +33,7 @@ public class MediaAdapter extends BaseAdapter { final Medium medium = mMedia.get(position); ViewHolder viewHolder; if (convertView == null) { - convertView = mInflater.inflate(R.layout.video_item, parent, false); + convertView = mInflater.inflate(R.layout.photo_video_item, parent, false); viewHolder = new ViewHolder(convertView); convertView.setTag(viewHolder); } else { diff --git a/app/src/main/res/layout-v21/photo_video_tmb.xml b/app/src/main/res/layout-v21/photo_video_tmb.xml new file mode 100644 index 000000000..4f1627c04 --- /dev/null +++ b/app/src/main/res/layout-v21/photo_video_tmb.xml @@ -0,0 +1,7 @@ + + diff --git a/app/src/main/res/layout/video_item.xml b/app/src/main/res/layout/photo_video_item.xml similarity index 67% rename from app/src/main/res/layout/video_item.xml rename to app/src/main/res/layout/photo_video_item.xml index dbbd17e70..941a6cfa8 100644 --- a/app/src/main/res/layout/video_item.xml +++ b/app/src/main/res/layout/photo_video_item.xml @@ -3,13 +3,9 @@ android:id="@+id/media_item_holder" xmlns:android="http://schemas.android.com/apk/res/android" android:layout_width="match_parent" - android:layout_height="match_parent" - android:foreground="@drawable/selector"> + android:layout_height="match_parent"> - + + + + + + + + +