Update small icons

This commit is contained in:
Victor Shcherb 2015-04-10 19:36:46 +02:00
parent 91d9f0fa6c
commit 08ab3b073a
2 changed files with 14 additions and 3 deletions

View file

@ -201,12 +201,14 @@ public class FavoritesListFragment extends ListFragment implements SearchActivit
TextView distanceText = (TextView) row.findViewById(R.id.distance);
ImageView icon = (ImageView) row.findViewById(R.id.favourite_icon);
ImageView direction = (ImageView) row.findViewById(R.id.direction);
ImageView giImage= (ImageView)row.findViewById(R.id.group_image);
direction.setVisibility(View.VISIBLE);
final FavouritePoint favorite = getItem(position);
if (!favorite.getCategory().isEmpty()) {
row.findViewById(R.id.group_image).setVisibility(View.VISIBLE);
giImage.setVisibility(View.VISIBLE);
giImage.setImageDrawable(app.getIconsCache().getContentIcon(R.drawable.ic_small_group));
} else {
row.findViewById(R.id.group_image).setVisibility(View.GONE);
giImage.setVisibility(View.GONE);
}
((TextView) row.findViewById(R.id.group_name)).setText(favorite.getCategory());
@ -216,7 +218,7 @@ public class FavoritesListFragment extends ListFragment implements SearchActivit
name.setText(getName(favorite));
final CheckBox ch = (CheckBox) row.findViewById(R.id.check_item);
row.findViewById(R.id.favourite_icon).setVisibility(View.VISIBLE);
icon.setVisibility(View.VISIBLE);
ch.setVisibility(View.GONE);
return row;
}

View file

@ -1325,6 +1325,15 @@ public class AvailableGPXFragment extends OsmandExpandableListFragment {
} else {
v.findViewById(R.id.read_section).setVisibility(View.VISIBLE);
v.findViewById(R.id.unknown_section).setVisibility(View.GONE);
ImageView distanceI = (ImageView) v.findViewById(R.id.distance_icon);
distanceI.setVisibility(View.VISIBLE);
distanceI.setImageDrawable(app.getIconsCache().getContentIcon(R.drawable.ic_small_distance));
ImageView pointsI = (ImageView) v.findViewById(R.id.points_icon);
pointsI.setVisibility(View.VISIBLE);
pointsI.setImageDrawable(app.getIconsCache().getContentIcon(R.drawable.ic_small_point));
ImageView timeI = (ImageView) v.findViewById(R.id.time_icon);
timeI.setVisibility(View.VISIBLE);
timeI.setImageDrawable(app.getIconsCache().getContentIcon(R.drawable.ic_small_time));
TextView time = (TextView) v.findViewById(R.id.time);
TextView distance = (TextView) v.findViewById(R.id.distance);
TextView pointsCount = (TextView) v.findViewById(R.id.points_count);