📄 eluoshiview.h
字号:
// eluoshiView.h : interface of the CEluoshiView class
//
/////////////////////////////////////////////////////////////////////////////
#if !defined(AFX_ELUOSHIVIEW_H__7B72C60A_2CFE_48C9_895F_5B808D131621__INCLUDED_)
#define AFX_ELUOSHIVIEW_H__7B72C60A_2CFE_48C9_895F_5B808D131621__INCLUDED_
#if _MSC_VER > 1000
#pragma once
#endif // _MSC_VER > 1000
#define MAP_STATE_EMPTY 0
#define MAP_STATE_NOT_EMPTY 1
#define LEFT 2
#define RIGHT 3
#define UP 4
#define DOWN 5
class CEluoshiView : public CView
{
protected: // create from serialization only
CEluoshiView();
DECLARE_DYNCREATE(CEluoshiView)
// Attributes
public:
CEluoshiDoc* GetDocument();
// Operations
public:
BOOL m_bGamePaush;
BOOL m_bGameEnd;
int m_iLevel;
int m_icurrentStatus;
int m_inextStatus;
BOOL m_isBottom;
int m_currentRect;
int InterFace[74][4];
int GameStatus[24][20];
CDC m_memDC;
CBitmap m_memBmp;
CDC m_memRectDC;
CBitmap m_memRectBmp;
//HBITMAP m_hMemRectBmp;
int m_iLarge;
int m_iStartX;
int m_iStartY;
int m_nWidth;
int m_nHeight;
int m_iCol;
int m_iRow;
int ActiveStatus[4][2];
int NextStatus[4][2];
int m_iPerformance;
CPen* m_pBlackPen;
CBrush* m_pGrayBrush;
CBrush* m_pBlackBrush;
// Overrides
// ClassWizard generated virtual function overrides
//{{AFX_VIRTUAL(CEluoshiView)
public:
virtual void OnDraw(CDC* pDC); // overridden to draw this view
virtual BOOL PreCreateWindow(CREATESTRUCT& cs);
protected:
virtual BOOL OnPreparePrinting(CPrintInfo* pInfo);
virtual void OnBeginPrinting(CDC* pDC, CPrintInfo* pInfo);
virtual void OnEndPrinting(CDC* pDC, CPrintInfo* pInfo);
//}}AFX_VIRTUAL
// Implementation
public:
void GameInitnal();
BOOL IsRightLimit();
void DrawGame(CDC *pDC);
void DCEnvClear();
void DcEnvInitial(void);
void RectTangle();
BOOL IsLeftLimit();
void RectArrow(int m_Type);
void InvalidateCurrent();
void RectDown();
void ISBottom();
void ActiveStatusToGameStatus();
void RectStatusToActiveStatus(int m_which);
void RectStatusToNextStatus(int m_which);
int Random(int MaxNumber);
virtual ~CEluoshiView();
#ifdef _DEBUG
virtual void AssertValid() const;
virtual void Dump(CDumpContext& dc) const;
#endif
protected:
// Generated message map functions
protected:
//{{AFX_MSG(CEluoshiView)
afx_msg void OnGameStart();
afx_msg void OnGamePaush();
afx_msg void OnGameEnd();
afx_msg void OnTimer(UINT nIDEvent);
afx_msg void OnKeyDown(UINT nChar, UINT nRepCnt, UINT nFlags);
//}}AFX_MSG
DECLARE_MESSAGE_MAP()
};
#ifndef _DEBUG // debug version in eluoshiView.cpp
inline CEluoshiDoc* CEluoshiView::GetDocument()
{ return (CEluoshiDoc*)m_pDocument; }
#endif
/////////////////////////////////////////////////////////////////////////////
//{{AFX_INSERT_LOCATION}}
// Microsoft Visual C++ will insert additional declarations immediately before the previous line.
#endif // !defined(AFX_ELUOSHIVIEW_H__7B72C60A_2CFE_48C9_895F_5B808D131621__INCLUDED_)
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -