merge in nyc-release history after reset to nyc-dev
[android/platform/packages/providers/DownloadProvider.git] / AndroidManifest.xml
index 49d0279..8720523 100644 (file)
     <uses-permission android:name="android.permission.UPDATE_DEVICE_STATS" />
     <!-- TODO: replace with READ_NETWORK_POLICY permission when it exists -->
     <uses-permission android:name="android.permission.CONNECTIVITY_INTERNAL" />
+    <uses-permission android:name="android.permission.MODIFY_NETWORK_ACCOUNTING" />
+    <uses-permission android:name="android.permission.CLEAR_APP_CACHE" />
+    <uses-permission android:name="android.permission.WAKE_LOCK" />
+    <uses-permission android:name="android.permission.UPDATE_APP_OPS_STATS" />
 
     <application android:process="android.process.media"
-                 android:label="@string/app_label">
+                 android:label="@string/app_label"
+                 android:icon="@mipmap/ic_launcher_download"
+                 android:allowBackup="false"
+                 android:supportsRtl="true"
+                 android:usesCleartextTraffic="true">
+
         <provider android:name=".DownloadProvider"
-                  android:authorities="downloads">
+                  android:authorities="downloads" android:exported="true">
           <!-- Anyone can access /my_downloads, the provider internally restricts access by UID for
                these URIs -->
           <path-permission android:pathPrefix="/my_downloads"
           <!-- Apps with access to /all_downloads/... can grant permissions, allowing them to share
                downloaded files with other viewers -->
           <grant-uri-permission android:pathPrefix="/all_downloads/"/>
+          <!-- Apps with access to /my_downloads/... can grant permissions, allowing them to share
+               downloaded files with other viewers -->
+          <grant-uri-permission android:pathPrefix="/my_downloads/"/>
+        </provider>
+
+        <provider
+            android:name=".DownloadStorageProvider"
+            android:authorities="com.android.providers.downloads.documents"
+            android:grantUriPermissions="true"
+            android:exported="true"
+            android:permission="android.permission.MANAGE_DOCUMENTS">
+            <intent-filter>
+                <action android:name="android.content.action.DOCUMENTS_PROVIDER" />
+            </intent-filter>
         </provider>
-        <service android:name=".DownloadService"
-                android:permission="android.permission.ACCESS_DOWNLOAD_MANAGER" />
+
+        <service
+            android:name=".DownloadJobService"
+            android:exported="true"
+            android:permission="android.permission.BIND_JOB_SERVICE" />
+
+        <service
+            android:name=".DownloadIdleService"
+            android:exported="true"
+            android:permission="android.permission.BIND_JOB_SERVICE" />
+
         <receiver android:name=".DownloadReceiver" android:exported="false">
             <intent-filter>
                 <action android:name="android.intent.action.BOOT_COMPLETED" />
-                <action android:name="android.net.conn.CONNECTIVITY_CHANGE" />
+                <action android:name="android.intent.action.UID_REMOVED" />
             </intent-filter>
             <intent-filter>
                 <action android:name="android.intent.action.MEDIA_MOUNTED" />
                 <data android:scheme="file" />
             </intent-filter>
         </receiver>
-
-        <activity android:name=".SizeLimitActivity"
-                  android:launchMode="singleTask"
-                  android:theme="@style/Theme.Translucent"/>
     </application>
 </manifest>