mirror of https://github.com/readrops/Readrops.git
Fix feed name color when no color is available
This commit is contained in:
parent
76aef3916a
commit
b53463b2d4
|
@ -103,10 +103,13 @@ public class MainItemListAdapter extends ListAdapter<ItemWithFeed, MainItemListA
|
||||||
} else
|
} else
|
||||||
viewHolder.feedIcon.setImageResource(R.drawable.ic_rss_feed);
|
viewHolder.feedIcon.setImageResource(R.drawable.ic_rss_feed);
|
||||||
|
|
||||||
|
Resources resources = viewHolder.itemView.getResources();
|
||||||
if (itemWithFeed.getColor() != 0)
|
if (itemWithFeed.getColor() != 0)
|
||||||
viewHolder.feedName.setTextColor(itemWithFeed.getColor());
|
viewHolder.feedName.setTextColor(itemWithFeed.getColor());
|
||||||
|
else
|
||||||
|
viewHolder.feedName.setTextColor(resources.getColor(android.R.color.tab_indicator_text));
|
||||||
|
|
||||||
|
|
||||||
Resources resources = viewHolder.itemView.getResources();
|
|
||||||
int minutes = (int)Math.round(itemWithFeed.getItem().getReadTime());
|
int minutes = (int)Math.round(itemWithFeed.getItem().getReadTime());
|
||||||
if (minutes < 1)
|
if (minutes < 1)
|
||||||
viewHolder.itemReadTime.setText(resources.getString(R.string.read_time_lower_than_1));
|
viewHolder.itemReadTime.setText(resources.getString(R.string.read_time_lower_than_1));
|
||||||
|
|
Loading…
Reference in New Issue