]> SALOME platform Git repositories - modules/hydrosolver.git/commitdiff
Salome HOME
corrections
authorisn <isn@opencascade.com>
Fri, 7 Sep 2018 09:55:08 +0000 (12:55 +0300)
committerisn <isn@opencascade.com>
Fri, 7 Sep 2018 09:55:08 +0000 (12:55 +0300)
src/salome_hydro/generate_interpolz.py
src/salome_hydro/interpolz_gui.py

index 030eb80864c86d35f322d90b9056b0bb32acf430..fad48c49e6fc6a19d7a4a732c43482e545206832 100644 (file)
@@ -44,4 +44,4 @@ def generate( path, calc_case, med_file, med_groups_regions, z_undef, regions_in
 
 
 if __name__=='__main__':
-    generate( "test_interpolz.py", "case_1", "mesh.med", {"group_1":"reg_1", "group_2":"reg_2"}, -9999, {"reg_1" : "0", "reg_2": "1"} )
+    generate( "test_interpolz.py", "case_1", "mesh.med", {"group_1":"reg_1", "group_2":"reg_2"}, -9999, {"reg_1" : 0, "reg_2": 1} )
index 3d4a008c7b0d860d1b392259a24c2e419b8dfdcf..7bfdf2607df501cceb75b9e5353236c4257279c0 100644 (file)
@@ -149,6 +149,16 @@ class InterpolzDlg( QDialog ):
         icb.addItem( 'Interpolation at the nearest point' )
         icb.addItem( 'Linear interpolation on a cloud triangulation' )
         self.Groups.setCellWidget( i, 2, icb )
+        icb.currentIndexChanged.connect(self.onCBInterpChanged)
+               
+    def onCBInterpChanged( self ):
+      ind_set = set()
+      for i in range( 0, self.Groups.rowCount() ):
+        ind_set.add( self.Groups.cellWidget( i, 2 ).currentIndex() )
+      if len(ind_set) == 2:
+        self.InterpMethod.setStyleSheet("QComboBox { background-color: grey; }")
+      elif len(ind_set) == 1:
+        self.InterpMethod.setStyleSheet("")
 
     def onInterpChanged( self ):
       n = self.Groups.rowCount()