Salome HOME
Merge remote-tracking branch 'origin/BR_1321_ECW' into BR_DEMO
[modules/hydro.git] / src / HYDROGUI / HYDROGUI_BathymetryOp.cxx
index 0c45c2d72ba45b79a7a23f224a26f69d75245389..68178b587a5980ee6b1d7677060ba34a231bd781 100644 (file)
@@ -30,6 +30,7 @@
 #include <SUIT_Desktop.h>
 #include <QLayout>
 #include <QPushButton>
+#include <QApplication>
 
 HYDROGUI_BathymetryLimitsDlg::HYDROGUI_BathymetryLimitsDlg( QWidget* theParent )
   : QDialog( theParent )
@@ -130,6 +131,9 @@ void HYDROGUI_BathymetryOp::activate( bool isActivate )
   QList<Handle(HYDROGUI_BathymetryPrs)> baths = getShownBathymetries( module() );
   bool isUpdateCS = false;
 
+  if( myMode!=BathymetryRescaleUserId )
+    qApp->setOverrideCursor( Qt::WaitCursor );
+
   switch( myMode )
   {
   case BathymetryTextId:
@@ -183,6 +187,8 @@ void HYDROGUI_BathymetryOp::activate( bool isActivate )
         dlg.SetMinMax( min, max );
         if( dlg.exec()==QDialog::Accepted )
         {
+          qApp->setOverrideCursor( Qt::WaitCursor );
+
           min = dlg.GetMin();
           max = dlg.GetMax();
           foreach( Handle(HYDROGUI_BathymetryPrs) bath, baths )
@@ -212,4 +218,6 @@ void HYDROGUI_BathymetryOp::activate( bool isActivate )
 
   if( isUpdateCS )
     module()->getOCCDisplayer()->UpdateColorScale( getViewer( module() ) );
+
+  qApp->restoreOverrideCursor();
 }