bool Q3DockArea::eventFilter(QObject *o, QEvent *e) { if (e->type() == QEvent::Close) { if (qobject_cast<Q3DockWindow*>(o)) { o->removeEventFilter(this); QApplication::sendEvent(o, e); if (((QCloseEvent*)e)->isAccepted()) removeDockWindow((Q3DockWindow*)o, false, false); return true; } } return false; }
bool QDockArea::eventFilter( QObject *o, QEvent *e ) { if ( e->type() == QEvent::Close ) { if ( ::qt_cast<QDockWindow*>(o) ) { o->removeEventFilter( this ); QApplication::sendEvent( o, e ); if ( ( (QCloseEvent*)e )->isAccepted() ) removeDockWindow( (QDockWindow*)o, FALSE, FALSE ); return TRUE; } } return FALSE; }