//---------------------------------------------------------------------------

#include <vcl.h>
#pragma hdrstop
#include <tchar.h>
//---------------------------------------------------------------------------




USEFORM("FormAbout.cpp", AboutForm);
USEFORM("FormDebug.cpp", DebugForm);
USEFORM("FormDiag.cpp", DiagForm);
USEFORM("FormMain.cpp", MainForm);
USEFORM("FormOptions.cpp", OptionsForm);
//---------------------------------------------------------------------------
WINAPI _tWinMain(HINSTANCE, HINSTANCE, LPTSTR, int)
{
	try
	{
		Application->Initialize();
		Application->MainFormOnTaskBar = true;
		Application->Title = "OSCA Z80 Board Emulator";
		Application->CreateForm(__classid(TMainForm), &MainForm);
		Application->CreateForm(__classid(TAboutForm), &AboutForm);
		Application->CreateForm(__classid(TDebugForm), &DebugForm);
		Application->CreateForm(__classid(TDiagForm), &DiagForm);
		Application->CreateForm(__classid(TOptionsForm), &OptionsForm);
		Application->Run();
	}
	catch (Exception &exception)
	{
		Application->ShowException(&exception);
	}
	catch (...)
	{
		try
		{
			throw Exception("");
		}
		catch (Exception &exception)
		{
			Application->ShowException(&exception);
		}
	}
	return 0;
}
//---------------------------------------------------------------------------
