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

Commit 6dee0e40 authored by Tyler Gunn's avatar Tyler Gunn
Browse files

Ensure mShouldIgnoreVideoStateChanges is set on/off on fake pause/resume.

This is a fix for a modem bug where video state changes are not relayed
to the framework.
When I made the initial fix to add the changetoPausedState methods,
I thought I'd fixed the bug but it turns out I forget to set the
mShouldIgnoreVideoStateChanges variable.  There is a bit of a race
condition when reproducing this bug and I hit the race condition and
erroneously thought I'd solved it.

Test: Manual
Bug: 63153661
Change-Id: I82c9cb7bcf57df8f86964a3bff37469f0b999f1a
parent 2434d436
Loading
Loading
Loading
Loading
+2 −0
Original line number Diff line number Diff line
@@ -1228,6 +1228,7 @@ public class ImsPhoneConnection extends Connection implements
        Rlog.i(LOG_TAG, "ImsPhoneConnection: changeToPausedState - setting paused bit; "
                + "newVideoState=" + VideoProfile.videoStateToString(newVideoState));
        updateVideoState(newVideoState);
        mShouldIgnoreVideoStateChanges = true;
    }

    public void changeToUnPausedState() {
@@ -1235,5 +1236,6 @@ public class ImsPhoneConnection extends Connection implements
        Rlog.i(LOG_TAG, "ImsPhoneConnection: changeToUnPausedState - unsetting paused bit; "
                + "newVideoState=" + VideoProfile.videoStateToString(newVideoState));
        updateVideoState(newVideoState);
        mShouldIgnoreVideoStateChanges = false;
    }
}