From 31aa10eaae103c30e02d7dc6c71ff4e50de361b3 Mon Sep 17 00:00:00 2001
From: mrDarker <mr.darker@163.com>
Date: 星期一, 12 五月 2025 15:28:32 +0800
Subject: [PATCH] 1. 修改报警的显示模式(包括日志,需要后期修复) 2. 添加Release模式编译
---
SourceCode/Bond/Servo/AlarmDlg.cpp | 12 ++++++++++--
1 files changed, 10 insertions(+), 2 deletions(-)
diff --git a/SourceCode/Bond/Servo/AlarmDlg.cpp b/SourceCode/Bond/Servo/AlarmDlg.cpp
index 9db69a5..3ca1d9c 100644
--- a/SourceCode/Bond/Servo/AlarmDlg.cpp
+++ b/SourceCode/Bond/Servo/AlarmDlg.cpp
@@ -187,6 +187,7 @@
ON_WM_DESTROY()
ON_WM_CLOSE()
ON_WM_SIZE()
+ ON_WM_TIMER()
ON_CBN_SELCHANGE(IDC_COMBO_DATETIME, &CAlarmDlg::OnCbnSelchangeComboDatetime)
ON_BN_CLICKED(IDC_BUTTON_SEARCH, &CAlarmDlg::OnBnClickedButtonSearch)
ON_BN_CLICKED(IDC_BUTTON_EXPORT, &CAlarmDlg::OnBnClickedButtonExport)
@@ -199,7 +200,7 @@
BOOL CAlarmDlg::OnInitDialog()
{
CDialogEx::OnInitDialog();
- InitRxWindow();
+ SetTimer(1, 3000, nullptr);
// 涓嬫媺妗嗘帶浠�
CComboBox* pComboBox = (CComboBox*)GetDlgItem(IDC_COMBO_DATETIME);
@@ -244,7 +245,6 @@
pListCtrl->InsertColumn(6, _T("瑙i櫎鏃堕棿"), LVCFMT_LEFT, width[6]);
pListCtrl->InsertColumn(7, _T("鎻忚堪"), LVCFMT_LEFT, width[7]);
pListCtrl->SetColumnWidth(7, LVSCW_AUTOSIZE_USEHEADER);
-
// 璁$畻鎬婚〉鏁�
@@ -315,6 +315,14 @@
Resize();
}
+void CAlarmDlg::OnTimer(UINT_PTR nIDEvent)
+{
+ if (1 == nIDEvent) {
+ KillTimer(1);
+ InitRxWindow();
+ }
+}
+
void CAlarmDlg::OnCbnSelchangeComboDatetime()
{
CComboBox* pComboBox = (CComboBox*)GetDlgItem(IDC_COMBO_DATETIME);
--
Gitblit v1.9.3