Commit e8bbc351 authored by Shawn Waldon's avatar Shawn Waldon Committed by Kitware Robot

Merge topic 'pick-block-fixes'

ad5d784e Fix Wsign-compare warning
d9665e7c Get current value of opacity to populate set block opacity dialog
15a500f2 Add HasElement to vtkSMDoubleMapProperty
9ccb5fd0 Make multiblock inspector panel update when block color/opacity are set
b5e3aa09 Get block name for context menu no longer uses inspector panel
ab8f8491 Make pqPipelineContextMenuBehavior not use multiblock inspector panel
Acked-by: Kitware Robot's avatarKitware Robot <kwrobot@kitware.com>
Reviewed-by: Utkarsh Ayachit's avatarUtkarsh Ayachit <utkarsh.ayachit@kitware.com>
Merge-request: !1421
parents 07a1ff2f ad5d784e
Pipeline #54149 running with stage
......@@ -158,6 +158,12 @@ vtkIdType vtkSMDoubleMapProperty::GetNumberOfElements()
return this->Private->Map.size();
}
//---------------------------------------------------------------------------
bool vtkSMDoubleMapProperty::HasElement(vtkIdType index)
{
return this->Private->Map.find(index) != this->Private->Map.end();
}
//---------------------------------------------------------------------------
void vtkSMDoubleMapProperty::ClearElements()
{
......
......@@ -90,6 +90,11 @@ public:
*/
virtual vtkIdType GetNumberOfElements() VTK_OVERRIDE;
/**
* Returns true if the property has an element with the given index
*/
bool HasElement(vtkIdType index);
/**
* Clears all of the elements from the property.
*/
......
......@@ -237,12 +237,18 @@ void pqMultiBlockInspectorPanel::onRepresentationChanged(pqRepresentation* repre
visibilityProperty, vtkCommand::ModifiedEvent, &this->UpdateUITimer, SLOT(start()));
}
vtkSMProperty* colorProperty = proxy->GetProperty("BlockColors");
vtkSMProperty* colorProperty = proxy->GetProperty("BlockColor");
if (colorProperty)
{
this->PropertyListener->Connect(
colorProperty, vtkCommand::ModifiedEvent, &this->UpdateUITimer, SLOT(start()));
}
vtkSMProperty* opacityProperty = proxy->GetProperty("BlockOpacity");
if (opacityProperty)
{
this->PropertyListener->Connect(
opacityProperty, vtkCommand::ModifiedEvent, &this->UpdateUITimer, SLOT(start()));
}
vtkSMProperty* colorArrayNameProperty = proxy->GetProperty("ColorArrayName");
if (colorArrayNameProperty)
{
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment