1 bool event(QEvent *event) 2 { 3 if (event->type() == QEvent::NonClientAreaMouseButtonDblClick) 4 qDebug() << "title double clicked event"; 5 return QWidget::event(event); 6 }
重载event事件,即可