From: vsr Date: Wed, 18 Feb 2009 13:20:00 +0000 (+0000) Subject: Issue 0020169: Automatically set the good viewer at module activation X-Git-Tag: V5_1_1a1~2 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=2460e2ea8e882950a8071b57f2f10707a4b89158;p=modules%2Fgui.git Issue 0020169: Automatically set the good viewer at module activation --- diff --git a/src/Qtx/QtxWorkstack.cxx b/src/Qtx/QtxWorkstack.cxx index eca4c7852..53e91aab4 100644 --- a/src/Qtx/QtxWorkstack.cxx +++ b/src/Qtx/QtxWorkstack.cxx @@ -1344,6 +1344,8 @@ QtxWorkstackChild::QtxWorkstackChild( QWidget* wid, QWidget* parent, Qt::WindowF { myWidget->setParent( this, f ); myWidget->installEventFilter( this ); + if ( myWidget->focusProxy() ) + myWidget->focusProxy()->installEventFilter( this ); myWidget->setVisible( myWidget->isVisibleTo( myWidget->parentWidget() ) ); QVBoxLayout* base = new QVBoxLayout( this ); @@ -1368,6 +1370,8 @@ QtxWorkstackChild::~QtxWorkstackChild() widget()->hide(); widget()->removeEventFilter( this ); + if ( widget()->focusProxy() ) + widget()->focusProxy()->removeEventFilter( this ); widget()->setParent( 0 ); }