06-23-2014 05:24 AM
06-23-2014 05:53 AM - edited 06-23-2014 06:04 AM
While it would work you need to make sure if you are having multiple feeds that you thread each one, in fact even with a single download you will potenitally stall the UI by doing this.
Take a look at threading and signals and slots for how to do what you are trying to do correctly (although this is about openGL it is the same problem of blocking the UI)...
Although the documentation is slightly wrong here you would not subclass the thread instead use a worker.
06-23-2014 05:59 AM
Always takes me a while to find the correct page in the documentation for this one (I should bookmark it ).
Anyway at the bottom of this page is an explanation of the preferred way of threading (i.e. using QThread) with some example code...
Before someone else does I will also mention there are lighter ways of writing asynchronous code as well, such as QtConcurrent, which is also mentioned at the bottom of the page at that link.