commit | e61467cd6c479662312d4104e6f27428b620d6bb | [log] [tgz] |
---|---|---|
author | Jakub Pawlowski <jpawlowski@google.com> | Mon Jun 08 05:55:40 2020 +0000 |
committer | Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com> | Mon Jun 08 05:55:40 2020 +0000 |
tree | 1bc2415edb481f90fc383285c314825ec86a1381 | |
parent | 103cc7cf29fcf2ab2132ab1af98e4a1d80a5bd09 [diff] | |
parent | c48d63752a60443db076b1538588c2b57862d285 [diff] |
Prevent overlay drawing on top of Bluetooth discovery request dialog am: c48d63752a Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Settings/+/11484059 Change-Id: I3572c16dd2b47189dc26ae4cd99f569d32b6ae2a
diff --git a/src/com/android/settings/bluetooth/RequestPermissionActivity.java b/src/com/android/settings/bluetooth/RequestPermissionActivity.java index 5485406..4446fb6 100644 --- a/src/com/android/settings/bluetooth/RequestPermissionActivity.java +++ b/src/com/android/settings/bluetooth/RequestPermissionActivity.java
@@ -37,6 +37,8 @@ import com.android.settings.R; import com.android.settingslib.bluetooth.BluetoothDiscoverableTimeoutReceiver; +import static android.view.WindowManager.LayoutParams.SYSTEM_FLAG_HIDE_NON_SYSTEM_OVERLAY_WINDOWS; + /** * RequestPermissionActivity asks the user whether to enable discovery. This is * usually started by an application wanted to start bluetooth and or discovery @@ -72,6 +74,8 @@ protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); + getWindow().addSystemFlags(SYSTEM_FLAG_HIDE_NON_SYSTEM_OVERLAY_WINDOWS); + setResult(Activity.RESULT_CANCELED); // Note: initializes mBluetoothAdapter and returns true on error