diff --git a/modules/juce_opengl/opengl/juce_OpenGLContext.cpp b/modules/juce_opengl/opengl/juce_OpenGLContext.cpp index 5d6d4adfe7..2bea0e4d16 100644 --- a/modules/juce_opengl/opengl/juce_OpenGLContext.cpp +++ b/modules/juce_opengl/opengl/juce_OpenGLContext.cpp @@ -444,6 +444,7 @@ private: void detach() { getComponent()->setCachedComponentImage (nullptr); + context.nativeContext = nullptr; } };