-----------------------------------------------------------------------------
| 731 | |
| 732 | //----------------------------------------------------------------------------- |
| 733 | void pqDisplayColorWidget::updateColorTransferFunction() |
| 734 | { |
| 735 | if (!this->Representation) |
| 736 | { |
| 737 | return; |
| 738 | } |
| 739 | |
| 740 | pqScalarsToColors* lut = this->Representation->getLookupTable( |
| 741 | this->Internals->ColorMapEditorHelper->GetSelectedPropertiesType()); |
| 742 | if (this->ColorTransferFunction && this->ColorTransferFunction != lut) |
| 743 | { |
| 744 | this->disconnect(this->ColorTransferFunction); |
| 745 | this->ColorTransferFunction->disconnect(this); |
| 746 | this->ColorTransferFunction = nullptr; |
| 747 | } |
| 748 | if (lut) |
| 749 | { |
| 750 | this->ColorTransferFunction = lut; |
| 751 | this->setComponentNumber( |
| 752 | lut->getVectorMode() == pqScalarsToColors::MAGNITUDE ? -1 : lut->getVectorComponent()); |
| 753 | QObject::connect(lut, &pqScalarsToColors::componentOrModeChanged, this, |
| 754 | &pqDisplayColorWidget::updateColorTransferFunction, Qt::UniqueConnection); |
| 755 | } |
| 756 | } |
| 757 | |
| 758 | //----------------------------------------------------------------------------- |
| 759 | int pqDisplayColorWidget::addOutOfDomainEntry(int association, const QString& arrayName) |
no test coverage detected