[Solved] Login dialog before mainwin
Hi all
I am wondering how I can make a login dialog such that mainwindow wont start before the correct credentials are typed in. ie:
- int main(int argc, char *argv[])
- {
- MainWindow w;
- LoginScreen ls;
- ls.show();
- a.processEvents();
- w.show(); // this should not show before LoginScreen is finished
- ls.close();
- return a.exec();
- }
How can I do this ?
How do I handle if the credentials are wrong, i.e show the LoginScreen again without the mainwindow showing ?
Thanks
DarkRoast
2 replies
QDialog::exec () [doc.qt.nokia.com]
Shows the dialog as a modal dialog, blocking until the user closes it. The function returns a DialogCode result.
You must log in to post a reply. Not a member yet? Register here!

