diff --git a/OsmAnd/src/net/osmand/plus/activities/FavoritesListFragment.java b/OsmAnd/src/net/osmand/plus/activities/FavoritesListFragment.java index 28c902914e..40e1260160 100644 --- a/OsmAnd/src/net/osmand/plus/activities/FavoritesListFragment.java +++ b/OsmAnd/src/net/osmand/plus/activities/FavoritesListFragment.java @@ -182,6 +182,13 @@ public class FavoritesListFragment extends ListFragment implements SearchActivit TextView label = (TextView) row.findViewById(R.id.favourite_label); ImageView icon = (ImageView) row.findViewById(R.id.favourite_icon); final FavouritePoint model = getItem(position); + if (!model.getCategory().isEmpty()){ + row.findViewById(R.id.group_image).setVisibility(View.VISIBLE); + } else { + row.findViewById(R.id.group_image).setVisibility(View.GONE); + } + ((TextView) row.findViewById(R.id.group_name)).setText(model.getCategory()); + icon.setImageDrawable(FavoriteImageDrawable.getOrCreate(activity, model.getColor())); String distance = ""; if (location != null) { diff --git a/OsmAnd/src/net/osmand/plus/download/DownloadIndexAdapter.java b/OsmAnd/src/net/osmand/plus/download/DownloadIndexAdapter.java index 59b0a0a440..a46bff46a0 100644 --- a/OsmAnd/src/net/osmand/plus/download/DownloadIndexAdapter.java +++ b/OsmAnd/src/net/osmand/plus/download/DownloadIndexAdapter.java @@ -250,7 +250,6 @@ public class DownloadIndexAdapter extends OsmandBaseExpandableListAdapter implem }); if (indexFileNames != null) { - if (e.isAlreadyDownloaded(indexFileNames)) { if (e.getType() == DownloadActivityType.HILLSHADE_FILE || e.getType() == DownloadActivityType.SRTM_COUNTRY_FILE) { @@ -267,17 +266,19 @@ public class DownloadIndexAdapter extends OsmandBaseExpandableListAdapter implem String sfName = e.getTargetFileName(); final boolean updatableResource = indexActivatedFileNames.containsKey(sfName); if (updatableResource && !DownloadActivity.downloadListIndexThread.checkIfItemOutdated(e)) { - edition.setText(downloadFragment.getResources().getString(R.string.local_index_installed) + " : " - + indexActivatedFileNames.get(sfName)); + description.setText(indexActivatedFileNames.get(sfName) + " " + e.getSizeDescription(clctx)); } else if (indexFileNames.containsKey(sfName) && !DownloadActivity.downloadListIndexThread.checkIfItemOutdated(e)) { - edition.setText(downloadFragment.getResources().getString(R.string.local_index_installed) + " : " - + indexFileNames.get(sfName)); + description.setText(indexFileNames.get(sfName) + " " + e.getSizeDescription(clctx)); } else if (updatableResource) { + String updatedDescr = indexActivatedFileNames.get(sfName) + " " + e.getSizeDescription(clctx); + description.setText(updatedDescr); edition.setText(downloadFragment.getResources().getString(R.string.local_index_installed) + " : " - + indexActivatedFileNames.get(sfName)); + + e.getDate(format)); } else { - edition.setText(name.getText() + "\n" + downloadFragment.getResources().getString(R.string.local_index_installed) + " : " + description.setText(name.getText() + "\n" + downloadFragment.getResources().getString(R.string.local_index_installed) + " : " + indexFileNames.get(sfName)); + edition.setText(downloadFragment.getResources().getString(R.string.local_index_installed) + " : " + + e.getDate(format)); } } }