Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Unverified Commit db9eb236 authored by Michael W's avatar Michael W Committed by Michael Bestas
Browse files

DeskClock: Remove ACTION_CLOSE_SYSTEM_DIALOGS

* Fixes alarms and timers not firing, especially when screen is off /
  device is locked
* https://developer.android.com/about/versions/12/behavior-changes-all#close-system-dialogs-exceptions

Change-Id: I555e6a2253fa135385742d0e5fa3fb42c6713012
parent 40fe6186
Loading
Loading
Loading
Loading
+0 −3
Original line number Diff line number Diff line
@@ -184,9 +184,6 @@ public class AlarmActivity extends BaseActivity
        // Hide navigation bar to minimize accidental tap on Home key
        hideNavigationBar();

        // Close dialogs and window shade, so this is fully visible
        sendBroadcast(new Intent(Intent.ACTION_CLOSE_SYSTEM_DIALOGS));

        // Honor rotation on tablets; fix the orientation on phones.
        if (!getResources().getBoolean(R.bool.rotateAlarmAlert)) {
            setRequestedOrientation(ActivityInfo.SCREEN_ORIENTATION_NOSENSOR);
+0 −3
Original line number Diff line number Diff line
@@ -91,9 +91,6 @@ public class ExpiredTimersActivity extends BaseActivity {
        KeyguardManager kgm = getSystemService(KeyguardManager.class);
        kgm.requestDismissKeyguard(this, null);

        // Close dialogs and window shade, so this is fully visible
        sendBroadcast(new Intent(Intent.ACTION_CLOSE_SYSTEM_DIALOGS));

        // Honor rotation on tablets; fix the orientation on phones.
        if (!getResources().getBoolean(R.bool.rotateAlarmAlert)) {
            setRequestedOrientation(ActivityInfo.SCREEN_ORIENTATION_NOSENSOR);