Important: Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct
how to abort QJSEngine evaluate
-
If evaluate some script that has infinite loop, how to abort the evaluation process.
for example: evaluate some buggy JS in back thread:
QJSEngine engine;
void threadproc() {
engine.evaluate("while(1){}");
}How to give user a choice to abort the evaluate in main(GUI) thread.