]> SALOME platform Git repositories - modules/visu.git/commitdiff
Salome HOME
Fix for Bug IPAL11993:
authorenk <enk@opencascade.com>
Fri, 24 Mar 2006 14:55:51 +0000 (14:55 +0000)
committerenk <enk@opencascade.com>
Fri, 24 Mar 2006 14:55:51 +0000 (14:55 +0000)
TC: Exception after closing animation dialog

src/VISUGUI/VisuGUI_TimeAnimation.cxx

index de4de17ef4c8fd15baec5a08295bfb72b8cc797b..92a3b4ab17f259bdef81745cccb795ad1ed671e8 100644 (file)
@@ -285,13 +285,11 @@ void ArrangeDlg::acceptAnimation()
     }
   } else {
     QApplication::setOverrideCursor( Qt::waitCursor );
-    FieldData& aData = myAnimator->getFieldData(0);
+    FieldData& aData = myAnimator->getFieldData(myFieldLst->currentItem());
     if (aData.myPrs.empty())
-      myAnimator->generatePresentations(0);
-    VISU_Actor* aActor = aData.myPrs[0]->CreateActor();
+      myAnimator->generatePresentations(myFieldLst->currentItem());
     float aBounds[6];
-    aActor->GetBounds(aBounds);
-    aActor->Delete();
+    aData.myPrs[0]->GetBounds(aBounds);
     float aDist = 0;
     int aAxis = getAxis();
     switch (aAxis) {
@@ -1170,6 +1168,7 @@ VisuGUI_TimeAnimationDlg::~VisuGUI_TimeAnimationDlg()
   if(myAnimator != NULL){
     delete myAnimator;
     myAnimator = NULL;
+    VISU::GetActiveViewWindow<SVTK_ViewWindow>(myModule)->Repaint();
   }
 }