race604 / FlyRefresh

The implementation of https://dribbble.com/shots/2067564-Replace

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

solution to resolve "data.time" err

user8361 opened this issue · comments

change data.time ---> data.date.getTime()

public void onBindViewHolder(ItemViewHolder itemViewHolder, int i) {
final ItemData data = mDataSet.get(i);
ShapeDrawable drawable = new ShapeDrawable(new OvalShape());
drawable.getPaint().setColor(data.color);
itemViewHolder.icon.setBackgroundDrawable(drawable);
itemViewHolder.icon.setImageResource(data.icon);
itemViewHolder.title.setText(data.title);
itemViewHolder.subTitle.setText(dateFormat.format(data.date.getTime()));
}