From 2a803976ed12e59f3e082e7c08941ef5004e6ea1 Mon Sep 17 00:00:00 2001
From: mrDarker <mr.darker@163.com>
Date: 星期二, 20 五月 2025 11:40:10 +0800
Subject: [PATCH] 1. 添加机器臂命令配置界面
---
SourceCode/Bond/Servo/CArm.cpp | 6 +++++-
1 files changed, 5 insertions(+), 1 deletions(-)
diff --git a/SourceCode/Bond/Servo/CArm.cpp b/SourceCode/Bond/Servo/CArm.cpp
index e698692..064ab30 100644
--- a/SourceCode/Bond/Servo/CArm.cpp
+++ b/SourceCode/Bond/Servo/CArm.cpp
@@ -56,13 +56,17 @@
int CArm::tempStore(CGlass* pGlass)
{
- // 保证列表中只存储一个物料
+ // 原:保证列表中只存储一个物料
+ // 修改为:先清空之前的,再添加当前pGlass, 如果pGlass有buddy,也要加入列表中
Lock();
for (auto item : m_glassList) {
item->release();
}
m_glassList.clear();
addGlassToList(pGlass);
+ if (pGlass->getBuddy() != nullptr) {
+ addGlassToList(pGlass->getBuddy());
+ }
Unlock();
if (m_listener.onDataChanged != nullptr) {
--
Gitblit v1.9.3