| 919 | } |
| 920 | |
| 921 | juce::Colour NodeComponent::getOutlineColour() const |
| 922 | { |
| 923 | if (node->getRootNetwork()->getRootNode() == node.get()) |
| 924 | return dynamic_cast<const Processor*>(node->getScriptProcessor())->getColour(); |
| 925 | |
| 926 | auto& exceptionHandler = node->getRootNetwork()->getExceptionHandler(); |
| 927 | |
| 928 | if (!exceptionHandler.isOk()) |
| 929 | { |
| 930 | auto error = exceptionHandler.getErrorMessage(node.get()); |
| 931 | |
| 932 | if (error.isNotEmpty()) |
| 933 | return JUCE_LIVE_CONSTANT_OFF(Colour(0xFFFF0000)); |
| 934 | } |
| 935 | |
| 936 | if (!header.colour.isTransparent()) |
| 937 | return header.colour; |
| 938 | |
| 939 | return header.isDragging ? Colour(0x88444444) : Colour(0xFF555555); |
| 940 | } |
| 941 | |
| 942 | juce::Colour NodeComponent::getHeaderColour() const |
| 943 | { |
no test coverage detected