class MyInputDigit :public QInputDialog{ Q_OBJECTpublic: explicit MyInputDigit(QWidget *parent = 0);public slots: void textValChanged();};
MyInputDigit::MyInputDigit(QWidget *parent) :QInputDialog(parent){ connect(this, SIGNAL(textValueChanged(const QString &text)), this, SLOT(textValChanged()));}void MyInputDigit::textValChanged(){ QMessageBox msg; msg.setText("text"); msg.exec();}
class MyInputDigit :public QInputDialog{ Q_OBJECTpublic: MyInputDigit(QWidget *parent = 0);public slots: void textValChanged(QString text);};
MyInputDigit::MyInputDigit(QWidget *parent) :QInputDialog(parent){ connect(this, SIGNAL(textValueChanged(QString)), this, SLOT(textValChanged(QString)));}void MyInputDigit::textValChanged(QString text){ QMessageBox msg; msg.setText(text); msg.exec();}