1 ///////////////////////////////////////
\r
5 #include "MyDialog.h"
\r
6 #include "resource.h"
\r
9 // Definitions for the CMyDialog class
\r
10 CMyDialog::CMyDialog(UINT nResID, CWnd* pParent)
\r
11 : CDialog(nResID, pParent)
\r
15 CMyDialog::~CMyDialog()
\r
19 INT_PTR CMyDialog::DialogProc(UINT uMsg, WPARAM wParam, LPARAM lParam)
\r
21 // Pass resizing messages on to the resizer
\r
22 m_Resizer.HandleMessage(uMsg, wParam, lParam);
\r
26 // //Additional messages to be handled go here
\r
29 // Pass unhandled messages on to parent DialogProc
\r
30 return DialogProcDefault(uMsg, wParam, lParam);
\r
33 BOOL CMyDialog::OnInitDialog()
\r
36 SetIconLarge(IDW_MAIN);
\r
37 SetIconSmall(IDW_MAIN);
\r
39 // Attach the custom control to a CWnd object
\r
40 m_MyControl.AttachDlgItem(IDC_CUSTOMWEB, this);
\r
42 // Support automatic resizing
\r
43 m_Resizer.Initialize( this, CRect(0, 0, 300, 200) );
\r
44 m_Resizer.AddChild(m_MyControl, topleft, RD_STRETCH_WIDTH|RD_STRETCH_HEIGHT);
\r