Single Modeless Dialog
General and Desktop
4
Posts
2
Posters
838
Views
2
Watching
-
I know how to add a modal and modeless dialog to pop up. What I can't find is how do you have a modeless window pop open and not allow the user to continue to open new windows?
.h
private:
MyDialog *mDialog;.cpp
mDialog = new MyDialog(this);
mDialog->show(); -
hi and welcome
with new windows, you mean another copy of Mydialog?
you could test with
if (mDialog!=NULL && mDialog->isVisible() ) return;set mDialog =NULL in constructor.
-
hi and welcome
with new windows, you mean another copy of Mydialog?
you could test with
if (mDialog!=NULL && mDialog->isVisible() ) return;set mDialog =NULL in constructor.
-
did you set mDialog=NULL; at constructor?
else it just has random value and u will crash.