<?xml version="1.0" encoding="utf-8"?>

<!--
==========================================
- POST-GAME SUMMARY SCREEN -
==========================================
-->

<objects>
	<script file="gui/common/functions_global_object.js"/>
	<script file="gui/common/functions_civinfo.js"/>
	<script file="gui/common/functions_utility.js"/>
	<script file="gui/common/settings.js"/>
	<script file="gui/summary/counters.js"/>
	<script file="gui/summary/layout.js"/>
	<script file="gui/summary/summary.js"/>

	<object type="image"
		style="ModernWindow"
		size="0 0 100% 100%"
	>
		<object style="ModernLabelText" type="text" size="50%-128 4 50%+128 36">
			<translatableAttribute id="caption">Summary</translatableAttribute>
		</object>

		<object size="20 26 100%-20 92">

			<object name="summaryText"
				type="text"
				size="50 16 100%-50 100%-16"
				font="sans-bold-18"
				textcolor="255 255 255"
				text_align="left"
				text_valign="center"
			/>

			<object name="timeElapsed"
				type="text"
				size="50 16 100%-50 100%-16"
				font="sans-bold-18"
				textcolor="255 255 255"
				text_align="right"
				text_valign="center"
			/>

			<object name="mapName"
				type="text"
				size="50 16 100%-50 100%-16"
				font="sans-bold-18"
				textcolor="255 255 255"
				text_align="center"
				text_valign="center"
			/>

		</object>

		<object name="tabDividerLeft" type="image" sprite="TabSpacer" size="172 120 174 122"/>
		<object name="tabDividerRight" type="image" sprite="TabSpacer" size="328 120 330 122"/>

		<object name="scorePanelButton" type="button" sprite="ForegroundTab" size="20 92 136 120">
			<action on="Press">selectPanel(0);</action>
			<object type="text" style="ModernLabelText" ghost="true">
				<translatableAttribute id="caption">Score</translatableAttribute>
			</object>
		</object>

		<object name="buildingsPanelButton" type="button" sprite="BackgroundTab" size="142 92 260 120">
			<action on="Press">selectPanel(1);</action>
			<object type="text" style="ModernLabelText" ghost="true">
				<translatableAttribute id="caption">Buildings</translatableAttribute>
			</object>
		</object>

		<object name="unitsPanelButton" type="button" sprite="BackgroundTab" size="266 92 384 120">
			<action on="Press">selectPanel(2);</action>
			<object type="text" style="ModernLabelText" ghost="true">
				<translatableAttribute id="caption">Units</translatableAttribute>
			</object>
		</object>

		<object name="resourcesPanelButton" type="button" sprite="BackgroundTab" size="390 92 508 120">
			<action on="Press">selectPanel(3);</action>
			<object type="text" style="ModernLabelText" ghost="true">
				<translatableAttribute id="caption">Resources</translatableAttribute>
			</object>
		</object>

		<object name="marketPanelButton" type="button" sprite="BackgroundTab" size="514 92 632 120">
			<action on="Press">selectPanel(4);</action>
			<object type="text" style="ModernLabelText" ghost="true">
				<translatableAttribute id="caption">Market</translatableAttribute>
			</object>
		</object>

		<object name="miscPanelButton" type="button" sprite="BackgroundTab" size="638 92 756 120">
			<action on="Press">selectPanel(5);</action>
			<object type="text" style="ModernLabelText" ghost="true">
				<translatableAttribute id="caption">Miscellaneous</translatableAttribute>
			</object>
		</object>

		<object name="generalPanel" type="image" sprite="ForegroundBody" size="20 120 100%-20 100%-54">
			<object size="0 0 100% 100%-50">
				<object name="playerNameHeading" type="text" style="ModernLeftTabLabelText">
					<translatableAttribute id="caption">Player name</translatableAttribute>
				</object>
				<repeat var="x" count="8">
					<object name="titleHeading[x]" type="text" style="ModernTabLabelText">
					</object>
				</repeat>
				<repeat var="x" count="8">
					<object name="Heading[x]" type="text" style="ModernTabLabelText">
					</object>
				</repeat>
			</object>

			<repeat count="4" var="i">
				<object type="image" name="teamBoxt[i]" size="0 65 100% 100%-50" hidden="true">
					<object type="text" name="teamNameHeadingt[i]" size="15 5 100% 100%" style="ModernLeftTabLabelText"/>
					<object size="0 30 100% 100%">
						<repeat count="8" var="n">
							<object type="image" name="playerBoxt[i][n]" size="10 0 10 30" hidden="true">
								<object name="playerColorBoxt[i][n]" type="image" size="10 4 30 24"/>
								<object name="playerNamet[i][n]" type="text"  size="40 2 208 100%" style="ModernLeftLabelText" />
								<object name="civIcont[i][n]" type="image" size="208 0 240 32"/>
								<repeat var="x" count="8">
									<object name="valueDataTeam[i][n][x]" type="text" style="ModernTabLabelText">
									</object>
								</repeat>
							</object>
						</repeat>
					</object>
					<object name="teamHeadingt[i]" type="text" style="ModernLeftTabLabelText"/>
					<repeat var="x" count="8">
						<object name="valueDataTeam[i][x]" type="text" style="ModernTabLabelText">
						</object>
					</repeat>
				</object>
			</repeat>

			<object type="image" name="noTeamsBox" size="0 65 100% 100%-50" hidden="true">
				<repeat count="8">
					<object type="image" name="playerBox[n]" size="10 0 10 30" hidden="true">
						<object type="image" sprite="ForegroundBox" size="10 4 34 28">
							<object name="playerColorBox[n]" type="image" size="2 2 22 22"/>
						</object>
						<object name="playerName[n]" type="text"  size="40 2 208 100%" style="ModernLeftLabelText"/>
						<object name="civIcon[n]" type="image" size="208 0 240 32"/>
						<repeat var="x" count="8">
							<object name="valueData[n][x]" type="text" style="ModernTabLabelText">
							</object>
						</repeat>
					</object>
				</repeat>
			</object>
		</object>

		<object type="button" style="ModernButtonRed" size="100%-160 100%-48 100%-20 100%-20">
			<translatableAttribute id="caption">Continue</translatableAttribute>
			<action on="Press"><![CDATA[
				if (g_GameData.isReplay)
				{
					Engine.SwitchGuiPage("page_replaymenu.xml");
				}
				else if (!Engine.HasXmppClient())
				{
					Engine.SwitchGuiPage("page_pregame.xml");
				}
				else
				{
					Engine.LobbySetPlayerPresence("available");
					Engine.SwitchGuiPage("page_lobby.xml");
				}
				]]>
			</action>
		</object>
	</object>
</objects>
