| 719 | } |
| 720 | |
| 721 | void RcxController::renameNode(int nodeIdx, const QString& newName) { |
| 722 | if (nodeIdx < 0 || nodeIdx >= m_doc->tree.nodes.size()) return; |
| 723 | auto& node = m_doc->tree.nodes[nodeIdx]; |
| 724 | m_doc->undoStack.push(new RcxCommand(this, |
| 725 | cmd::Rename{node.id, node.name, newName})); |
| 726 | } |
| 727 | |
| 728 | void RcxController::insertNode(uint64_t parentId, int offset, NodeKind kind, const QString& name) { |
| 729 | Node n; |