]> SALOME platform Git repositories - modules/superv.git/commitdiff
Salome HOME
Fix for bug IPAL9494 : 3.0.0 (/dn06/.../current1507/): Dataflow displays in the secon...
authormkr <mkr@opencascade.com>
Fri, 15 Jul 2005 04:36:59 +0000 (04:36 +0000)
committermkr <mkr@opencascade.com>
Fri, 15 Jul 2005 04:36:59 +0000 (04:36 +0000)
src/SUPERVGUI/SUPERVGUI.cxx

index b1c609572b4b4d1030ef67c4ed374ce7167d806f..be668d781c65be310efd9e0a3bdce39ca6791713 100644 (file)
@@ -471,7 +471,18 @@ void SUPERVGUI::displayDataflow() {
       }
       */
     }
-    SUPERVGraph_ViewFrame* aViewFrame = dynamic_cast<SUPERVGraph_ViewFrame*>( createGraph() );
+
+    SUPERVGraph_ViewFrame* aViewFrame; 
+    if ( !myInitialViewFrame ) {
+      // first case : create a ViewFrame object
+      aViewFrame = dynamic_cast<SUPERVGraph_ViewFrame*>( 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 );