code_production/cfg-tools/apps/scanner-check/CDlgItemMgr.h

61 lines
1.6 KiB
C
Raw Permalink Normal View History

2022-12-09 07:31:09 +00:00
#pragma once
// CDlgItemMgr 对话框
#include <string>
#include <vector>
#include "page.h"
class CDlgItemMgr : public CDialogEx
{
DECLARE_DYNAMIC(CDlgItemMgr)
public:
CDlgItemMgr(CWnd* pParent = nullptr); // 标准构造函数
virtual ~CDlgItemMgr();
// 对话框数据
#ifdef AFX_DESIGN_TIME
enum { IDD = IDD_TEST_ITEM };
#endif
protected:
virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV 支持
virtual BOOL OnInitDialog();
2023-01-04 10:23:36 +00:00
enum
{
STORE_FILE_SELF = 0,
STORE_FILE_BACKUP,
STORE_FILE_TEMP,
};
std::wstring get_stored_config_file(int type = STORE_FILE_SELF);
2022-12-09 07:31:09 +00:00
void load_from_file(const wchar_t* file);
void load_stored_config(void);
2023-01-04 10:23:36 +00:00
void init_sane_cfg(void);
int find_test_item(const wchar_t* name, known_file_util::IJsonW** jsn = NULL);
int find_sane_item(const wchar_t* name, known_file_util::IJsonW** jsn = NULL);
void save_test_template(int type = STORE_FILE_SELF);
known_file_util::IJsonW* test_tmpl_;
bool lst_trigger_sel_change_;
2022-12-09 07:31:09 +00:00
DECLARE_MESSAGE_MAP()
public:
CListCtrl list_;
afx_msg void OnNMDblclkList1(NMHDR* pNMHDR, LRESULT* pResult);
afx_msg void OnBnClickedButtonAdd();
2023-01-04 10:23:36 +00:00
known_file_util::IJsonW* get_all_items(void);
2022-12-09 07:31:09 +00:00
afx_msg void OnDropFiles(HDROP hDropInfo);
2023-01-04 10:23:36 +00:00
afx_msg void OnBnClickedButtonAdd2();
CListCtrl lst_param_;
CComboBox combo_param_;
CComboBox combo_param_val_;
afx_msg void OnCbnSelchangeComboParamName();
static void notify_combo_param_changed(void* param);
afx_msg void OnLvnItemchangedListVal(NMHDR* pNMHDR, LRESULT* pResult);
afx_msg void OnNMClickList1(NMHDR* pNMHDR, LRESULT* pResult);
afx_msg void OnBnClickedButtonSaveTemplate();
afx_msg void OnBnClickedButtonClear();
2022-12-09 07:31:09 +00:00
};