aboutsummaryrefslogtreecommitdiff
path: root/src/widgets/WebViewStack.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/widgets/WebViewStack.cpp')
-rw-r--r--src/widgets/WebViewStack.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/widgets/WebViewStack.cpp b/src/widgets/WebViewStack.cpp
index ab5808f..5503a3c 100644
--- a/src/widgets/WebViewStack.cpp
+++ b/src/widgets/WebViewStack.cpp
@@ -342,14 +342,15 @@ void WebViewStack::set_html(const QString &html, WebViewId webview_id) {
webview->setHtml(html);
}
-void WebViewStack::run_javascript(const QString &js_code, WebViewId webview_id) {
+void WebViewStack::run_javascript(const QString &js_code, WebViewId webview_id,
+ const JsOnResultFunc &on_result) {
auto *webview = get_webview(webview_id);
if (webview == nullptr) {
qDebug() << "Webview does not exist";
return;
}
- webview->run_javascript(js_code);
+ webview->run_javascript(js_code, on_result);
}
void WebViewStack::expose_rpc_function(const QString &name, const RpcFunc & /* unused */,