Use async task to generate intent when user tapping on Download Home |
||
Issue descriptionCurrently in DownloadUtils.openFile(), we remove the StrictMode violation when user tapping on a download item. We should investigate whether this can be done through an AsyncTask.
,
Apr 7 2017
We open the downloaded file in direct response to a user request, so we made an intentional decision to allow the strict mode violation rather than queue up an AsyncTask. If we queue a task, the file will open at some unspecified point in the future rather than immediately. This is documented in the DownloadUtils#getUriForItem(): // #getContentUriFromFile causes a disk read when it calls into FileProvider#getUriForFile. // Obtaining a content URI is on the critical path for creating a share intent after the // user taps on the share button, so even if we were to run this method on a background // thread we would have to wait. As it depends on user-selected items, we cannot // know/preload which URIs we need until the user presses share.
,
Apr 9 2018
Issue has not been modified or commented on in the last 365 days, please re-open or file a new bug if this is still an issue. For more details visit https://www.chromium.org/issue-tracking/autotriage - Your friendly Sheriffbot |
||
►
Sign in to add a comment |
||
Comment 1 by dfalcant...@chromium.org
, Apr 7 2017Owner: dtrainor@chromium.org