aboutsummaryrefslogtreecommitdiff
path: root/src/widgets/WebView.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/widgets/WebView.cpp')
-rw-r--r--src/widgets/WebView.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/widgets/WebView.cpp b/src/widgets/WebView.cpp
index ceb9c8e..1cd3d54 100644
--- a/src/widgets/WebView.cpp
+++ b/src/widgets/WebView.cpp
@@ -24,6 +24,11 @@ void WebView::open_devtools() {
devtools_window = nullptr;
});
+ connect(this, &WebView::destroyed, this, [this]() {
+ devtools_window->deleteLater();
+ devtools_window = nullptr;
+ });
+
page()->setDevToolsPage(devtools_window->page());
}