https://github.com/AriaLyy/Aria/issues/610 https://github.com/AriaLyy/Aria/issues/614
This commit is contained in:
@@ -9,7 +9,7 @@
|
||||
<!--设置Aria的日志级别,{@link ALog#LOG_LEVEL_VERBOSE}-->
|
||||
<logLevel value="2"/>
|
||||
<!-- 是否检查网络 true: 检查网络,false: 不检查网络-->
|
||||
<netCheck value="false"/>
|
||||
<netCheck value="true"/>
|
||||
<!--除非无法使用注解,否则不建议使用广播来接受任务状态,true:使用广播接收任务状态,false:不适用广播接收状态 -->
|
||||
<!-- http://aria.laoyuyu.me/aria_doc/api/use_broadcast.html -->
|
||||
<useBroadcast value="false"/>
|
||||
|
||||
@@ -59,6 +59,7 @@ public class HttpDownloadModule extends BaseViewModule {
|
||||
//String url = "https://ss1.baidu.com/-4o3dSag_xI4khGko9WTAnF6hhy/image/h%3D300/sign=a9e671b9a551f3dedcb2bf64a4eff0ec/4610b912c8fcc3cef70d70409845d688d53f20f7.jpg";
|
||||
//String filePath = AppUtil.getConfigValue(context, HTTP_PATH_KEY, defFilePath);
|
||||
String url = "https://y.qq.com/download/import/QQMusic-import-1.2.1.zip";
|
||||
//String url = "http://donuts.aigauss.com/doc_fPhW2DBGj3_1578932414.png";
|
||||
String filePath = "/mnt/sdcard/update.zip";
|
||||
//String url = "https://dhfspace.360drm.com/1_12809_1543904946_VID_20180808_212829.vep?e=1578554567&token=gUBmfZgZS5wy4wdQIDZG8UVxlNCyVSjvksIb13K5:WYSZRgmLbH1_9hjgqOAGmqR27JM=";
|
||||
//String filePath = "/mnt/sdcard/sssss.zip";
|
||||
@@ -67,7 +68,7 @@ public class HttpDownloadModule extends BaseViewModule {
|
||||
if (singDownloadInfo == null) {
|
||||
singDownloadInfo = new DownloadEntity();
|
||||
singDownloadInfo.setUrl(url);
|
||||
File file = new File(defFilePath);
|
||||
File file = new File(filePath);
|
||||
singDownloadInfo.setFilePath(filePath);
|
||||
singDownloadInfo.setFileName(file.getName());
|
||||
} else {
|
||||
|
||||
@@ -269,7 +269,7 @@ public class M3U8VodDLoadActivity extends BaseActivity<ActivityM3u8VodBinding> {
|
||||
|
||||
@Download.onTaskFail
|
||||
void taskFail(DownloadTask task, Exception e) {
|
||||
if (task.getKey().equals(mUrl)) {
|
||||
if (task != null && task.getKey().equals(mUrl)) {
|
||||
Toast.makeText(M3U8VodDLoadActivity.this, getString(R.string.download_fail),
|
||||
Toast.LENGTH_SHORT)
|
||||
.show();
|
||||
@@ -330,7 +330,7 @@ public class M3U8VodDLoadActivity extends BaseActivity<ActivityM3u8VodBinding> {
|
||||
//String parentUrl = "http://" + uri.getHost() + "/gear1/";
|
||||
int index = m3u8Url.lastIndexOf("/");
|
||||
//String parentUrl = m3u8Url.substring(0, index + 1);
|
||||
String parentUrl = "https://cn7.kankia.com/";
|
||||
String parentUrl = "https://135zyv5.xw0371.com/2018/10/29/X05c7CG3VB91gi1M/";
|
||||
//String parentUrl = "http://" + uri.getHost() + "/";
|
||||
List<String> newUrls = new ArrayList<>();
|
||||
for (String url : tsUrls) {
|
||||
|
||||
@@ -35,9 +35,10 @@ public class M3U8VodModule extends BaseViewModule {
|
||||
//private final String defUrl = "https://www.gaoya123.cn/2019/1557993797897.m3u8";
|
||||
// 多码率地址:
|
||||
//private final String defUrl = "http://devimages.apple.com/iphone/samples/bipbop/bipbopall.m3u8";
|
||||
private final String defUrl = "https://cn7.kankia.com/hls/20200108/e1eaec074274c64fe46a3bdb5d2ba487/1578488360/index.m3u8";
|
||||
//private final String defUrl = "https://cn7.kankia.com/hls/20200108/e1eaec074274c64fe46a3bdb5d2ba487/1578488360/index.m3u8";
|
||||
//private final String defUrl = "https://youku.cdn7-okzy.com/20191213/16167_c3592a02/index.m3u8";
|
||||
//private final String defUrl = "http://qn.shytong.cn/b83137769ff6b555/11b0c9970f9a3fa0.mp4.m3u8";
|
||||
private final String defUrl = "https://135zyv5.xw0371.com/2018/10/29/X05c7CG3VB91gi1M/playlist.m3u8";
|
||||
private final String filePath =
|
||||
Environment.getExternalStoragePublicDirectory(Environment.DIRECTORY_DOWNLOADS).getPath()
|
||||
//+ "/道士下山.ts";
|
||||
|
||||
Reference in New Issue
Block a user