| 752 | } // autoConnectNodes |
| 753 | |
| 754 | NodePtr |
| 755 | NodeCollectionPrivate::findNodeInternal(const std::string& name, |
| 756 | const std::string& recurseName) const |
| 757 | { |
| 758 | QMutexLocker k(&nodesMutex); |
| 759 | |
| 760 | for (NodesList::const_iterator it = nodes.begin(); it != nodes.end(); ++it) { |
| 761 | if ( (*it)->getScriptName_mt_safe() == name ) { |
| 762 | if ( !recurseName.empty() ) { |
| 763 | NodeGroup* isGrp = (*it)->isEffectGroup(); |
| 764 | if (isGrp) { |
| 765 | return isGrp->getNodeByFullySpecifiedName(recurseName); |
| 766 | } else { |
| 767 | NodesList children; |
| 768 | (*it)->getChildrenMultiInstance(&children); |
| 769 | for (NodesList::iterator it2 = children.begin(); it2 != children.end(); ++it2) { |
| 770 | if ( (*it2)->getScriptName_mt_safe() == recurseName ) { |
| 771 | return *it2; |
| 772 | } |
| 773 | } |
| 774 | } |
| 775 | } else { |
| 776 | return *it; |
| 777 | } |
| 778 | } |
| 779 | } |
| 780 | |
| 781 | return NodePtr(); |
| 782 | } |
| 783 | |
| 784 | NodePtr |
| 785 | NodeCollection::getNodeByName(const std::string & name) const |
no test coverage detected