From a4f4d9aa60ac7b9137047ed1e7dc8e1ef822ff19 Mon Sep 17 00:00:00 2001
From: LAPTOP-SNT8I5JK\Boounion <Chenluhua@qq.com>
Date: 星期三, 25 六月 2025 14:01:50 +0800
Subject: [PATCH] 1.日志窗口的自动流动模式和固定模式自动切换;

---
 SourceCode/Bond/Servo/CStep.cpp |   16 ++++++++++++++++
 1 files changed, 16 insertions(+), 0 deletions(-)

diff --git a/SourceCode/Bond/Servo/CStep.cpp b/SourceCode/Bond/Servo/CStep.cpp
index 0597e6e..4ac3dfd 100644
--- a/SourceCode/Bond/Servo/CStep.cpp
+++ b/SourceCode/Bond/Servo/CStep.cpp
@@ -91,6 +91,22 @@
 		m_attributeVector.addAttribute(pAttribute, TRUE);
 	}
 
+	void CStep::addAttributeVector(CAttributeVector& attributeVector)
+	{
+		// 添加attribute时,要前删除存在的同名的attribute
+		std::vector<CAttribute*>& srcs = attributeVector.getAttributes();
+		auto it = srcs.begin();
+		while (it != srcs.end()) {
+			BOOL bAdd = m_attributeVector.addAttribute((*it), TRUE);
+			if (bAdd) {
+				it = srcs.erase(it);
+			}
+			else {
+				++it;
+			}
+		}
+	}
+
 	void CStep::convertString(const char* pszBuffer, int size, std::string& strOut)
 	{
 		strOut.clear();

--
Gitblit v1.9.3