mirror of
https://git.mirrors.martin98.com/https://github.com/prusa3d/PrusaSlicer.git
synced 2025-08-15 04:16:04 +08:00
Remove static run_script function.
This commit is contained in:
parent
d72794bde8
commit
7b9d9a33a4
@ -56,9 +56,3 @@ wxWebView* WebView::CreateWebView(wxWindow * parent, const wxString& url)
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
bool WebView::run_script(wxWebView *webView, wxString const &javascript)
|
|
||||||
{
|
|
||||||
webView->RunScriptAsync(javascript);
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
@ -8,7 +8,6 @@ class wxString;
|
|||||||
namespace WebView
|
namespace WebView
|
||||||
{
|
{
|
||||||
wxWebView *CreateWebView(wxWindow *parent, const wxString& url);
|
wxWebView *CreateWebView(wxWindow *parent, const wxString& url);
|
||||||
bool run_script(wxWebView * webView, const wxString& msg);
|
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif // !slic3r_GUI_WebView_hpp_
|
#endif // !slic3r_GUI_WebView_hpp_
|
||||||
|
@ -318,11 +318,8 @@ void WebViewPanel::run_script(const wxString& javascript)
|
|||||||
// Remember the script we run in any case, so the next time the user opens
|
// Remember the script we run in any case, so the next time the user opens
|
||||||
// the "Run Script" dialog box, it is shown there for convenient updating.
|
// the "Run Script" dialog box, it is shown there for convenient updating.
|
||||||
m_javascript = javascript;
|
m_javascript = javascript;
|
||||||
|
BOOST_LOG_TRIVIAL(debug) << "RunScript " << javascript;
|
||||||
if (!m_browser) return;
|
m_browser->RunScriptAsync(javascript);
|
||||||
|
|
||||||
bool res = WebView::run_script(m_browser, javascript);
|
|
||||||
BOOST_LOG_TRIVIAL(debug) << "RunScript " << javascript << " " << res;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -681,8 +678,7 @@ void WebViewDialog::run_script(const wxString& javascript)
|
|||||||
{
|
{
|
||||||
if (!m_browser)
|
if (!m_browser)
|
||||||
return;
|
return;
|
||||||
// dk_FIXME: Is it ok to discard the return value?
|
m_browser->RunScriptAsync(javascript);
|
||||||
/*bool res = */ WebView::run_script(m_browser, javascript);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
PrinterPickWebViewDialog::PrinterPickWebViewDialog(wxWindow* parent, std::string& ret_val)
|
PrinterPickWebViewDialog::PrinterPickWebViewDialog(wxWindow* parent, std::string& ret_val)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user