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

Commit d4da7eae authored by TreeHugger Robot's avatar TreeHugger Robot Committed by Android (Google) Code Review
Browse files

Merge "Move showing notification to background thread"

parents 5ee0f781 110f9a12
Loading
Loading
Loading
Loading
+4 −1
Original line number Diff line number Diff line
@@ -44,6 +44,7 @@ import android.util.Slog;

import com.android.internal.annotations.VisibleForTesting;
import com.android.internal.logging.MetricsLogger;
import com.android.settingslib.utils.ThreadUtils;
import com.android.systemui.Dependency;
import com.android.systemui.R;
import com.android.systemui.SystemUI;
@@ -242,7 +243,9 @@ public class PowerUI extends SystemUI {
                }

                // Show the correct version of low battery warning if needed
                ThreadUtils.postOnBackgroundThread(() -> {
                    maybeShowBatteryWarning(plugged, oldPlugged, oldBucket, bucket);
                });

            } else if (Intent.ACTION_SCREEN_OFF.equals(action)) {
                mScreenOffTime = SystemClock.elapsedRealtime();