packages/apps/Settings
Revisão | 8a9fafb37d089789b2017676942da2da001ac47d (tree) |
---|---|
Hora | 2021-04-06 20:02:10 |
Autor | Arc Wang <arcwang@goog...> |
Commiter | Arc Wang |
Hide non-system overlay window on ActivityPicker
To improve security.
Bug: 181962311
Test: manual
Change-Id: I6e2845cc19dc012cba2933318a067bbb8db90a23
Merged-In: I6e2845cc19dc012cba2933318a067bbb8db90a23
(cherry picked from commit 3b4853e109a5d95656f73d31dace4099d5dfbca7)
@@ -16,6 +16,8 @@ | ||
16 | 16 | |
17 | 17 | package com.android.settings; |
18 | 18 | |
19 | +import static android.view.WindowManager.LayoutParams.PRIVATE_FLAG_HIDE_NON_SYSTEM_OVERLAY_WINDOWS; | |
20 | + | |
19 | 21 | import android.app.Activity; |
20 | 22 | import android.content.Context; |
21 | 23 | import android.content.DialogInterface; |
@@ -71,6 +73,8 @@ public class ActivityPicker extends AlertActivity implements | ||
71 | 73 | @Override |
72 | 74 | protected void onCreate(Bundle savedInstanceState) { |
73 | 75 | super.onCreate(savedInstanceState); |
76 | + | |
77 | + getWindow().addPrivateFlags(PRIVATE_FLAG_HIDE_NON_SYSTEM_OVERLAY_WINDOWS); | |
74 | 78 | |
75 | 79 | final Intent intent = getIntent(); |
76 | 80 |