From 27c3ab630afd6296ff1ff7b2b71638caa8f2ec54 Mon Sep 17 00:00:00 2001 From: Adrian Roos Date: Wed, 15 Oct 2014 17:21:31 +0200 Subject: [PATCH] Prevent ChooserActivity from taking over the system bars Bug: 17939334 Change-Id: I4d028695a1f81442cbbe7067b33475634effd5d2 --- core/java/com/android/internal/app/ResolverActivity.java | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/core/java/com/android/internal/app/ResolverActivity.java b/core/java/com/android/internal/app/ResolverActivity.java index f9da09a82aaee..b9cbc62e0aaa0 100644 --- a/core/java/com/android/internal/app/ResolverActivity.java +++ b/core/java/com/android/internal/app/ResolverActivity.java @@ -74,6 +74,9 @@ import java.util.List; import java.util.Map; import java.util.Set; +import static android.view.WindowManager.LayoutParams.FLAG_LAYOUT_INSET_DECOR; +import static android.view.WindowManager.LayoutParams.FLAG_LAYOUT_IN_SCREEN; + /** * This activity is displayed when the system attempts to start an Intent for * which there is more than one matching activity, allowing the user to decide @@ -269,6 +272,9 @@ public class ResolverActivity extends Activity implements AdapterView.OnItemClic mListView = (ListView) findViewById(R.id.resolver_list); mListView.setVisibility(View.GONE); } + // Prevent the Resolver window from becoming the top fullscreen window and thus from taking + // control of the system bars. + getWindow().clearFlags(FLAG_LAYOUT_IN_SCREEN|FLAG_LAYOUT_INSET_DECOR); final ResolverDrawerLayout rdl = (ResolverDrawerLayout) findViewById(R.id.contentPanel); if (rdl != null) {