#include "Resource.h" class CMyApp : public CWinApp { public: virtual BOOL InitInstance (); }; class mwin2 : public CFrameWnd { public : mwin2(CFrameWnd* p); CFrameWnd* parent; // pointer to parent window CClientDC* mdc; // main device context CRect mrect; // main rectangle CBitmapButton* button1; CEdit* edit1; // editible text field protected: afx_msg void hbutton1(); DECLARE_MESSAGE_MAP () }; class mwin : public CFrameWnd { public : mwin(); CClientDC* mdc; // main device context CRect mrect; // main rectangle CEdit* edit1; // editible text field CBitmap* blankbm; // blank bit map CBitmap* bmap[BMN]; CDC* bdc; // bitmap memory dc CButton* button1; CAnimateCtrl* movie; // an animation common control mwin2* win2; // second window created by OnAct1 CWinThread* mythread; // two threads CWinThread* yourthread; static UINT myfunc (LPVOID w); // LPVOID = pointer to any type protected: afx_msg void OnNew(); afx_msg void OnOpen(); afx_msg void OnSave(); afx_msg void OnExit(); afx_msg void OnAct1(); afx_msg void OnAct2(); afx_msg void hbutton1(); //afx_msg void hbutton2(); afx_msg void OnVScroll (UINT, UINT, CScrollBar*); DECLARE_MESSAGE_MAP () };