[Qt-interest] Main thread sleep or stop problem

Andreas Pakulat apaku at gmx.de
Mon Feb 22 09:41:22 CET 2010


On 22.02.10 03:38:04, arjun  wrote:
> Hi All,
> I am working on multithread application. I want to stop or sleep main until all other thread complete there work.
> How can achieve this. please help me.  
> currently i am doing this using following while loop.
> here i am checking for each thread Object is finish in main thread. But it consume time for doing this.

Look into the QThread API, an easy way would be using QThread::wait().

Andreas

-- 
You will be a winner today.  Pick a fight with a four-year-old.



More information about the Qt-interest-old mailing list