#pragma once

#include <Widgets/Panel.h>
#include <Widgets/Label.h>
#include "../Mechanics/PlayerGame.h"
#include <sstream>
#include <Widgets/Organizers/LinearOrganizer.h>
#include "../Mechanics/Townsfolk.h"
#include "../Mechanics/Soldier.h"
#include <Widgets/Window.h>
#include <Widgets/DialogWindow.h>
#include <Widgets/Listbox.h>
#include "../Assets/Buildings.h"
#include "../Mechanics/Artisan.h"
#include "Actions.h"
#include "Credits.h"
#include <Widgets/InlinePanel.h>

//for vs
#undef interface

namespace interface {

	class TitleMenu : public gge::widgets::InlinePanel {
	public:
		TitleMenu() {
			SetOrganizer(organizer);
			organizer.SetDistance(5);

			SetWidth(160);

			newgame.Text="New game";
			newgame.SetContainer(this);
			newgame.ClickEvent.RegisterLambda(showTitleMapSelection);

			options.Text="Options";
			options.SetContainer(this);
			options.Disable();

			credits.Text="Credits";
			credits.SetContainer(this);
			credits.ClickEvent.RegisterLambda(showTitleCredits);

			quit.Text="Quit";
			quit.SetContainer(this);
			quit.ClickEvent.Register(&askQuit);

			SetHeight(quit.GetBounds().Bottom+40);
		}

	protected:
		gge::widgets::ListOrganizer organizer;

		gge::widgets::Button
			newgame,
			options,
			credits,
			quit
			;

	};

}
