Download Log: Show retry button icon
This commit is contained in:
parent
cc00d03bf0
commit
719075bbf9
|
@ -7,11 +7,11 @@ import android.view.LayoutInflater;
|
|||
import android.view.View;
|
||||
import android.view.ViewGroup;
|
||||
import android.widget.BaseAdapter;
|
||||
import android.widget.Button;
|
||||
import android.widget.TextView;
|
||||
import android.widget.Toast;
|
||||
|
||||
import com.joanzapata.iconify.Iconify;
|
||||
import com.joanzapata.iconify.widget.IconButton;
|
||||
|
||||
import java.util.Date;
|
||||
|
||||
|
@ -50,7 +50,7 @@ public class DownloadLogAdapter extends BaseAdapter {
|
|||
.getSystemService(Context.LAYOUT_INFLATER_SERVICE);
|
||||
convertView = inflater.inflate(R.layout.downloadlog_item, parent, false);
|
||||
holder.icon = (TextView) convertView.findViewById(R.id.txtvIcon);
|
||||
holder.retry = (Button) convertView.findViewById(R.id.btnRetry);
|
||||
holder.retry = (IconButton) convertView.findViewById(R.id.btnRetry);
|
||||
holder.date = (TextView) convertView.findViewById(R.id.txtvDate);
|
||||
holder.title = (TextView) convertView.findViewById(R.id.txtvTitle);
|
||||
holder.type = (TextView) convertView.findViewById(R.id.txtvType);
|
||||
|
@ -96,8 +96,6 @@ public class DownloadLogAdapter extends BaseAdapter {
|
|||
if(status.getFeedfileType() != FeedImage.FEEDFILETYPE_FEEDIMAGE &&
|
||||
!newerWasSuccessful(position, status.getFeedfileType(), status.getFeedfileId())) {
|
||||
holder.retry.setVisibility(View.VISIBLE);
|
||||
holder.retry.setText("{fa-repeat}");
|
||||
Iconify.addIcons(holder.retry);
|
||||
holder.retry.setOnClickListener(clickListener);
|
||||
ButtonHolder btnHolder;
|
||||
if(holder.retry.getTag() != null) {
|
||||
|
@ -161,7 +159,7 @@ public class DownloadLogAdapter extends BaseAdapter {
|
|||
|
||||
static class Holder {
|
||||
TextView icon;
|
||||
Button retry;
|
||||
IconButton retry;
|
||||
TextView title;
|
||||
TextView type;
|
||||
TextView date;
|
||||
|
|
|
@ -20,7 +20,7 @@
|
|||
tools:text="[Icon]"
|
||||
android:gravity="center" />
|
||||
|
||||
<Button
|
||||
<com.joanzapata.iconify.widget.IconButton
|
||||
android:id="@+id/btnRetry"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
|
@ -28,6 +28,7 @@
|
|||
android:layout_alignLeft="@id/txtvIcon"
|
||||
android:layout_alignRight="@id/txtvIcon"
|
||||
android:layout_marginTop="8dp"
|
||||
android:text="{fa-repeat}"
|
||||
tools:text="↻" />
|
||||
|
||||
<TextView
|
||||
|
|
Loading…
Reference in New Issue