diff options
author | Android Build Coastguard Worker <android-build-coastguard-worker@google.com> | 2023-12-14 16:37:58 +0000 |
---|---|---|
committer | Android Build Coastguard Worker <android-build-coastguard-worker@google.com> | 2023-12-14 16:37:58 +0000 |
commit | 0885499516034df559ee37cea766857840db713c (patch) | |
tree | f4802065607aaa04531013f3e21c7f4dfdb26a30 | |
parent | b3329371243bfb01868a4306ec400a931a48eacf (diff) | |
parent | 76e5a686c4ff5f075d5c402003a08e344e7f54e3 (diff) | |
download | DownloadProvider-aml_tz4_332714010.tar.gz |
Snap for 11219529 from 76e5a686c4ff5f075d5c402003a08e344e7f54e3 to mainline-tzdata4-releaseaml_tz4_332714070aml_tz4_332714050aml_tz4_332714010aml_tz4_332714010
Change-Id: I5eee1e7f569e558c3579d943cedca2e4e7a3eca8
-rw-r--r-- | res/values-kn/strings.xml | 2 | ||||
-rw-r--r-- | src/com/android/providers/downloads/DownloadStorageProvider.java | 38 | ||||
-rw-r--r-- | ui/res/values-or/strings.xml | 2 |
3 files changed, 14 insertions, 28 deletions
diff --git a/res/values-kn/strings.xml b/res/values-kn/strings.xml index 354b90ac..51956737 100644 --- a/res/values-kn/strings.xml +++ b/res/values-kn/strings.xml @@ -26,7 +26,7 @@ <string name="permdesc_downloadCompletedIntent" msgid="3384693829639860032">"ಪೂರ್ಣಗೊಂಡಿರುವ ಡೌನ್ಲೋಡ್ಗಳ ಕುರಿತು ಅಧಿಸೂಚನೆಗಳನ್ನು ಕಳುಹಿಸಲು ಅಪ್ಲಿಕೇಶನ್ಗೆ ಅನುಮತಿ ನೀಡುತ್ತದೆ. ದುರುದ್ದೇಶಪೂರಿತ ಅಪ್ಲಿಕೇಶನ್ಗಳು, ಡೌನ್ಲೋಡ್ ಮಾಡುವ ಇತರ ಅಪ್ಲಿಕೇಶನ್ಗಳಲ್ಲಿ ಗೊಂದಲವುಂಟು ಮಾಡಲೋಸುಗ ಇದನ್ನು ಬಳಸಿಕೊಳ್ಳಬಹುದು."</string> <string name="permlab_downloadCacheNonPurgeable" msgid="4538031250425141333">"ಡೌನ್ಲೋಡ್ ಕ್ಯಾಷ್ನಲ್ಲಿ ಸ್ಥಳವನ್ನು ಮೀಸಲಿರಿಸಿ"</string> <string name="permdesc_downloadCacheNonPurgeable" msgid="3071381088686444674">"ಡೌನ್ಲೊಡ್ ನಿರ್ವಾಹಕಕ್ಕೆ ಹೆಚ್ಚಿನ ಸ್ಥಳಾವಕಾಶದ ಅಗತ್ಯವಿರುವ ಸಂದರ್ಭದಲ್ಲಿ ಸ್ವಯಂಚಾಲಿತವಾಗಿ ಅಳಿಸಲಾಗದಿರುವ ಫೈಲ್ಗಳನ್ನು ಡೌನ್ಲೋಡ್ ಕ್ಯಾಷ್ಗೆ ಡೌನ್ಲೋಡ್ ಮಾಡಲು ಅಪ್ಲಿಕೇಶನ್ಗೆ ಅನುಮತಿ ನೀಡಲಾಗುತ್ತದೆ."</string> - <string name="permlab_downloadWithoutNotification" msgid="4877101864770265405">"ಅಧಿಸೂಚನೆ ಇಲ್ಲದೆಯೇ ಫೈಲ್ಗಳನ್ನು ಡೌನ್ಲೋಡ್ ಮಾಡಿ"</string> + <string name="permlab_downloadWithoutNotification" msgid="4877101864770265405">"ನೋಟಿಫಿಕೇಶನ್ ಇಲ್ಲದೆಯೇ ಫೈಲ್ಗಳನ್ನು ಡೌನ್ಲೋಡ್ ಮಾಡಿ"</string> <string name="permdesc_downloadWithoutNotification" msgid="7699189763226483523">"ಯಾವುದೇ ಅಧಿಸೂಚನೆಯನ್ನು ಬಳಕೆದಾರರಿಗೆ ತೋರಿಸದೇ ಡೌನ್ಲೋಡ್ ನಿರ್ವಾಹಕದ ಮೂಲಕ ಫೈಲ್ಗಳನ್ನು ಡೌನ್ಲೋಡ್ ಮಾಡಲು ಅಪ್ಲಿಕೇಶನ್ಗೆ ಅನುಮತಿ ನೀಡುತ್ತದೆ."</string> <string name="permlab_accessAllDownloads" msgid="8227356876527248611">"ಎಲ್ಲ ಸಿಸ್ಟಂನ ಡೌನ್ಲೋಡ್ಗಳನ್ನು ಪ್ರವೇಶಿಸಿ"</string> <string name="permdesc_accessAllDownloads" msgid="7541731738152145079">"ಸಿಸ್ಟಂನಲ್ಲಿ ಯಾವುದೇ ಅಪ್ಲಿಕೇಶನ್ ಮೂಲಕ ಆರಂಭಿಸಲಾದ ಎಲ್ಲ ಡೌನ್ಲೋಡ್ಗಳನ್ನು ವೀಕ್ಷಿಸಲು ಮತ್ತು ಮಾರ್ಪಡಿಸಲು ಅಪ್ಲಿಕೇಶನ್ಗೆ ಅನುಮತಿ ನೀಡಲಾಗುತ್ತದೆ."</string> diff --git a/src/com/android/providers/downloads/DownloadStorageProvider.java b/src/com/android/providers/downloads/DownloadStorageProvider.java index 421c2613..f5ba1e5d 100644 --- a/src/com/android/providers/downloads/DownloadStorageProvider.java +++ b/src/com/android/providers/downloads/DownloadStorageProvider.java @@ -307,39 +307,26 @@ public class DownloadStorageProvider extends FileSystemProvider { } @Override - public Cursor queryChildDocuments(String parentDocId, String[] projection, String sortOrder) - throws FileNotFoundException { - return queryChildDocuments(parentDocId, projection, sortOrder, false); - } - - @Override - public Cursor queryChildDocumentsForManage( - String parentDocId, String[] projection, String sortOrder) - throws FileNotFoundException { - return queryChildDocuments(parentDocId, projection, sortOrder, true); - } - - private Cursor queryChildDocuments(String parentDocId, String[] projection, - String sortOrder, boolean manage) throws FileNotFoundException { - + protected Cursor queryChildDocuments(String documentId, String[] projection, String sortOrder, + boolean includeHidden) throws FileNotFoundException { // Delegate to real provider final long token = Binder.clearCallingIdentity(); Cursor cursor = null; try { - if (RawDocumentsHelper.isRawDocId(parentDocId)) { - return super.queryChildDocuments(parentDocId, projection, sortOrder); + if (RawDocumentsHelper.isRawDocId(documentId)) { + return super.queryChildDocuments(documentId, projection, sortOrder, includeHidden); } final DownloadsCursor result = new DownloadsCursor(projection, getContext().getContentResolver()); final ArrayList<Uri> notificationUris = new ArrayList<>(); - if (isMediaStoreDownloadDir(parentDocId)) { + if (isMediaStoreDownloadDir(documentId)) { includeDownloadsFromMediaStore(result, null /* queryArgs */, null /* filePaths */, notificationUris, - getMediaStoreIdString(parentDocId), NO_LIMIT, manage); + getMediaStoreIdString(documentId), NO_LIMIT, includeHidden); } else { - assert (DOC_ID_ROOT.equals(parentDocId)); - if (manage) { + assert (DOC_ID_ROOT.equals(documentId)); + if (includeHidden) { cursor = mDm.query( new DownloadManager.Query().setOnlyIncludeVisibleInDownloadsUi(true)); } else { @@ -354,7 +341,7 @@ public class DownloadStorageProvider extends FileSystemProvider { notificationUris.add(cursor.getNotificationUri()); includeDownloadsFromMediaStore(result, null /* queryArgs */, filePaths, notificationUris, - null /* parentId */, NO_LIMIT, manage); + null /* parentId */, NO_LIMIT, includeHidden); includeFilesFromSharedStorage(result, filePaths, null); } result.setNotificationUris(getContext().getContentResolver(), notificationUris); @@ -476,12 +463,11 @@ public class DownloadStorageProvider extends FileSystemProvider { return result; } - private void includeSearchFilesFromSharedStorage(DownloadsCursor result, - String[] projection, Set<String> filePaths, - Bundle queryArgs) throws FileNotFoundException { + private void includeSearchFilesFromSharedStorage(DownloadsCursor result, String[] projection, + Set<String> filePaths, Bundle queryArgs) throws FileNotFoundException { final File downloadDir = getPublicDownloadsDirectory(); try (Cursor rawFilesCursor = super.querySearchDocuments(downloadDir, - projection, filePaths, queryArgs)) { + projection, /* exclusion */ filePaths, queryArgs)) { final boolean shouldExcludeMedia = queryArgs.getBoolean( DocumentsContract.QUERY_ARG_EXCLUDE_MEDIA, false /* defaultValue */); diff --git a/ui/res/values-or/strings.xml b/ui/res/values-or/strings.xml index e89215cf..7a962de1 100644 --- a/ui/res/values-or/strings.xml +++ b/ui/res/values-or/strings.xml @@ -19,7 +19,7 @@ <string name="app_label" msgid="4847371117203587513">"ଡାଉନଲୋଡ୍"</string> <string name="download_title_sorted_by_date" msgid="6033509257480233878">"ଡାଉନଲୋଡ୍ - ତାରିଖ ଅନୁସାରେ କ୍ରମବଦ୍ଧ"</string> <string name="download_title_sorted_by_size" msgid="2575551670173644253">"ଡାଉନଲୋଡ୍ - ଆକାର ଅନୁସାରେ କ୍ରମବଦ୍ଧ"</string> - <string name="no_downloads" msgid="1654764193290918538">"କୌଣସି ଡାଉନଲୋଡ୍ ନାହିଁ।"</string> + <string name="no_downloads" msgid="1654764193290918538">"କୌଣସି ଡାଉନଲୋଡ ହୋଇନାହିଁ।"</string> <string name="missing_title" msgid="3827247802608803753">"<ଅଜଣା>"</string> <string name="button_sort_by_size" msgid="7952187121189086395">"ଆକାର ଅନୁସାରେ କ୍ରମବଦ୍ଧ କରନ୍ତୁ"</string> <string name="button_sort_by_date" msgid="2064919145709585942">"ତାରିଖ ଅନୁସାରେ କ୍ରମବଦ୍ଧ କରନ୍ତୁ"</string> |