summaryrefslogtreecommitdiff
path: root/src/de/danoeh/antennapod/asynctask
diff options
context:
space:
mode:
authordaniel oeh <daniel.oeh@gmail.com>2012-09-21 12:33:55 +0200
committerdaniel oeh <daniel.oeh@gmail.com>2012-09-21 12:33:55 +0200
commit0459f9129976d8628878b09078e404eeaa2127ec (patch)
tree2f91931b15413b77d3913d0b81618f477c2c31ec /src/de/danoeh/antennapod/asynctask
parentb2aed41e8ce8094e741950256459951a59a92bae (diff)
downloadAntennaPod-0459f9129976d8628878b09078e404eeaa2127ec.zip
Excluded cancelled downloads from the download service report and the
download log
Diffstat (limited to 'src/de/danoeh/antennapod/asynctask')
-rw-r--r--src/de/danoeh/antennapod/asynctask/DownloadStatus.java18
1 files changed, 14 insertions, 4 deletions
diff --git a/src/de/danoeh/antennapod/asynctask/DownloadStatus.java b/src/de/danoeh/antennapod/asynctask/DownloadStatus.java
index 3ec5344a0..3d63026eb 100644
--- a/src/de/danoeh/antennapod/asynctask/DownloadStatus.java
+++ b/src/de/danoeh/antennapod/asynctask/DownloadStatus.java
@@ -51,6 +51,7 @@ public class DownloadStatus {
protected long size;
protected int statusMsg;
protected boolean done;
+ protected boolean cancelled;
public DownloadStatus(FeedFile feedfile, String title) {
this.feedfile = feedfile;
@@ -58,9 +59,9 @@ public class DownloadStatus {
}
/** Constructor for restoring Download status entries from DB. */
- public DownloadStatus(long id, String title, FeedFile feedfile, int feedfileType,
- boolean successful, int reason, Date completionDate,
- String reasonDetailed) {
+ public DownloadStatus(long id, String title, FeedFile feedfile,
+ int feedfileType, boolean successful, int reason,
+ Date completionDate, String reasonDetailed) {
progressPercent = 100;
soFar = 0;
size = 0;
@@ -79,7 +80,8 @@ public class DownloadStatus {
/** Constructor for creating new completed downloads. */
public DownloadStatus(FeedFile feedfile, String title, int reason,
boolean successful, String reasonDetailed) {
- this(0, title, feedfile, feedfile.getTypeAsInt(), successful, reason, new Date(), reasonDetailed);
+ this(0, title, feedfile, feedfile.getTypeAsInt(), successful, reason,
+ new Date(), reasonDetailed);
}
public FeedFile getFeedFile() {
@@ -174,4 +176,12 @@ public class DownloadStatus {
return feedfileType;
}
+ public boolean isCancelled() {
+ return cancelled;
+ }
+
+ public void setCancelled(boolean cancelled) {
+ this.cancelled = cancelled;
+ }
+
} \ No newline at end of file