summaryrefslogtreecommitdiffstats
path: root/ui/src
diff options
context:
space:
mode:
authorJeff Sharkey <jsharkey@android.com>2013-08-15 16:23:09 -0700
committerJeff Sharkey <jsharkey@android.com>2013-08-15 16:23:15 -0700
commit8c9cef79df1ddcd971a0a0775cef774c17a5081c (patch)
tree76a9346691510c29c8e3041b25579c6e98a430c5 /ui/src
parent4bafe763c1374c41cd84cb2e0621ea16bfeddd10 (diff)
downloadandroid_packages_providers_DownloadProvider-8c9cef79df1ddcd971a0a0775cef774c17a5081c.tar.gz
android_packages_providers_DownloadProvider-8c9cef79df1ddcd971a0a0775cef774c17a5081c.tar.bz2
android_packages_providers_DownloadProvider-8c9cef79df1ddcd971a0a0775cef774c17a5081c.zip
Delegate to documents UI; improve contents.
When Downloads app is launched, delegate to new documents management UI. Use DownloadManager public API to match the contents of the existing Downloads UI. Bug: 10329983 Change-Id: Iaa1a1dc013cfe3b17d31ecc764d4c4cc13f62258
Diffstat (limited to 'ui/src')
-rw-r--r--ui/src/com/android/providers/downloads/ui/DownloadList.java12
1 files changed, 12 insertions, 0 deletions
diff --git a/ui/src/com/android/providers/downloads/ui/DownloadList.java b/ui/src/com/android/providers/downloads/ui/DownloadList.java
index 05b5d757..57530474 100644
--- a/ui/src/com/android/providers/downloads/ui/DownloadList.java
+++ b/ui/src/com/android/providers/downloads/ui/DownloadList.java
@@ -33,6 +33,7 @@ import android.os.Environment;
import android.os.Handler;
import android.os.Parcelable;
import android.provider.BaseColumns;
+import android.provider.DocumentsContract;
import android.provider.Downloads;
import android.util.Log;
import android.util.SparseBooleanArray;
@@ -148,6 +149,17 @@ public class DownloadList extends Activity {
@Override
public void onCreate(Bundle icicle) {
super.onCreate(icicle);
+
+ // Trampoline over to new management UI
+ final Intent intent = new Intent(Intent.ACTION_MANAGE_DOCUMENT);
+ intent.setData(DocumentsContract.buildRootUri(
+ Constants.STORAGE_AUTHORITY, Constants.STORAGE_ROOT));
+ startActivity(intent);
+ finish();
+ }
+
+ public void onCreateLegacy(Bundle icicle) {
+ super.onCreate(icicle);
setFinishOnTouchOutside(true);
setupViews();