_DEBUG modal dialogs
| 490 | #endif //_DEBUG |
| 491 | // modal dialogs |
| 492 | INT_PTR DoModal(HWND hWndParent = ::GetActiveWindow(), LPARAM dwInitParam = NULL) |
| 493 | { |
| 494 | ATLASSERT(m_hWnd == NULL); |
| 495 | |
| 496 | T* pT = static_cast<T*>(this); |
| 497 | pT->ConstructDialogResource(); |
| 498 | |
| 499 | ATLASSERT((bool)m_dynamicDialogTemplate); |
| 500 | _AtlWinModule.AddCreateWndData(&m_thunk.cd, (ATL::CDialogImplBaseT< TBase >*)this); |
| 501 | #ifdef _DEBUG |
| 502 | m_bModal = true; |
| 503 | #endif //_DEBUG |
| 504 | //return ::DialogBoxParam(_AtlBaseModule.GetResourceInstance(), MAKEINTRESOURCE(static_cast<T*>(this)->IDD), |
| 505 | // hWndParent, T::StartDialogProc, dwInitParam); |
| 506 | return ::DialogBoxIndirectParam(_AtlBaseModule.GetResourceInstance(), m_dynamicDialogTemplate, |
| 507 | hWndParent, T::StartDialogProc, dwInitParam); |
| 508 | } |
| 509 | BOOL EndDialog(int nRetCode) |
| 510 | { |
| 511 | ATLASSERT(::IsWindow(m_hWnd)); |
nothing calls this directly
no test coverage detected