Salome HOME
Merge remote-tracking branch 'origin/uhz/padder_bug_fix_rmaxrmin' into V8_3_BR V8_3_0rc3
authorrnv <rnv@opencascade.com>
Mon, 24 Apr 2017 15:34:04 +0000 (18:34 +0300)
committerrnv <rnv@opencascade.com>
Mon, 24 Apr 2017 15:34:04 +0000 (18:34 +0300)
src/OBJECT/SMESH_ScalarBarActor.cxx
src/SMESH_I/SMESH_Gen_i_1.cxx

index 1f5b00b..a45696d 100644 (file)
@@ -578,15 +578,18 @@ int SMESH_ScalarBarActor::RenderOpaqueGeometry(vtkViewport *viewport)
       
       // rnv begin
       // Customization of the vtkScalarBarActor to show distribution histogram.
-      if(myDistributionColoringType == SMESH_MULTICOLOR_TYPE && GetDistributionVisibility() && distrVisibility)
-        {
-          rgb = distColors->GetPointer(3*dcCount); //write into array directly
-          rgb[0] = rgba[0];
-          rgb[1] = rgba[1];
-          rgb[2] = rgba[2];
-          dcCount++;
-        }
+      if ( myDistributionColoringType == SMESH_MULTICOLOR_TYPE &&
+           GetDistributionVisibility() &&
+           distrVisibility &&
+           myNbValues[i] > 0 )
+      {
+        rgb = distColors->GetPointer(3*dcCount); //write into array directly
+        rgb[0] = rgba[0];
+        rgb[1] = rgba[1];
+        rgb[2] = rgba[2];
+        dcCount++;
       }
+    }
 
     // Now position everything properly
     //
index 0ae5198..b08b7e3 100644 (file)
@@ -277,6 +277,10 @@ static SALOMEDS::SObject_ptr publish(SALOMEDS::Study_ptr   theStudy,
       SO = aStudyBuilder->NewObjectToTag( theFatherObject, theTag );
       isNewSO = true;
     }
+    else
+    {
+      isInUseCaseTree = useCaseBuilder->IsUseCaseNode( SO );
+    }
   }
   else
   {