home *** CD-ROM | disk | FTP | other *** search
/ Master Visual C++ 1.5 / MASTERVC15.ISO / vcprog / original / appendix / multi / mainfrm.cpp next >
Encoding:
C/C++ Source or Header  |  1994-02-11  |  1.6 KB  |  79 lines

  1. // mainfrm.cpp : implementation of the CMainFrame class
  2. //
  3.  
  4. #include "stdafx.h"
  5. #include "multi.h"
  6.  
  7. #include "mainfrm.h"
  8.  
  9. #ifdef _DEBUG
  10. #undef THIS_FILE
  11. static char BASED_CODE THIS_FILE[] = __FILE__;
  12. #endif
  13.  
  14. /////////////////////////////////////////////////////////////////////////////
  15. // CMainFrame
  16.  
  17. IMPLEMENT_DYNCREATE(CMainFrame, CFrameWnd)
  18.  
  19. BEGIN_MESSAGE_MAP(CMainFrame, CFrameWnd)
  20.     //{{AFX_MSG_MAP(CMainFrame)
  21.         // NOTE - the ClassWizard will add and remove mapping macros here.
  22.         //    DO NOT EDIT what you see in these blocks of generated code !
  23.     //}}AFX_MSG_MAP
  24. END_MESSAGE_MAP()
  25.  
  26. /////////////////////////////////////////////////////////////////////////////
  27. // CMainFrame construction/destruction
  28.  
  29. CMainFrame::CMainFrame()
  30. {
  31.     // TODO: add member initialization code here
  32. }
  33.  
  34. CMainFrame::~CMainFrame()
  35. {
  36. }
  37.  
  38. /////////////////////////////////////////////////////////////////////////////
  39. // CMainFrame diagnostics
  40.  
  41. #ifdef _DEBUG
  42. void CMainFrame::AssertValid() const
  43. {
  44.     CFrameWnd::AssertValid();
  45. }
  46.  
  47. void CMainFrame::Dump(CDumpContext& dc) const
  48. {
  49.     CFrameWnd::Dump(dc);
  50. }
  51.  
  52. #endif //_DEBUG
  53.  
  54. /////////////////////////////////////////////////////////////////////////////
  55. // CMainFrame message handlers
  56.  
  57. //////////////////////
  58. // MY CODE STARTS HERE
  59. //////////////////////
  60.  
  61. BOOL CMainFrame::PreCreateWindow(CREATESTRUCT& cs)
  62. {
  63.  
  64.     // Call the base class function.
  65.     CFrameWnd::PreCreateWindow( cs );
  66.  
  67.     // Set the width of the window to 520.
  68.     cs.cx = 520;
  69.  
  70.     // Set the height of the window to 300.
  71.     cs.cy = 300;
  72.  
  73.     return TRUE;
  74. }
  75.  
  76. ////////////////////
  77. // MY CODE ENDS HERE
  78. ////////////////////
  79.