Browse Source

Reverse order of cable names in PortTooltip.

tags/v2.0.0
Andrew Belt 3 years ago
parent
commit
f96cf2dd71
1 changed files with 3 additions and 1 deletions
  1. +3
    -1
      src/app/PortWidget.cpp

+ 3
- 1
src/app/PortWidget.cpp View File

@@ -50,7 +50,9 @@ struct PortTooltip : ui::Tooltip {
text += string::f("% .3fV", math::normalizeZero(v)); text += string::f("% .3fV", math::normalizeZero(v));
} }
// Connected to // Connected to
for (CableWidget* cable : APP->scene->rack->getCablesOnPort(portWidget)) {
std::vector<CableWidget*> cables = APP->scene->rack->getCablesOnPort(portWidget);
for (auto it = cables.rbegin(); it != cables.rend(); it++) {
CableWidget* cable = *it;
PortWidget* otherPw = (portWidget->type == engine::Port::INPUT) ? cable->outputPort : cable->inputPort; PortWidget* otherPw = (portWidget->type == engine::Port::INPUT) ? cable->outputPort : cable->inputPort;
if (!otherPw) if (!otherPw)
continue; continue;


Loading…
Cancel
Save