PDA

View Full Version : modeless dialog



mhoover
22nd March 2006, 23:34
This is an extra newbie question.
I thought I knew Qt so well ... and then Qt4 came out ;)

Anyway, for some reason, when I run this function the modeless dialog comes up great. When I run it again nothing happens.

Any ideas?


void MainForm::openLemonDialog()
{
if ( !lemon_dialog ) {
lemon_dialog = new LemonDialog( this );
connect( lemon_dialog, SIGNAL( addLemonJuice( const QString & ) ),
this, SLOT( changeLemonAmnt( const QString & ) ) ); // remember H+ diff
}
lemon_dialog->show();
lemon_dialog->raise();
lemon_dialog->activateWindow();
}

Chicken Blood Machine
23rd March 2006, 05:34
Where is lemon_dialog defined? Presumably it is a member variable?

mhoover
23rd March 2006, 22:56
Yep. It is.