require "scripts/style"
HeaderFont = {
  standardFont,
  30,
  BlackColor
};
BodyFont = {
  standardFont,
  16,
  BlackColor
};

kStatTextX  = kCenter-49;
kStatValueX = kCenter+99;
kStatStartY = 300;
kStatSpaceY = 25;

MakeDialog
{
	-- Name the modal dialog
	name="GameFinishedDialog",
	Bitmap
	{
		image="backgrounds/largedialog",
		x=kCenter,
		y=kCenter,			
		Text
		{
			font = QuickTaskButtonFont,--StandardButtonFont,
			name = "gameFinishedText",
			x=40,y=130, w=kMax-40,h=145,
			flags = kHAlignCenter,
			label = "gameFinishedText"
		};        
-- time passed
		Text
		{
			font = QuickTaskButtonFont,--StandardButtonFont,
			name = "TimePassedText",
			x=kStatTextX, y=kStatStartY, 
            w=200,h=30,
			flags = kHAlignLeft,
			label = "AllTimePassedText"
		};
		Text
		{
			font = QuickTaskButtonFont,--StandardButtonFont,
			name = "TimePassedValue",
			x=kStatValueX,y=kStatStartY, 
            w=100,h=30,
			flags = kHAlignRight,
			label = "TimePassedValue"
		};
-- all items matched
		Text
		{
			font = QuickTaskButtonFont,--StandardButtonFont,
			name = "AllItemsText",
			x=kStatTextX, y=kStatStartY + kStatSpaceY, 
            w=200,h=30,
			flags = kHAlignLeft,
			label = "AllItemsText"
		};
		Text
		{
			font = QuickTaskButtonFont,--StandardButtonFont,
			name = "AllItemsValue",
			x=kStatValueX, y=kStatStartY + kStatSpaceY,
            w=100,h=30,
			flags = kHAlignRight,
			label = "zeroNumber"
		};		
-- match3
		Text
		{
			font = QuickTaskButtonFont,--StandardButtonFont,
			name = "ItemsMatch3Text",
			x=kStatTextX,y=kStatStartY + kStatSpaceY*2,
            w=200,h=30,
			flags = kHAlignLeft,
			label = "ItemsMatch3Text"
		};
		Text
		{
			font = QuickTaskButtonFont,--StandardButtonFont,
			name = "ItemsMatch3Value",
			x=kStatValueX,y=kStatStartY + kStatSpaceY*2,
            w=100,h=30,
			flags = kHAlignRight,
			label = "zeroNumber"
		};
-- match4
		Text
		{
			font = QuickTaskButtonFont,--StandardButtonFont,
			name = "ItemsMatch4Text",
			x=kStatTextX,y=kStatStartY + kStatSpaceY*3,
            w=200,h=30,
			flags = kHAlignLeft,
			label = "ItemsMatch4Text"
		};
		Text
		{
			font = QuickTaskButtonFont,--StandardButtonFont,
			name = "ItemsMatch4Value",
			x=kStatValueX,y=kStatStartY + kStatSpaceY*3,
            w=100,h=30,
			flags = kHAlignRight,
			label = "zeroNumber"
		};				
-- match5 or more
		Text
		{
			font = QuickTaskButtonFont,--StandardButtonFont,
			name = "ItemsMatch5pText",
			x=kStatTextX,y=kStatStartY + kStatSpaceY*4,
            w=200,h=30,
			flags = kHAlignLeft,
			label = "ItemsMatch5pText"
		};
		Text
		{
			font = QuickTaskButtonFont,--StandardButtonFont,
			name = "ItemsMatch5pValue",
			x=kStatValueX,y=kStatStartY + kStatSpaceY*4,
            w=100,h=30,
			flags = kHAlignRight,
			label = "zeroNumber"
		};	
-- number of tries on this level 
		Text
		{
			font = QuickTaskButtonFont,--StandardButtonFont,
			name = "AllLevelTriesText",
			x=kStatTextX,y=kStatStartY + kStatSpaceY*5,
            w=200,h=30,
			flags = kHAlignLeft,
			label = "AllLevelTriesText"
		};
		Text
		{
			font = QuickTaskButtonFont,--StandardButtonFont,
			name = "LevelTriesValue",
			x=kStatValueX,y=kStatStartY + kStatSpaceY*5,
            w=100,h=30,
			flags = kHAlignRight,
			label = "zeroNumber"
		};	

		SetStyle(SmallEmptyRoundButtonStyle),
		Button
		{
			name = "gamemode1",
			label = "ok",
			x = kCenter,
			y = kMax-80,
			-- close = true,
			command =
			function()
				SwapToModal('scripts/mainmenu.lua');
			end
		},
		Bitmap
		{
			name = "gBitmap0001",
			image = "pics/congrat",
			x = 58,
			y = 45,
			scale = 1.00
		}
	},
}