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

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

Merge "Mark GrContext dirty after onContextDestroyed"

parents 018edf2c 1b0278c1
Loading
Loading
Loading
Loading
+5 −0
Original line number Diff line number Diff line
@@ -18,6 +18,7 @@

#include <private/hwui/WebViewFunctor.h>
#include "Properties.h"
#include "renderthread/RenderThread.h"

#include <log/log.h>
#include <utils/Trace.h>
@@ -90,6 +91,10 @@ void WebViewFunctor::destroyContext() {
        mHasContext = false;
        ATRACE_NAME("WebViewFunctor::onContextDestroyed");
        mCallbacks.onContextDestroyed(mFunctor, mData);

        // grContext may be null in unit tests.
        auto* grContext = renderthread::RenderThread::getInstance().getGrContext();
        if (grContext) grContext->resetContext();
    }
}

+1 −0
Original line number Diff line number Diff line
@@ -123,6 +123,7 @@ private:
    friend class RenderProxy;
    friend class DummyVsyncSource;
    friend class android::uirenderer::TestUtils;
    friend class android::uirenderer::WebViewFunctor;

    RenderThread();
    virtual ~RenderThread();