void GroupBlock::initInputPattern() {
foreach(AbstractInterface* iface, getControlInputs()) {
ConnectedInterface* connIface = AI_TO_CON(iface);
- connIface->setOutputPattern(connIface->getConnectedFrom()->getOutputPattern());
+ QList<char>* pattern = new QList<char>(*(connIface->getConnectedFrom()->getOutputPattern()));
+ connIface->setOutputPattern(pattern);
}
}
if (canCompute) {
foreach(AbstractInterface* iface, getControlOutputs()) {
ConnectedInterface* connIface = AI_TO_CON(iface);
- connIface->setOutputPattern(connIface->getConnectedFrom()->getOutputPattern());
+ QList<char>* pattern = new QList<char>(*(connIface->getConnectedFrom()->getOutputPattern()));
+ connIface->setOutputPattern(pattern);
}
setPatternComputed(true);
}