From 9ee126d76bb52e96ef9a9c5fa5241d5bf63cc2e5 Mon Sep 17 00:00:00 2001 From: Andrew Belt Date: Sun, 25 Jun 2023 09:03:09 -0400 Subject: [PATCH] Set vg in ContextCreateEvent and ContextDestroyEvent when constructing and destructing Window. --- src/window/Window.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/window/Window.cpp b/src/window/Window.cpp index 164db77b..fd8850bf 100644 --- a/src/window/Window.cpp +++ b/src/window/Window.cpp @@ -358,6 +358,7 @@ Window::Window() { if (APP->scene) { widget::Widget::ContextCreateEvent e; + e.vg = vg; APP->scene->onContextCreate(e); } } @@ -366,6 +367,7 @@ Window::Window() { Window::~Window() { if (APP->scene) { widget::Widget::ContextDestroyEvent e; + e.vg = vg; APP->scene->onContextDestroy(e); }