From 4108c7bf82e45395abade94fc33cb763d9c750a9 Mon Sep 17 00:00:00 2001 From: epa Date: Tue, 31 Oct 2006 17:23:16 +0000 Subject: [PATCH] Work of "Display only on creation" with CutLines has been corrected --- src/VISUGUI/VisuGUI_Prs3dTools.h | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/src/VISUGUI/VisuGUI_Prs3dTools.h b/src/VISUGUI/VisuGUI_Prs3dTools.h index 4b093282..a58eb941 100644 --- a/src/VISUGUI/VisuGUI_Prs3dTools.h +++ b/src/VISUGUI/VisuGUI_Prs3dTools.h @@ -178,11 +178,18 @@ namespace VISU if (aPrs3d) { SUIT_ResourceMgr* aResourceMgr = GetResourceMgr(); int aValue = aResourceMgr->integerValue("VISU","BuildDefaultPrs3d",0); + if(aResourceMgr->booleanValue("VISU","display_only",false)){ + theModule->OnEraseAll(); + } + if (!aValue) { if (TDlg* aDlg = new TDlg(theModule)) { // dialog box in creation mode aDlg->initFromPrsObject(aPrs3d); if (runAndWait(aDlg,IsDlgModal) && (aDlg->storeToPrsObject(aPrs3d))) { + if(aResourceMgr->booleanValue("VISU","display_only",false)){ + if(SPlot2d_Viewer* aPlot2d = GetPlot2dViewer(theModule, false)) aPlot2d->EraseAll(); + } // Optionally, create table and curves for cut lines QApplication::setOverrideCursor(Qt::waitCursor); CreateCurves( theModule, @@ -203,9 +210,6 @@ namespace VISU aViewWindow = GetViewWindow(theModule); // Display created presentation. if (aViewWindow) { - if(aResourceMgr->booleanValue("VISU","display_only",false)){ - theModule->OnEraseAll(); - } PublishInView(theModule, aPrs3d, aViewWindow, /*highlight = */true); aViewWindow->onFitAll(); -- 2.39.2