PeeperFrm.h
Upload User: xztxsm
Upload Date: 2007-02-12
Package Size: 150k
Code Size: 4k
Category:

Remote Control

Development Platform:

Visual C++

  1. ///////////////////////////////////////////////////////////////////////////////
  2. // 远程控制软件-偷窥者  主窗口                                               //
  3. // 日期:2001/10/02                                                           //
  4. // 作者:刘东发                                                               //
  5. // Email:dongfa@yeah.net                                                     //
  6. // http://dongfa.yeah.net                                                    //
  7. // OICQ:5584173  阿东                                                        //
  8. // 作者声明:                                                                 //
  9. //     此部分代码全是作者所写,可以随便传播,但要保持文件的完整性,有问题     //
  10. // 或者意见请来信,谢谢!                                                      //
  11. ///////////////////////////////////////////////////////////////////////////////
  12. #ifndef __PEEPER_FRAME_H__
  13. #define __PEEPER_FRAME_H__
  14. #include "../PeeperMenu.h"
  15. class CMainClientWnd : public CWnd
  16. {
  17. public:
  18. CMainClientWnd();
  19. virtual ~CMainClientWnd();
  20. BOOL SetBkBitmap(HBITMAP hBmp, BOOL bStretch = FALSE);
  21. BOOL PaintBmp();
  22. protected:
  23. CDC  m_memDC;
  24. SIZE m_szBmp;
  25. BOOL m_bStretch;
  26. public:
  27. //{{AFX_VIRTUAL(CMainClientWnd)
  28. //}}AFX_VIRTUAL
  29. protected:
  30. //{{AFX_MSG(CMainClientWnd)
  31. afx_msg void OnPaint();
  32. //}}AFX_MSG
  33. DECLARE_MESSAGE_MAP()
  34. };
  35. class CChildFrame : public CMDIChildWnd
  36. {
  37. DECLARE_DYNCREATE(CChildFrame)
  38. public:
  39. CChildFrame();
  40. virtual ~CChildFrame();
  41. public:
  42. //{{AFX_VIRTUAL(CChildFrame)
  43. virtual BOOL PreCreateWindow(CREATESTRUCT& cs);
  44. //}}AFX_VIRTUAL
  45. protected:
  46. //{{AFX_MSG(CChildFrame)
  47. afx_msg void OnGetMinMaxInfo(MINMAXINFO FAR* lpMMI);
  48. afx_msg int OnCreate(LPCREATESTRUCT lpCreateStruct);
  49. afx_msg void OnMDIActivate(BOOL bActivate, CWnd* pActivateWnd, CWnd* pDeactivateWnd);
  50. //}}AFX_MSG
  51. DECLARE_MESSAGE_MAP()
  52. };
  53. class CPeeperBar : public CDialogBar
  54. {
  55. public:
  56. CPeeperBar();
  57. virtual ~CPeeperBar();
  58. public:
  59. //{{AFX_VIRTUAL(CPeeperBar)
  60. //}}AFX_VIRTUAL
  61. protected:
  62. //{{AFX_MSG(CPeeperBar)
  63. //}}AFX_MSG
  64. DECLARE_MESSAGE_MAP()
  65. };
  66. class CPeeperWnd;
  67. class CPeeperClientDoc;
  68. class CMainFrame : public CMDIFrameWnd
  69. {
  70. DECLARE_DYNAMIC(CMainFrame)
  71. public:
  72. CMainFrame();
  73. virtual ~CMainFrame();
  74. CChildFrame *GetCurFrame();
  75. CPeeperWnd *GetCurPeeperWnd();
  76. CPeeperClientDoc *GetCurPeeperDoc();
  77. public:
  78. //{{AFX_VIRTUAL(CMainFrame)
  79. public:
  80. virtual BOOL PreCreateWindow(CREATESTRUCT& cs);
  81. virtual BOOL PreTranslateMessage(MSG* pMsg);
  82. //}}AFX_VIRTUAL
  83. public:
  84. CStatusBar  m_wndStatusBar;
  85. CToolBar    m_wndToolBar;
  86. CPeeperBar  m_wndCommand;
  87. CPeeperBar  m_wndFile;
  88. CPeeperBar  m_wndComputer;
  89. CToolBar    m_wndDibView;
  90. // for full screen
  91. CRect       m_rcOldRect;
  92. int         m_nOldCmdShow;
  93. BOOL        m_bIsFullScreen;
  94. CMainClientWnd m_wndClientWnd;
  95. protected:
  96. CPeeperMenu m_hPeeperMenu;
  97. CPeeperMenu m_hPeeperClientMenu;
  98. CPeeperMenu m_hPeeperSysMenu;
  99. public:
  100. BOOL PeeperMenuAttach(HMENU hMenu);
  101. BOOL PeeperClientMenuAttach(HMENU hMenu);
  102. void OnExecCommand();
  103. void OnExecComputer();
  104. void OnExecFile();
  105. void OnFullScreen();
  106. void OnFileClose();
  107. void OnFileNew();
  108. int  GetClientCount();
  109. protected:
  110. //{{AFX_MSG(CMainFrame)
  111. afx_msg int OnCreate(LPCREATESTRUCT lpCreateStruct);
  112. afx_msg void OnMenuCommand();
  113. afx_msg void OnUpdateMenuCommand(CCmdUI* pCmdUI);
  114. afx_msg void OnGetMinMaxInfo(MINMAXINFO FAR* lpMMI);
  115. afx_msg void OnDrawItem(int nIDCtl, LPDRAWITEMSTRUCT lpDrawItemStruct);
  116. afx_msg void OnMeasureItem(int nIDCtl, LPMEASUREITEMSTRUCT lpMeasureItemStruct);
  117. //}}AFX_MSG
  118. DECLARE_MESSAGE_MAP()
  119. };
  120. #endif //__PEEPER_FRAME_H__