summaryrefslogtreecommitdiff
path: root/hammer/maperrorsdlg.cpp
blob: a37902258e37df5bbbf7d602a067e4044e23bd24 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
//========= Copyright Valve Corporation, All rights reserved. ============//
//
// Purpose: 
//
// $NoKeywords: $
//
//=============================================================================//
// MapErrorsDlg.cpp : implementation file
//

#include "stdafx.h"
#include "hammer.h"
#include "MapErrorsDlg.h"
#include "Error3d.h"

// memdbgon must be the last include file in a .cpp file!!!
#include <tier0/memdbgon.h>

/////////////////////////////////////////////////////////////////////////////
// CMapErrorsDlg dialog


CMapErrorsDlg::CMapErrorsDlg(CWnd* pParent /*=NULL*/)
	: CDialog(CMapErrorsDlg::IDD, pParent)
{
	//{{AFX_DATA_INIT(CMapErrorsDlg)
		// NOTE: the ClassWizard will add member initialization here
	//}}AFX_DATA_INIT
}


void CMapErrorsDlg::DoDataExchange(CDataExchange* pDX)
{
	CDialog::DoDataExchange(pDX);
	//{{AFX_DATA_MAP(CMapErrorsDlg)
	DDX_Control(pDX, IDC_ERRORS, m_cErrors);
	//}}AFX_DATA_MAP
}


BEGIN_MESSAGE_MAP(CMapErrorsDlg, CDialog)
	//{{AFX_MSG_MAP(CMapErrorsDlg)
	ON_BN_CLICKED(IDC_CLEAR, OnClear)
	ON_LBN_DBLCLK(IDC_ERRORS, OnDblclkErrors)
	ON_BN_CLICKED(IDC_VIEW, OnView)
	//}}AFX_MSG_MAP
END_MESSAGE_MAP()

/////////////////////////////////////////////////////////////////////////////
// CMapErrorsDlg message handlers

void CMapErrorsDlg::OnClear() 
{
}

void CMapErrorsDlg::OnDblclkErrors() 
{
}

void CMapErrorsDlg::OnView() 
{
}

BOOL CMapErrorsDlg::OnInitDialog() 
{
	CDialog::OnInitDialog();

	// fill list with errors
	error3d * pError = Enum3dErrors(TRUE);
	while(pError)
	{
		m_cErrors.AddString(pError->pszReason);
		m_cErrors.SetItemDataPtr(m_cErrors.GetCount()-1, PVOID(pError));
		pError = Enum3dErrors();
	}
	
	return TRUE;
}