From dfe8a3e03dd5f36409a036d24a2c72301df8accc Mon Sep 17 00:00:00 2001 From: Alex Sytnyk Date: Wed, 11 Apr 2018 17:28:41 +0300 Subject: [PATCH] Add icon to wikivoyage saved articles list --- OsmAnd/res/layout/wikivoyage_article_card.xml | 4 +++- .../explore/SavedArticlesRvAdapter.java | 19 ++++++++++++++++++- 2 files changed, 21 insertions(+), 2 deletions(-) diff --git a/OsmAnd/res/layout/wikivoyage_article_card.xml b/OsmAnd/res/layout/wikivoyage_article_card.xml index 772d8fbd96..768a7b0a1e 100644 --- a/OsmAnd/res/layout/wikivoyage_article_card.xml +++ b/OsmAnd/res/layout/wikivoyage_article_card.xml @@ -60,8 +60,10 @@ android:layout_gravity="center_vertical" android:layout_marginLeft="@dimen/content_padding" android:layout_marginStart="@dimen/content_padding" + android:visibility="gone" tools:ignore="ContentDescription" - tools:src="@drawable/ic_empty_state_marker_history_night"/> + tools:src="@drawable/ic_empty_state_marker_history_night" + tools:visibility="visible"/> diff --git a/OsmAnd/src/net/osmand/plus/wikivoyage/explore/SavedArticlesRvAdapter.java b/OsmAnd/src/net/osmand/plus/wikivoyage/explore/SavedArticlesRvAdapter.java index 2c1bb0709c..797e64cda9 100644 --- a/OsmAnd/src/net/osmand/plus/wikivoyage/explore/SavedArticlesRvAdapter.java +++ b/OsmAnd/src/net/osmand/plus/wikivoyage/explore/SavedArticlesRvAdapter.java @@ -11,10 +11,14 @@ import android.view.ViewGroup; import android.widget.ImageView; import android.widget.TextView; +import com.squareup.picasso.Callback; +import com.squareup.picasso.Picasso; + import net.osmand.AndroidUtils; import net.osmand.plus.IconsCache; import net.osmand.plus.OsmandApplication; import net.osmand.plus.R; +import net.osmand.plus.widgets.tools.CropCircleTransformation; import net.osmand.plus.wikivoyage.data.WikivoyageArticle; import net.osmand.plus.wikivoyage.data.WikivoyageLocalDataHelper; @@ -68,10 +72,23 @@ public class SavedArticlesRvAdapter extends RecyclerView.Adapter