/*
	$Id: inputdialog.cpp,v 1.11 2004/01/15 09:37:59 sphair Exp $
	
	ClanGUI, copyrights by various people. Have a look in the CREDITS file.
	
	This sourcecode is distributed using the Library GNU Public Licence,
	version 2 or (at your option) any later version. Please read LICENSE
	for details.
*/

#include "precomp.h"
#include <string>
#include "API/GUI/inputdialog.h"
#include "API/GUI/stylemanager.h"
#include "API/GUI/gui_manager.h"
#include "API/Core/XML/dom_element.h"
#include "inputdialog_generic.h"

/////////////////////////////////////////////////////////////////////////////
// Construction:

CL_InputDialog::CL_InputDialog(
	const std::string &title,
	const std::string &button1,
	const std::string &button2,
	const std::string &button3,
	CL_Component *parent,
	CL_StyleManager *style)
: CL_Window(parent, style), impl(0)
{
	impl = new CL_InputDialog_Generic(this, title, button1, button2, button3);
}

CL_InputDialog::~CL_InputDialog()
{
	delete impl;
}

/////////////////////////////////////////////////////////////////////////////
// Operations:

int CL_InputDialog::get_result_button()
{
	return impl->result_button;
}

CL_InputBox * CL_InputDialog::add_input_box(const std::string &label,
	const std::string &default_value, int inputbox_width)
{
	return impl->add_input_box(label, default_value, inputbox_width);
}

CL_CheckBox * CL_InputDialog::add_check_box(const std::string &text,
		bool enabled, int check_box_width)
{
	return impl->add_check_box(text, enabled, check_box_width);
}
