⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 test_wmisampledlg.h

📁 windows 2000/xpWDM设备驱动程序开发光盘代码
💻 H
字号:
// Test_WMISampleDlg.h : header file
//

#if !defined(AFX_TEST_WMISAMPLEDLG_H__62CD07DB_7D39_4CCC_B20E_360915495348__INCLUDED_)
#define AFX_TEST_WMISAMPLEDLG_H__62CD07DB_7D39_4CCC_B20E_360915495348__INCLUDED_

#if _MSC_VER > 1000
#pragma once
#endif // _MSC_VER > 1000

#define WM_PRINTEVENT WM_USER+1

class Print_Event
{
public:
	CString Message;

	static HWND ViewHwnd;	// View Hwnd

	// Generate and send an event
	static void SendEvent( CString msg)
	{
		if( ViewHwnd==NULL) return;
		Print_Event* pEvent = new Print_Event;
		pEvent->Message = msg;
		::PostMessage( ViewHwnd, WM_PRINTEVENT, 0, (LPARAM)pEvent);
	}
};

/////////////////////////////////////////////////////////////////////////////
// CTest_WMISampleDlg dialog

class CTest_WMISampleDlg : public CDialog
{
// Construction
public:
	CTest_WMISampleDlg(CWnd* pParent = NULL);	// standard constructor
	virtual ~CTest_WMISampleDlg();
// Dialog Data
	//{{AFX_DATA(CTest_WMISampleDlg)
	enum { IDD = IDD_TEST_WMISAMPLE_DIALOG };
	CButton	m_Set;
	CButton	m_Reset;
	CButton	m_Inc;
	CButton	m_Dec;
	CButton	m_BtEventStop;
	CButton	m_BtEventStart;
	CButton	m_BtDataStop;
	CButton	m_BtDataStart;
	CListBox	m_LtEvent;
	//}}AFX_DATA
	HANDLE m_hDevice;

	// ClassWizard generated virtual function overrides
	//{{AFX_VIRTUAL(CTest_WMISampleDlg)
	protected:
	virtual void DoDataExchange(CDataExchange* pDX);	// DDX/DDV support
	//}}AFX_VIRTUAL

// Implementation
protected:
	HICON m_hIcon;

	// Generated message map functions
	//{{AFX_MSG(CTest_WMISampleDlg)
	virtual BOOL OnInitDialog();
	afx_msg void OnPaint();
	afx_msg HCURSOR OnQueryDragIcon();
	afx_msg void OnInc();
	afx_msg void OnDec();
	afx_msg void OnBtDataStart();
	afx_msg void OnBtDataStop();
	afx_msg void OnBtEventStop();
	afx_msg void OnBtEventStart();
	afx_msg void OnClose();
	afx_msg void OnReset();
	afx_msg void OnSet();
	//}}AFX_MSG
	afx_msg LONG OnPrintEvent( UINT, LONG);
	DECLARE_MESSAGE_MAP()
};

//{{AFX_INSERT_LOCATION}}
// Microsoft Visual C++ will insert additional declarations immediately before the previous line.

#endif // !defined(AFX_TEST_WMISAMPLEDLG_H__62CD07DB_7D39_4CCC_B20E_360915495348__INCLUDED_)

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -