Merge "[Security] resolve overlay attack on RequestIgnoreBatteryOptimizations" into sc-v2-dev am: d24f289548
am: e401e37369
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Settings/+/15898228 Change-Id: I750731ab9eb4bc063b33b2ca4c80999f5544b64f
This commit is contained in:
@@ -42,6 +42,8 @@ public class RequestIgnoreBatteryOptimizations extends AlertActivity implements
|
||||
@Override
|
||||
public void onCreate(Bundle savedInstanceState) {
|
||||
super.onCreate(savedInstanceState);
|
||||
getWindow().addSystemFlags(android.view.WindowManager.LayoutParams
|
||||
.SYSTEM_FLAG_HIDE_NON_SYSTEM_OVERLAY_WINDOWS);
|
||||
|
||||
mPowerWhitelistManager = getSystemService(PowerWhitelistManager.class);
|
||||
|
||||
@@ -98,13 +100,6 @@ public class RequestIgnoreBatteryOptimizations extends AlertActivity implements
|
||||
setupAlert();
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void onStart() {
|
||||
super.onStart();
|
||||
getWindow().addSystemFlags(android.view.WindowManager.LayoutParams
|
||||
.SYSTEM_FLAG_HIDE_NON_SYSTEM_OVERLAY_WINDOWS);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onClick(DialogInterface dialog, int which) {
|
||||
switch (which) {
|
||||
|
Reference in New Issue
Block a user