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

Commit 178652a5 authored by Jesse Hall's avatar Jesse Hall Committed by Android Git Automerger
Browse files

am 3b4e55c0: am 9a143922: Ignore display state changes for disconnected displays

* commit '3b4e55c0':
  Ignore display state changes for disconnected displays
parents 1c19de6c 3b4e55c0
Loading
Loading
Loading
Loading
+5 −1
Original line number Original line Diff line number Diff line
@@ -1707,8 +1707,12 @@ void SurfaceFlinger::setTransactionState(


uint32_t SurfaceFlinger::setDisplayStateLocked(const DisplayState& s)
uint32_t SurfaceFlinger::setDisplayStateLocked(const DisplayState& s)
{
{
    ssize_t dpyIdx = mCurrentState.displays.indexOfKey(s.token);
    if (dpyIdx < 0)
        return 0;

    uint32_t flags = 0;
    uint32_t flags = 0;
    DisplayDeviceState& disp(mCurrentState.displays.editValueFor(s.token));
    DisplayDeviceState& disp(mCurrentState.displays.editValueAt(dpyIdx));
    if (disp.isValid()) {
    if (disp.isValid()) {
        const uint32_t what = s.what;
        const uint32_t what = s.what;
        if (what & DisplayState::eSurfaceChanged) {
        if (what & DisplayState::eSurfaceChanged) {