Set download status message to 'pending' while it's not being

downloaded.
This commit is contained in:
daniel oeh 2012-10-23 10:26:34 +02:00
parent 0884b0bf80
commit 7106fdcdab
2 changed files with 2 additions and 1 deletions

View File

@ -1,6 +1,7 @@
package de.danoeh.antennapod.service.download;
import android.os.Handler;
import de.danoeh.antennapod.R;
import de.danoeh.antennapod.asynctask.DownloadStatus;
/** Downloads files */
@ -19,6 +20,7 @@ public abstract class Downloader extends Thread {
super();
this.downloadService = downloadService;
this.status = status;
this.status.setStatusMsg(R.string.download_pending);
this.cancelled = false;
handler = new Handler();
}

View File

@ -37,7 +37,6 @@ public class HttpDownloader extends Downloader {
HttpURLConnection connection = null;
OutputStream out = null;
try {
status.setStatusMsg(R.string.download_pending);
URL url = new URL(status.getFeedFile().getDownload_url());
connection = (HttpURLConnection) url.openConnection();
connection.setConnectTimeout(CONNECTION_TIMEOUT);