hi all,
I have an application in which when I press a button I should get a find dialog box. Thing is if I press the button again, I shouldnot get one more dialog box. The previous one should appear.
My present code is like this:
{
//some other lines of code
QObject::connect(but,
SIGNAL(clicked
()),
this,
SLOT(findbox
()));
//remaining program
}
void CPT::findbox()
{
//other widgets added to it
findstr->show();
}
CPT::CPT(QWidget *parent):QWidget(parent)
{
//some other lines of code
QPushButton *but=new QPushButton(this);
QObject::connect(but,SIGNAL(clicked()),this,SLOT(findbox()));
//remaining program
}
void CPT::findbox()
{
QWidget *findstr=new QWidget;
//other widgets added to it
findstr->show();
}
To copy to clipboard, switch view to plain text mode
So kindly help me in this problem.
Bookmarks