另外写个槽函数呗void BEEP(){ QApplication::beep ();}QPushButton *pushBtn = new QPushButton;connect(pushBtn ,clicked(),this,BEEP());