mirror of
https://github.com/qelectrotech/qelectrotech-source-mirror.git
synced 2026-03-23 23:59:58 +01:00
Minor : rebuild terminal vector everywhere is needed
This commit is contained in:
@@ -155,6 +155,7 @@ bool TerminalStrip::removeTerminal(Element *terminal)
|
|||||||
|
|
||||||
static_cast<TerminalElement *>(terminal)->setParentTerminalStrip(nullptr);
|
static_cast<TerminalElement *>(terminal)->setParentTerminalStrip(nullptr);
|
||||||
|
|
||||||
|
rebuildRealVector();
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -344,6 +345,7 @@ bool TerminalStrip::groupTerminals(const QSharedPointer<PhysicalTerminal> &recei
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
rebuildRealVector();
|
||||||
emit orderChanged();
|
emit orderChanged();
|
||||||
}
|
}
|
||||||
return true;
|
return true;
|
||||||
@@ -375,6 +377,7 @@ void TerminalStrip::unGroupTerminals(const QVector<QSharedPointer<RealTerminal>>
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (ungrouped) {
|
if (ungrouped) {
|
||||||
|
rebuildRealVector();
|
||||||
emit orderChanged();
|
emit orderChanged();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -395,6 +398,7 @@ bool TerminalStrip::setLevel(const QSharedPointer<RealTerminal> &real_terminal,
|
|||||||
if (physical_terminal->realTerminals().size() > 1 &&
|
if (physical_terminal->realTerminals().size() > 1 &&
|
||||||
physical_terminal->setLevelOf(real_terminal, level))
|
physical_terminal->setLevelOf(real_terminal, level))
|
||||||
{
|
{
|
||||||
|
rebuildRealVector();
|
||||||
emit orderChanged();
|
emit orderChanged();
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user