This commit is contained in:
2026-03-08 22:49:39 +01:00
parent 5d29d6f3b6
commit c752553d2e
14 changed files with 255 additions and 52 deletions

View File

@@ -65,6 +65,20 @@ void Rktwebview_qt::processCommand(Command *cmd)
cmd->done = true;
}
break;
case COMMAND_SET_OU_TOKEN: {
doEvents();
int wv = cmd->args[0].toInt();
QString ou_token = cmd->args[1].toString();
if (_views.contains(wv)) {
WebviewWindow *w= _views[wv];
w->setOUToken(ou_token);
cmd->result = true;
} else {
cmd->result = false;
}
cmd->done = true;
}
break;
case COMMAND_SET_URL: {
doEvents();
int wv = cmd->args[0].toInt();
@@ -371,6 +385,18 @@ void Rktwebview_qt::rktWebViewClose(int wv)
while(!c.done) { doEvents(); }
}
void Rktwebview_qt::rktSetOUToken(rktwebview_t wv, const char *ou_token)
{
Command c(COMMAND_SET_OU_TOKEN);
c.args.push_back(wv);
QString ou_tok(ou_token);
c.args.push_back(ou_tok);
postCommand(&c);
while(!c.done) { doEvents(); }
}
result_t Rktwebview_qt::rktSetUrl(rktwebview_t wv, const char *url)
{
Command c(COMMAND_SET_URL);