// Eg11_1View.h : interface of the CEg11_1View class
//
/////////////////////////////////////////////////////////////////////////////

#if !defined(AFX_EG11_1VIEW_H__9A59C856_5E8B_4212_8FEB_CB1BC6B17540__INCLUDED_)
#define AFX_EG11_1VIEW_H__9A59C856_5E8B_4212_8FEB_CB1BC6B17540__INCLUDED_

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


class CEg11_1View : public CFormView
{
protected: // create from serialization only
	CEg11_1View();
	DECLARE_DYNCREATE(CEg11_1View)

public:
	//{{AFX_DATA(CEg11_1View)
	enum{ IDD = IDD_EG11_1_FORM };
		// NOTE: the ClassWizard will add data members here
	//}}AFX_DATA

// Attributes
public:
	CEg11_1Doc* GetDocument();
	//事件对象，表示计算机出牌完成，等待游戏者出牌
    CEvent  m_computerready;
	//事件对象，表示游戏者出牌完成，等待计算机出牌
	CEvent  m_playerready;
	//游戏正在进行的标志
	BOOL m_playing;
	//当前牌局中牌的张数
	int m_cardnum;
	//当前计算机成绩即计算机牌的张数
	int m_computernum;
	//当前游戏者牌的牌的张数
	int m_playernum;
	//当前牌局
	int m_card[100];
// Operations
public:
	void play();
	void showcard();
    friend  UINT   CompThread(LPVOID lpParameter);
    friend  UINT   PlayerThread(LPVOID lpParameter);

// Overrides
	// ClassWizard generated virtual function overrides
	//{{AFX_VIRTUAL(CEg11_1View)
	public:
	virtual BOOL PreCreateWindow(CREATESTRUCT& cs);
	protected:
	virtual void DoDataExchange(CDataExchange* pDX);    // DDX/DDV support
	virtual void OnInitialUpdate(); // called first time after construct
	virtual BOOL OnPreparePrinting(CPrintInfo* pInfo);
	virtual void OnBeginPrinting(CDC* pDC, CPrintInfo* pInfo);
	virtual void OnEndPrinting(CDC* pDC, CPrintInfo* pInfo);
	virtual void OnPrint(CDC* pDC, CPrintInfo* pInfo);
	//}}AFX_VIRTUAL

// Implementation
public:
	virtual ~CEg11_1View();
#ifdef _DEBUG
	virtual void AssertValid() const;
	virtual void Dump(CDumpContext& dc) const;
#endif

protected:

// Generated message map functions
protected:
	//{{AFX_MSG(CEg11_1View)
	afx_msg void OnFileBegin();
	afx_msg void OnDiscard();
	afx_msg void OnFileEnd();
	//}}AFX_MSG
	DECLARE_MESSAGE_MAP()
};

#ifndef _DEBUG  // debug version in Eg11_1View.cpp
inline CEg11_1Doc* CEg11_1View::GetDocument()
   { return (CEg11_1Doc*)m_pDocument; }
#endif

/////////////////////////////////////////////////////////////////////////////

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

#endif // !defined(AFX_EG11_1VIEW_H__9A59C856_5E8B_4212_8FEB_CB1BC6B17540__INCLUDED_)
