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

Commit 426095f6 authored by Lucas Dupin's avatar Lucas Dupin Committed by Android (Google) Code Review
Browse files

Merge "Trigger new frame after display is ready to turn on" into pi-dev

parents 9101ba2d f9583c41
Loading
Loading
Loading
Loading
+9 −0
Original line number Diff line number Diff line
@@ -407,6 +407,15 @@ public class TextClock extends TextView {
        registerObserver();
    }

    /**
     * Update the displayed time if necessary and invalidate the view.
     * @hide
     */
    public void refresh() {
        onTimeChanged();
        invalidate();
    }

    /**
     * Indicates whether the system is currently using the 24-hour mode.
     *
+1 −2
Original line number Diff line number Diff line
@@ -216,8 +216,7 @@ public class KeyguardStatusView extends GridLayout {
    }

    public void refreshTime() {
        mClockView.setFormat12Hour(Patterns.clockView12);
        mClockView.setFormat24Hour(Patterns.clockView24);
        mClockView.refresh();
    }

    private void refresh() {
+4 −0
Original line number Diff line number Diff line
@@ -109,7 +109,11 @@ public class DozeUi implements DozeMachine.Part {
        switch (newState) {
            case DOZE_AOD:
                if (oldState == DOZE_AOD_PAUSED) {
                    // Whenever turning on the display, it's necessary to push a new frame.
                    // The display buffers will be empty and need to be filled.
                    mHost.dozeTimeTick();
                    // The first frame may arrive when the display isn't ready yet.
                    mHandler.postDelayed(mHost::dozeTimeTick, 100);
                }
                scheduleTimeTick();
                break;
+1 −1
Original line number Diff line number Diff line
@@ -23,7 +23,7 @@ import android.os.Handler;
 */
public class DelayedWakeLock implements WakeLock {

    private static final long RELEASE_DELAY_MS = 240;
    private static final long RELEASE_DELAY_MS = 140;

    private final Handler mHandler;
    private final WakeLock mInner;