Specify _AFX_NO_MFC_CONTROLS_IN_DIALOGS and fix compiler warnings for Debug builds.