diff --git a/mastodon/src/main/java/org/joinmastodon/android/ui/photoviewer/PhotoViewer.java b/mastodon/src/main/java/org/joinmastodon/android/ui/photoviewer/PhotoViewer.java index 1326b3c1..cc4944aa 100644 --- a/mastodon/src/main/java/org/joinmastodon/android/ui/photoviewer/PhotoViewer.java +++ b/mastodon/src/main/java/org/joinmastodon/android/ui/photoviewer/PhotoViewer.java @@ -514,7 +514,11 @@ public class PhotoViewer implements ZoomPanView.Listener{ } private void saveViaDownloadManager(Attachment att){ - DownloadManager.Request req=new DownloadManager.Request(Uri.parse(att.url)); + Uri uri=Uri.parse(att.url); + DownloadManager.Request req=new DownloadManager.Request(uri); + req.allowScanningByMediaScanner(); + req.setNotificationVisibility(DownloadManager.Request.VISIBILITY_VISIBLE_NOTIFY_COMPLETED); + req.setDestinationInExternalPublicDir(Environment.DIRECTORY_DOWNLOADS, uri.getLastPathSegment()); activity.getSystemService(DownloadManager.class).enqueue(req); Toast.makeText(activity, R.string.downloading, Toast.LENGTH_SHORT).show(); }