From e48a55eb3cc807fa5a45cf398b6f523e96aa5312 Mon Sep 17 00:00:00 2001
From: LAPTOP-SNT8I5JK\Boounion <Chenluhua@qq.com>
Date: 星期二, 15 七月 2025 15:10:31 +0800
Subject: [PATCH] 1.Variable列表显示到界面; 2.从文件中加载CReport列表;
---
SourceCode/Bond/EAPSimulator/EAPSimulatorDlg.cpp | 23 +++++++++++++++++++++++
1 files changed, 23 insertions(+), 0 deletions(-)
diff --git a/SourceCode/Bond/EAPSimulator/EAPSimulatorDlg.cpp b/SourceCode/Bond/EAPSimulator/EAPSimulatorDlg.cpp
index 4609d25..6dca163 100644
--- a/SourceCode/Bond/EAPSimulator/EAPSimulatorDlg.cpp
+++ b/SourceCode/Bond/EAPSimulator/EAPSimulatorDlg.cpp
@@ -10,6 +10,7 @@
#include "Common.h"
#include <regex>
#include "CTerminalDisplayDlg.h"
+#include "CEDEventReportDlg.h"
#ifdef _DEBUG
@@ -77,6 +78,8 @@
ON_BN_CLICKED(IDC_BUTTON_ARE_YOU_THERE, &CEAPSimulatorDlg::OnBnClickedButtonAreYouThere)
ON_BN_CLICKED(IDC_BUTTON_DATETIME_SYNC, &CEAPSimulatorDlg::OnBnClickedButtonDatetimeSync)
ON_BN_CLICKED(IDC_BUTTON_TERMINAL_DISPLAY, &CEAPSimulatorDlg::OnBnClickedButtonTerminalDisplay)
+ ON_BN_CLICKED(IDC_BUTTON_ED_EVENT_REPORT, &CEAPSimulatorDlg::OnBnClickedButtonEdEventReport)
+ ON_BN_CLICKED(IDC_BUTTON_ED_ALARM_REPORT, &CEAPSimulatorDlg::OnBnClickedButtonEdAlarmReport)
END_MESSAGE_MAP()
@@ -164,6 +167,7 @@
SetDlgItemInt(IDC_EDIT_PORT, 7000);
SetGroup2Enabled(FALSE);
SetGroup1Enabled(TRUE);
+ ::SetProp(GetDlgItem(IDC_BUTTON_ED_ALARM_REPORT)->m_hWnd, _T("Enable"), (void*)1);
// log edit
@@ -255,6 +259,8 @@
GetDlgItem(IDC_BUTTON_ARE_YOU_THERE)->EnableWindow(enabled);
GetDlgItem(IDC_BUTTON_DATETIME_SYNC)->EnableWindow(enabled);
GetDlgItem(IDC_BUTTON_TERMINAL_DISPLAY)->EnableWindow(enabled);
+ GetDlgItem(IDC_BUTTON_ED_EVENT_REPORT)->EnableWindow(enabled);
+ GetDlgItem(IDC_BUTTON_ED_ALARM_REPORT)->EnableWindow(enabled);
}
void CEAPSimulatorDlg::OnBnClickedButtonConnect()
@@ -287,3 +293,20 @@
CTerminalDisplayDlg dlg;
dlg.DoModal();
}
+
+void CEAPSimulatorDlg::OnBnClickedButtonEdEventReport()
+{
+ CEDEventReportDlg dlg;
+ dlg.DoModal();
+}
+
+void CEAPSimulatorDlg::OnBnClickedButtonEdAlarmReport()
+{
+ int enable = (int)::GetProp(GetDlgItem(IDC_BUTTON_ED_ALARM_REPORT)->m_hWnd, _T("Enable"));
+ enable = enable == 0 ? 1 : 0;
+ theApp.m_model.m_pHsmsActive->hsmsEDAlarmReport(enable == 1, 0);
+
+ SetDlgItemText(IDC_BUTTON_ED_ALARM_REPORT,
+ enable == 1 ? _T("Disable Alarm Report") : _T("Enable Alarm Report"));
+ ::SetProp(GetDlgItem(IDC_BUTTON_ED_ALARM_REPORT)->m_hWnd, _T("Enable"), (void*)enable);
+}
--
Gitblit v1.9.3