int CMainFrame::OnCreate(LPCREATESTRUCT lpCreateStruct) { . . . if (!m_dlgBar.Create(this, IDD_DIALOGBAR, CBRS_LEFT | CBRS_TOOLTIPS | CBRS_FLYBY | CBRS_HIDE_INPLACE, IDD_DIALOGBAR)) { TRACE0("컨트롤 모음을 만들지 못했습니다.\n"); return -1; } m_dlgBar.EnableDocking(CBRS_ALIGN_LEFT | CBRS_ALIGN_RIGHT); EnableDocking(CBRS_ALIGN_ANY); DockControlBar(&m_dlgBar); InitDialogBar(); return 0; } void CMainFrame::InitDialogBar() { m_Button.Attach(((CBitmapButton*)m_dlgBar.GetDlgItem(IDC_BUTTON))->m_hwnd); m_Button.LoadBitmaps(IDB_BITMAP); m_Button.SizeToContent(); }
Dialog Property
* Bitmap = TRUE
* Notify = TRUE
* Owner Draw = TRUE
'MFC' 카테고리의 다른 글
[MFC] - 윈도우 전체에 대한 DC생성 (0) | 2014.09.08 |
---|