From 71a0ae449264321f67693a99d3f1c3ee1ab3fb0e Mon Sep 17 00:00:00 2001 From: AriaLyy <511455842@qq.com> Date: Thu, 13 Jul 2017 21:14:18 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8Dwait=20=E6=A8=A1=E5=BC=8F?= =?UTF-8?q?=E7=9A=84bug?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../java/com/arialyy/aria/core/command/normal/StartCmd.java | 5 ++--- .../aria/core/download/downloader/FileInfoThread.java | 6 ------ .../java/com/arialyy/simple/download/group/GroupModule.java | 4 ++-- 3 files changed, 4 insertions(+), 11 deletions(-) diff --git a/Aria/src/main/java/com/arialyy/aria/core/command/normal/StartCmd.java b/Aria/src/main/java/com/arialyy/aria/core/command/normal/StartCmd.java index 2b042a27..c8f81cb1 100644 --- a/Aria/src/main/java/com/arialyy/aria/core/command/normal/StartCmd.java +++ b/Aria/src/main/java/com/arialyy/aria/core/command/normal/StartCmd.java @@ -63,9 +63,8 @@ class StartCmd extends AbsNormalCmd { } } else { // 任务不存在时,根据配置不同,对任务执行操作 - if (!task.isRunning() - && mod.equals(QueueMod.WAIT.getTag()) - && task.getState() == IEntity.STATE_WAIT) { + if (!task.isRunning() && mod.equals(QueueMod.WAIT.getTag()) && (task.getState() + == IEntity.STATE_WAIT || task.getState() == IEntity.STATE_STOP)) { mQueue.startTask(task); } } diff --git a/Aria/src/main/java/com/arialyy/aria/core/download/downloader/FileInfoThread.java b/Aria/src/main/java/com/arialyy/aria/core/download/downloader/FileInfoThread.java index ab6dd7f1..90bb447c 100644 --- a/Aria/src/main/java/com/arialyy/aria/core/download/downloader/FileInfoThread.java +++ b/Aria/src/main/java/com/arialyy/aria/core/download/downloader/FileInfoThread.java @@ -25,8 +25,6 @@ import java.io.IOException; import java.net.HttpURLConnection; import java.net.URL; import java.net.URLDecoder; -import java.util.List; -import java.util.Map; /** * 下载文件信息获取 @@ -54,10 +52,6 @@ class FileInfoThread implements Runnable { void onFail(String url, String errorMsg); } - FileInfoThread(DownloadTaskEntity taskEntity) { - this(taskEntity, null); - } - FileInfoThread(DownloadTaskEntity taskEntity, OnFileInfoCallback callback) { this.mTaskEntity = taskEntity; mEntity = taskEntity.getEntity(); diff --git a/app/src/main/java/com/arialyy/simple/download/group/GroupModule.java b/app/src/main/java/com/arialyy/simple/download/group/GroupModule.java index c1f66b8d..ed98dff3 100644 --- a/app/src/main/java/com/arialyy/simple/download/group/GroupModule.java +++ b/app/src/main/java/com/arialyy/simple/download/group/GroupModule.java @@ -32,8 +32,8 @@ public class GroupModule extends BaseModule { List getUrls() { List urls = new ArrayList<>(); - //String[] str = getContext().getResources().getStringArray(R.array.download_url); - String[] str = getContext().getResources().getStringArray(R.array.group_urls); + String[] str = getContext().getResources().getStringArray(R.array.download_url); + //String[] str = getContext().getResources().getStringArray(R.array.group_urls); Collections.addAll(urls, str); return urls; }