// =================================
// BATTLEZONE EDITOR CAMERA CONTROLS
// =================================

//
// CREATE THE LICENSE WINDOW
//
CreateControl("EditLicense", "STATIC")
{
	Geom("HCENTRE", "VCENTRE");
	Pos(0, 0);
	Size(500, 350);
	Style("MODAL", "TABROOT", "OUTLINE");
	BorderSize(10);
	BevelSize(5);
	TabSize(200, 10);
	TitleFont("MEDIUM");
	Title("License Agreement");

	//
	// create the text display
	//
	CreateControl("Text", "LISTBOX")
	{
		ColorGroup("BACKGROUND");
		Pos(0, 0);
		Size(500, 320);
		CellSize(485, 10);
		BorderSize(5);
		BevelSize(3);
		SliderPadding(5);
		Font("TINY");
		Style("INERT", "NOSELECTION", "VSLIDER");
		ItemConfig()
		{
			Style("TRANSPARENT");
		}
		FillFromFile("bzeditor_license.txt");
	}

	//
	// create the ok button
	//
	CreateControl("OK", "BUTTON")
	{
		ColorGroup("LISTBOX");
		Geom("LEFT", "BOTTOM");
		Pos(5, -5);
		Size(200, 10);
		BorderSize(5);
		BevelSize(3);
		Font("MEDIUM");
		Text("I Agree");
		Style("ROLLOVER");
		NotifyParent("Button::Press", "OK");
	}

	//
	// create the cancel button
	//
	CreateControl("Cancel", "BUTTON")
	{
		ColorGroup("LISTBOX");
		Geom("RIGHT", "BOTTOM");
		Pos(-5, -5);
		Size(200, 10);
		BorderSize(5);
		BevelSize(3);
		Font("MEDIUM");
		Text("I Disagree");
		Style("ROLLOVER");
		NotifyParent("Button::Press", "Cancel");
	}

	// handle the ok event
	OnEvent("OK")
	{
		Deactivate();
		Cmd("editor.accept");
	}

	// handle the cancel event
	OnEvent("Cancel")
	{
		Deactivate();
		Cmd("editor.reject");
	}
}

// Cmd("iface.activate EditLicense");

// ----------------- Auto accept agreement -------------------

Cmd("editor.accept");


