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

Commit 391e4125 authored by Alex Sakhartchouk's avatar Alex Sakhartchouk Committed by android-build-merger
Browse files

Merge "Release virtual display hwcId during vr mode transition." into oc-dev am: 5d6d98a1

am: d940f0c8

Change-Id: I386d5b397e26d3c177abc11f07a931315e61506e
parents e1ea635a d940f0c8
Loading
Loading
Loading
Loading
+7 −0
Original line number Diff line number Diff line
@@ -1242,6 +1242,13 @@ void SurfaceFlinger::resetHwc() {
    // mCurrentState and mDrawingState and re-apply all changes when we make the
    // transition.
    mDrawingState.displays.clear();
    // Release virtual display hwcId during vr mode transition.
    for (size_t displayId = 0; displayId < mDisplays.size(); ++displayId) {
        const sp<DisplayDevice>& displayDevice = mDisplays[displayId];
        if (displayDevice->getDisplayType() == DisplayDevice::DISPLAY_VIRTUAL) {
            displayDevice->disconnect(getHwComposer());
        }
    }
    mDisplays.clear();
    initializeDisplays();
}