MFC 貪喫蛇

BOOL CMainFrame::PreCreateWindow(CREATESTRUCT& cs)
{
 if( !CFrameWnd::PreCreateWindow(cs) )
  return FALSE;
 cs.cx=535;//設置窗口長度
 cs.cy=605;//設置窗口寬度
 // TODO: Modify the Window class or styles here by modifying
 //  the CREATESTRUCT cs

 return TRUE;
}

 

int CMainFrame::OnCreate(LPCREATESTRUCT lpCreateStruct)
{
 .....

 // TODO: Delete these three lines if you don't want the toolbar to
 //  be dockable
 m_wndToolBar.EnableDocking(CBRS_ALIGN_ANY);
 EnableDocking(CBRS_ALIGN_ANY);
 DockControlBar(&m_wndToolBar);

 CMenu menu;//載入自定義菜單
 menu.LoadMenu(IDR_MENUMOVEPOINT);
 this->SetMenu(&menu);

 return 0;
}

 

pointmoveView.cpp

發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章