mirror of
https://github.com/OrcaSlicer/OrcaSlicer.git
synced 2026-08-03 16:22:08 +00:00
fix: startup crash on macOS when a printer has a print host set (#14747)
This commit is contained in:
@@ -246,7 +246,10 @@ void PrinterWebView::SendAPIKey()
|
||||
// RemoveAllUserScripts causes WebView to forget about our script message handler,
|
||||
// so re-add it here.
|
||||
m_browser->RemoveScriptMessageHandler("wx");
|
||||
m_browser->AddScriptMessageHandler("wx");
|
||||
if (m_browser->AddScriptMessageHandler("wx"))
|
||||
WebView::MarkScriptMessageHandlerAdded(m_browser);
|
||||
else
|
||||
wxLogError("Could not add script message handler");
|
||||
|
||||
#ifdef __linux__
|
||||
// Re-inject the vue-resize/WebKitGTK workaround that RemoveAllUserScripts just cleared.
|
||||
|
||||
Reference in New Issue
Block a user