X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=src%2FSUIT%2FSUIT_ViewWindow.cxx;h=d5d9032faeed6fff80f6bbf0b1d9f253a446034e;hb=efe3cdefadc31ad9cdaa9fd7fc368e2931cebdf1;hp=d0ac1a06697c4474a2f5e467b61312faaa3b5740;hpb=f87b97823fb44de451732cb03ffbf916bd9beb09;p=modules%2Fgui.git diff --git a/src/SUIT/SUIT_ViewWindow.cxx b/src/SUIT/SUIT_ViewWindow.cxx index d0ac1a066..d5d9032fa 100755 --- a/src/SUIT/SUIT_ViewWindow.cxx +++ b/src/SUIT/SUIT_ViewWindow.cxx @@ -549,3 +549,15 @@ void SUIT_ViewWindow::synchronizeView( SUIT_ViewWindow* viewWindow, int id ) } } } + +void SUIT_ViewWindow::setVisible( bool on ) +{ + // This is a workaround to avoid showing view window as a top-level window + // before re-parenting it to workstack (issue #23467). + // See SUIT_Desktop::childEvent(). + QApplication::sendPostedEvents( 0, QEvent::ChildRemoved ); + QApplication::sendPostedEvents( 0, QEvent::ChildAdded ); + QApplication::sendPostedEvents( 0, QEvent::ChildPolished ); + if ( !property( "blockShow" ).toBool() ) + QMainWindow::setVisible( on ); +}