We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Hi,感谢您的辛苦付出。在onProgress方法中打log显示progress=100,但是此时没有调用onCompleted方法。看到方法中存在synchronized代码块,但是没有分析出来原因。以下是我在onProgress中的规避方法。
// 处理有的数据在progress为100时不调用onComplete方法的问题 if (progress == 100) { if (mDownloadItem == null) { return; } final Long originId = mDownloadItem.getId(); mHandler.postDelayed(new Runnable() { @Override public void run() { // 当前progress为100时,5秒钟后判断当前item是否还是之前的,如果是手动调用onCompleted()。 if (originId != null && mDownloadItem != null && mDownloadItem.getId().equals(originId)) { logger.info("exception data!!! it's still in onProgress 5s,deal it manually"); try { onCompleted(); } catch (RemoteException e) { e.printStackTrace(); } } } }, 5000); }
不知道怎么格式化代码,看着费点儿劲儿- -!
The text was updated successfully, but these errors were encountered:
按正常,progress == 100, onCompleted()方法理应回调。 如果没回调,请查看是不是走了onFailed()或者其他回调方法。
progress == 100
onCompleted()
onFailed()
-ps: 更重要的是,这个库还没有正式发布,请充分了解以后再使用。(意思可能会有未知bug)。
Sorry, something went wrong.
No branches or pull requests
Hi,感谢您的辛苦付出。在onProgress方法中打log显示progress=100,但是此时没有调用onCompleted方法。看到方法中存在synchronized代码块,但是没有分析出来原因。以下是我在onProgress中的规避方法。
不知道怎么格式化代码,看着费点儿劲儿- -!
The text was updated successfully, but these errors were encountered: