From: mkr Date: Fri, 15 Jul 2005 04:36:59 +0000 (+0000) Subject: Fix for bug IPAL9494 : 3.0.0 (/dn06/.../current1507/): Dataflow displays in the secon... X-Git-Tag: current25072005~1 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=6ac3615606a41960553a8882a1af1aba207cd96d;p=modules%2Fsuperv.git Fix for bug IPAL9494 : 3.0.0 (/dn06/.../current1507/): Dataflow displays in the second (not first) new empty view frame after "Display" menu item in object browser popup. --- diff --git a/src/SUPERVGUI/SUPERVGUI.cxx b/src/SUPERVGUI/SUPERVGUI.cxx index b1c6095..be668d7 100644 --- a/src/SUPERVGUI/SUPERVGUI.cxx +++ b/src/SUPERVGUI/SUPERVGUI.cxx @@ -471,7 +471,18 @@ void SUPERVGUI::displayDataflow() { } */ } - SUPERVGraph_ViewFrame* aViewFrame = dynamic_cast( createGraph() ); + + SUPERVGraph_ViewFrame* aViewFrame; + if ( !myInitialViewFrame ) { + // first case : create a ViewFrame object + aViewFrame = dynamic_cast( createGraph() ); + } + else { + // second case : get empty initial view frame as new ViewFrame object + aViewFrame = myInitialViewFrame; + myInitialViewFrame = 0; + } + if( aViewFrame ) { main = new SUPERVGUI_Main( aViewFrame, application()->desktop(), aDataFlow ); registerGraph( aIORName, main );