[Interest] Update QWebElement from different threads

Freddy Martinez Garcia freddy311082 at gmail.com
Thu Mar 3 18:01:31 CET 2016


Hi guys... I need to update a QWebElement from different threads... Imagine
that I have the following statement:

QString htmlElemCode = "<p>Hello World</p>";
QWebElement elem = webFrame->findFirtsElement("#body_div");

elem.appendInside(htmlElemCode);

well, I need to run

elem.appendInside(htmlElemCode);

in a thread different than the main thread. I had defined this piece of
code inside one slot, which I need to call it in a different threads, not
only from the main thread. The problem come when I try to call the slot
from a thread different than the main thread, because the GUI doesn't
update it's html content... however, if I call the slot from the main
thread, I can see a success result on my html content, updating the html
elements as I wish.

My main goal is update my html content dynamically using a javascript
functions defined on my html code, which let me add some rows and columns
to my html tables, but, I need to do this using various threads...

is that possible ??? what is the best way to do that ??

regards



*============================================="El tamaño de tus logros
depende del tamaño de tus metas." *

*C++ and Qt Senior Developer*

*Lic. Computer Science*

*Buenos Aires, Argentina*
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.qt-project.org/pipermail/interest/attachments/20160303/66635946/attachment.html>


More information about the Interest mailing list