summaryrefslogtreecommitdiff
path: root/utils/vconfig/ManageGamesDialog.h
blob: d73121e9dafdc2dcb086bcc03e0673e99fac260a (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
//========= Copyright Valve Corporation, All rights reserved. ============//
//
// Purpose: 
//
//=============================================================================

#ifndef MANAGEGAMESDIALOG_H
#define MANAGEGAMESDIALOG_H
#ifdef _WIN32
#pragma once
#endif

#include <vgui_controls/Frame.h>
#include <vgui_controls/TextEntry.h>
#include <vgui_controls/PHandle.h>

using namespace vgui;

//-----------------------------------------------------------------------------
// Purpose: Main dialog for media browser
//-----------------------------------------------------------------------------
class CManageGamesDialog : public Frame
{
	DECLARE_CLASS_SIMPLE( CManageGamesDialog, Frame );

public:

	CManageGamesDialog( Panel *parent, const char *name, int configID );
	virtual ~CManageGamesDialog();

	void	SetGameDir( const char *szDir );
	void	SetGameName( const char *szDir );

protected:
	
	virtual void OnCommand( const char *command );
	
	bool	IsGameNameUnique( const char *name );

private:

	int					m_nConfigID;
	
	vgui::TextEntry		*m_pGameNameEntry;
	vgui::TextEntry		*m_pGameDirEntry;

	MESSAGE_FUNC_CHARPTR( OnChooseDirectory, "DirectorySelected", dir );
};


extern CManageGamesDialog *g_pManageGamesDialog;


#endif // MANAGEGAMESDIALOG_H