Skip to content

Commit

Permalink
fix using wildcards for targetParameter now links to the target's value
Browse files Browse the repository at this point in the history
  • Loading branch information
benkuper committed Sep 18, 2024
1 parent 386292f commit 01bd60f
Showing 1 changed file with 12 additions and 3 deletions.
15 changes: 12 additions & 3 deletions Source/Common/ParameterLink/ParameterLink.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ ParameterLink::~ParameterLink()
isLinkBeingDestroyed = true;

paramLinkNotifier.cancelPendingUpdate();

if (list != nullptr && !listRef.wasObjectDeleted())
{
list->removeMultiplexListListener(this);
Expand Down Expand Up @@ -296,10 +296,19 @@ String ParameterLink::getReplacementString(int multiplexIndex)
{
if (BaseMultiplexList* curList = multiplex->listManager.getItemWithName(dotSplit[1]))
{

if (Parameter* lp = dynamic_cast<Parameter*>(curList->list[multiplexIndex]))
{
result += lp->stringValue();
if (lp->type == Controllable::TARGET)
{
if (Parameter* ltp = dynamic_cast<Parameter*>(((TargetParameter*)lp)->getTargetControllable()))
{
result += ltp->stringValue();
}
else
{
result += lp->stringValue();
}
}
}
else
{
Expand Down

0 comments on commit 01bd60f

Please sign in to comment.