From: Paul RASCLE Date: Mon, 20 Mar 2017 15:46:37 +0000 (+0100) Subject: detached views can be correctly embedded in Python modules without GUI modification... X-Git-Tag: SHAPER_2.7.0_WIN~4 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=353ae915d182281648ed422139c3979d7a256ec9;p=modules%2Fgui.git detached views can be correctly embedded in Python modules without GUI modification, View Creation for GEOM or SMESH must take into account embedded VM --- diff --git a/src/LightApp/LightApp_Application.cxx b/src/LightApp/LightApp_Application.cxx index 9aee3eebe..c806a0018 100644 --- a/src/LightApp/LightApp_Application.cxx +++ b/src/LightApp/LightApp_Application.cxx @@ -1469,7 +1469,7 @@ SUIT_ViewManager* LightApp_Application::getViewManager( const QString& vmType, c aVM = anActiveVM; } - if ( aVM && create ) + if ( aVM && !aVM->getDetached() && create ) { if ( !aVM->getActiveView() ) { diff --git a/src/STD/STD_TabDesktop.cxx b/src/STD/STD_TabDesktop.cxx index f41b9aaf1..37766d63d 100644 --- a/src/STD/STD_TabDesktop.cxx +++ b/src/STD/STD_TabDesktop.cxx @@ -23,7 +23,6 @@ #include "STD_TabDesktop.h" #include -#include #include #include @@ -134,12 +133,6 @@ void STD_TabDesktop::addWindow( QWidget* w ) { if ( !w || !workstack() ) return; - if ( w && w->inherits( "SUIT_ViewWindow" ) ) - { - SUIT_ViewWindow* wid = (SUIT_ViewWindow*)w; - if ( wid->getViewManager()->getDetached() ) - return; - } workstack()->addWindow( w ); }