📄 maindlg.h
字号:
#if !defined(AFX_MAINDLG_H__533B2F42_BFEA_4788_B278_4C4EA7A80CEC__INCLUDED_)
#define AFX_MAINDLG_H__533B2F42_BFEA_4788_B278_4C4EA7A80CEC__INCLUDED_
#if _MSC_VER > 1000
#pragma once
#endif // _MSC_VER > 1000
// MainDlg.h : header file
//
#include "CommonInc.h"
#include "ElevatorDlg.h"
#include "CircleSingleLink.h"
/*####################################################################
模块名称: 主控中心
开发作者: 漫步阳光
开发时间: @2005.11
####################################################################*/
/////////////////////////////////////////////////////////////////////////////
// CMainDlg dialog
class CMainDlg : public CDialog
{
// Construction
public:
CMainDlg(CWnd* pParent = NULL); // standard constructor
// Dialog Data
//{{AFX_DATA(CMainDlg)
enum { IDD = IDD_MAINDLG };
//}}AFX_DATA
// Overrides
// ClassWizard generated virtual function overrides
//{{AFX_VIRTUAL(CMainDlg)
protected:
virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV support
//}}AFX_VIRTUAL
// Implementation
protected:
CElevatorDlg *m_elevatorArr[ELEVATOR_NUM];//电梯数组!
// Generated message map functions
//{{AFX_MSG(CMainDlg)
afx_msg void OnDestroy();
virtual BOOL OnInitDialog();
virtual void OnCancel();
afx_msg void OnBtnAbout();
afx_msg void OnTimer(UINT nIDEvent);
afx_msg int OnCreate(LPCREATESTRUCT lpCreateStruct);
//}}AFX_MSG
afx_msg LONG OnOneFloorArrived(WPARAM wP,LPARAM lP);
DECLARE_MESSAGE_MAP()
private:
CButton * m_pFloorButton[10][2];//楼层按钮
CircleSingleLink<sOuterRequest> lWaitQueue;//等待队列
CStdioFile m_cLogFile;//日志文件
CFileException m_Except;
char str_arrElevatorName[ELEVATOR_NUM];//电梯标识串
int iTotalFailTimes;
private:
void OnFloorBtnClk(UINT curBtn);
sOuterRequest No2ReqStruct(int iNo);
int ReqStruct2No(const sOuterRequest& tmpRequest);
int Goodness(const sOuterRequest& tmpOuterRequest);
void Schedule();
void trytoSchedule(sOuterRequest& tmpRequest);
void Write2Log(const CString& content);
};
#endif // !defined(AFX_MAINDLG_H__533B2F42_BFEA_4788_B278_4C4EA7A80CEC__INCLUDED_)
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -