Files
firestorm/Gameleap/code/mw4/Code/MW4GameEd/ConfirmDlg.cpp
T
Cyd 2b8ca921cb Initial full mirror of c:\VWE (source + assets + toolchain + outputs) via Git LFS
Complete disaster-recovery snapshot: engine/game source, game data assets,
VC6 toolchain + DX SDKs, build outputs, deployed game, and _UNUSED archive.
Large binaries in Git LFS; text preserved byte-for-byte (core.autocrlf=false,
no eol attributes). See RECOVERY.md for the one-clone rebuild procedure.
2026-06-24 21:28:16 -05:00

77 lines
1.7 KiB
C++

// ConfirmDlg.cpp : implementation file
//
#include "stdafx.h"
#include "mw4gameed.h"
#include "ConfirmDlg.h"
/////////////////////////////////////////////////////////////////////////////
// CConfirmDlg dialog
CConfirmDlg::CConfirmDlg(int id, CWnd* pParent /*=NULL*/)
: CDialog(CConfirmDlg::IDD, pParent)
{
//{{AFX_DATA_INIT(CConfirmDlg)
m_NeverCheck = FALSE;
//}}AFX_DATA_INIT
m_ID = id;
m_Show = true;
m_Title = "";
m_MessageText = "No Text Was Specified!!!";
CString keyname = "ConfirmDlg";
char string[8];
keyname += itoa(m_ID,string,10);
DWORD size=sizeof(m_Show);
gos_LoadDataFromRegistry((char *)(LPCTSTR)keyname,&m_Show,&size);
}
void CConfirmDlg::DoDataExchange(CDataExchange* pDX)
{
CDialog::DoDataExchange(pDX);
//{{AFX_DATA_MAP(CConfirmDlg)
DDX_Control(pDX, IDC_CONFIRMTEXT, m_ConfirmText);
DDX_Check(pDX, IDC_CONFIRMCHECK, m_NeverCheck);
//}}AFX_DATA_MAP
}
BEGIN_MESSAGE_MAP(CConfirmDlg, CDialog)
//{{AFX_MSG_MAP(CConfirmDlg)
//}}AFX_MSG_MAP
END_MESSAGE_MAP()
/////////////////////////////////////////////////////////////////////////////
// CConfirmDlg message handlers
BOOL CConfirmDlg::OnInitDialog()
{
CDialog::OnInitDialog();
SetWindowText(m_Title);
m_ConfirmText.SetWindowText(m_MessageText);
return TRUE; // return TRUE unless you set the focus to a control
// EXCEPTION: OCX Property Pages should return FALSE
}
int CConfirmDlg::DoModal()
{
int retVal = IDOK;
if (m_Show)
retVal = CDialog::DoModal();
if (m_NeverCheck)
{
m_Show = false;
CString keyname = "ConfirmDlg";
char string[8];
keyname += itoa(m_ID,string,10);
gos_SaveDataToRegistry((char *)(LPCTSTR)keyname,&m_Show,sizeof(m_Show));
}
return retVal;
}