Here my code snippet written in Qt.
bool myFunc()
{
.......
while(!tcpCommunicator->isLoginReplyExist)
{
qApp->processEvents(QEventLoop::AllEvents);
}
.......
return tcpCommunicator->res;
}
After "isLoginReplyExist" is changed by another part of program I want to exit from loop, is there any better way to accomplish this?
Thanks.