From: mzn Date: Wed, 21 Dec 2005 13:44:14 +0000 (+0000) Subject: Erase the scalar bar preview after the dialog closing. X-Git-Tag: T_Before_Join_BR_3_1_0deb~2 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=0c8508cc8290019efe1474d91e0fecd7dab57c63;p=modules%2Fvisu.git Erase the scalar bar preview after the dialog closing. --- diff --git a/src/VISUGUI/VisuGUI_CutLinesDlg.cxx b/src/VISUGUI/VisuGUI_CutLinesDlg.cxx index 14563d8a..a9983bf3 100644 --- a/src/VISUGUI/VisuGUI_CutLinesDlg.cxx +++ b/src/VISUGUI/VisuGUI_CutLinesDlg.cxx @@ -801,6 +801,7 @@ void VisuGUI_CutLinesDlg::accept() } } VisuGUI::application()->objectBrowser()->updateTree();*/ + myScalarPane->deletePreview(); deletePlanes(); QDialog::accept(); // } @@ -812,6 +813,7 @@ void VisuGUI_CutLinesDlg::reject() myPrs->RemoveFromStudy(); VisuGUI::application()->objectBrowser()->updateTree(); }*/ + myScalarPane->deletePreview(); deletePlanes(); QDialog::reject(); } diff --git a/src/VISUGUI/VisuGUI_CutPlanesDlg.cxx b/src/VISUGUI/VisuGUI_CutPlanesDlg.cxx index 8b921771..c4072907 100644 --- a/src/VISUGUI/VisuGUI_CutPlanesDlg.cxx +++ b/src/VISUGUI/VisuGUI_CutPlanesDlg.cxx @@ -530,10 +530,14 @@ void VisuGUI_CutPlanesDlg::accept() // return; //} if (myScalarPane->check()) - QDialog::accept(); + { + myScalarPane->deletePreview(); + QDialog::accept(); + } } void VisuGUI_CutPlanesDlg::reject() { + myScalarPane->deletePreview(); QDialog::reject(); } diff --git a/src/VISUGUI/VisuGUI_DeformedShapeDlg.cxx b/src/VISUGUI/VisuGUI_DeformedShapeDlg.cxx index 1dcf9e63..da99973c 100644 --- a/src/VISUGUI/VisuGUI_DeformedShapeDlg.cxx +++ b/src/VISUGUI/VisuGUI_DeformedShapeDlg.cxx @@ -137,5 +137,15 @@ int VisuGUI_DeformedShapeDlg::storeToPrsObject(VISU::DeformedShape_i* thePrs) { } void VisuGUI_DeformedShapeDlg::accept() { - if (myScalarPane->check()) QDialog::accept(); + if (myScalarPane->check()) + { + myScalarPane->deletePreview(); + QDialog::accept(); + } +} + +void VisuGUI_DeformedShapeDlg::reject() +{ + myScalarPane->deletePreview(); + QDialog::reject(); } diff --git a/src/VISUGUI/VisuGUI_DeformedShapeDlg.h b/src/VISUGUI/VisuGUI_DeformedShapeDlg.h index bd735a5a..573c439a 100644 --- a/src/VISUGUI/VisuGUI_DeformedShapeDlg.h +++ b/src/VISUGUI/VisuGUI_DeformedShapeDlg.h @@ -66,6 +66,7 @@ public: protected slots: void accept(); + void reject(); private: QtxDblSpinBox* ScalFact; diff --git a/src/VISUGUI/VisuGUI_IsoSurfacesDlg.cxx b/src/VISUGUI/VisuGUI_IsoSurfacesDlg.cxx index 344e30a2..34d170b9 100644 --- a/src/VISUGUI/VisuGUI_IsoSurfacesDlg.cxx +++ b/src/VISUGUI/VisuGUI_IsoSurfacesDlg.cxx @@ -212,5 +212,14 @@ VisuGUI_IsoSurfacesDlg::VisuGUI_IsoSurfacesDlg (SalomeApp_Module* theModule) void VisuGUI_IsoSurfacesDlg::accept() { if (myIsoPane->check() && myScalarPane->check()) - QDialog::accept(); + { + myScalarPane->deletePreview(); + QDialog::accept(); + } +} + +void VisuGUI_IsoSurfacesDlg::reject() +{ + myScalarPane->deletePreview(); + QDialog::reject(); } diff --git a/src/VISUGUI/VisuGUI_IsoSurfacesDlg.h b/src/VISUGUI/VisuGUI_IsoSurfacesDlg.h index f3ad7c0b..dc0547f1 100644 --- a/src/VISUGUI/VisuGUI_IsoSurfacesDlg.h +++ b/src/VISUGUI/VisuGUI_IsoSurfacesDlg.h @@ -85,6 +85,7 @@ class VisuGUI_IsoSurfacesDlg : public QDialog protected slots: void accept(); + void reject(); private: VisuGUI_IsoSurfPane* myIsoPane; diff --git a/src/VISUGUI/VisuGUI_Plot3DDlg.cxx b/src/VISUGUI/VisuGUI_Plot3DDlg.cxx index 78cbcec2..62ca7306 100644 --- a/src/VISUGUI/VisuGUI_Plot3DDlg.cxx +++ b/src/VISUGUI/VisuGUI_Plot3DDlg.cxx @@ -551,7 +551,10 @@ VisuGUI_Plot3DDlg::VisuGUI_Plot3DDlg (SalomeApp_Module* theModule) void VisuGUI_Plot3DDlg::accept() { if (myIsoPane->check() && myScalarPane->check()) - QDialog::accept(); + { + myScalarPane->deletePreview(); + QDialog::accept(); + } } //======================================================================= @@ -561,6 +564,7 @@ void VisuGUI_Plot3DDlg::accept() void VisuGUI_Plot3DDlg::reject() { myIsoPane->check(); // hide preview - + myScalarPane->deletePreview(); + QDialog::reject(); } diff --git a/src/VISUGUI/VisuGUI_StreamLinesDlg.cxx b/src/VISUGUI/VisuGUI_StreamLinesDlg.cxx index e5bf1e2c..aba09d66 100644 --- a/src/VISUGUI/VisuGUI_StreamLinesDlg.cxx +++ b/src/VISUGUI/VisuGUI_StreamLinesDlg.cxx @@ -541,5 +541,14 @@ VISU::Mesh_ptr VisuGUI_StreamLinesDlg::createMesh (VISU::VISUType theType, QStri void VisuGUI_StreamLinesDlg::accept() { if (myScalarPane->check()) - QDialog::accept(); + { + myScalarPane->deletePreview(); + QDialog::accept(); + } +} + +void VisuGUI_StreamLinesDlg::reject() +{ + myScalarPane->deletePreview(); + QDialog::reject(); } diff --git a/src/VISUGUI/VisuGUI_StreamLinesDlg.h b/src/VISUGUI/VisuGUI_StreamLinesDlg.h index 0e949ebd..c5f45e20 100644 --- a/src/VISUGUI/VisuGUI_StreamLinesDlg.h +++ b/src/VISUGUI/VisuGUI_StreamLinesDlg.h @@ -39,6 +39,7 @@ public: protected slots: void accept(); + void reject(); private slots: void onSelectionActive(bool theActive); diff --git a/src/VISUGUI/VisuGUI_VectorsDlg.cxx b/src/VISUGUI/VisuGUI_VectorsDlg.cxx index 86a10e9c..a5e2f2c5 100644 --- a/src/VISUGUI/VisuGUI_VectorsDlg.cxx +++ b/src/VISUGUI/VisuGUI_VectorsDlg.cxx @@ -408,6 +408,15 @@ void VisuGUI_VectorsDlg::enableMagnColor( bool enable ) void VisuGUI_VectorsDlg::accept() { - if (myScalarPane->check()) QDialog::accept(); + if (myScalarPane->check()) + { + myScalarPane->deletePreview(); + QDialog::accept(); + } } +void VisuGUI_VectorsDlg::reject() +{ + myScalarPane->deletePreview(); + QDialog::reject(); +} diff --git a/src/VISUGUI/VisuGUI_VectorsDlg.h b/src/VISUGUI/VisuGUI_VectorsDlg.h index 70d99b7c..2abdf591 100644 --- a/src/VISUGUI/VisuGUI_VectorsDlg.h +++ b/src/VISUGUI/VisuGUI_VectorsDlg.h @@ -81,6 +81,7 @@ public: protected slots: void accept(); + void reject(); private: QGroupBox* TopGroup;