Problem in deleting QTabWidget's Widget...
-
HI All,
I have added a QDialog into the QTabWidget...and while i try to remove first QWidget's TabBar...
All TabBar is getting removed from my QTabWidget@
void CTestDlg::addWidget()
{
CQuestionDlg *questionDlg = new CQuestionDlg();
ui->tabExams->addTab( questionDlg , "Question1");
}void CTestDlg::tabClose(int nCurIndex)
{
QWidget *wdgt = ui->tabWidget->widget( nCurIndex );
if( wdgt )
{
delete wdgt;
wdgt = 0;
}
ui->tabWidget->removeTab( nCurIndex );}
@please let me know whether i am doing anything wrong on this..