Quantcast
<Ui xmlns="http://www.blizzard.com/wow/ui/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
		xsi:schemaLocation="http://www.blizzard.com/wow/ui/ ..\FrameXML\UI.xsd">
	<Script file="config.lua"/>
	<Include file="widgets.xml"/>
	<Frame name="ww_config" inherits="ww_borderedFrame" hidden="true">
		<Anchors>
			<Anchor point="TOPLEFT"/>
			<Anchor point="BOTTOMRIGHT"/>
		</Anchors>
		<Layers>
			<Layer level="OVERLAY">
				<FontString name="$parentTitle" parentKey="title" inherits="GameFontNormalHuge" text="WeightsWatcher">
					<Anchors>
						<Anchor point="TOP">
							<Offset>
								<AbsDimension x="0" y="-5"/>
							</Offset>
						</Anchor>
					</Anchors>
				</FontString>
				<FontString name="$parentVersion" parentKey="version" inherits="GameFontNormal">
					<Anchors>
						<Anchor point="TOP" relativePoint="BOTTOM" relativeTo="$parentTitle">
							<Offset>
								<AbsDimension x="0" y="-10"/>
							</Offset>
						</Anchor>
						<Anchor point="LEFT">
							<Offset>
								<AbsDimension x="10" y="0"/>
							</Offset>
						</Anchor>
					</Anchors>
				</FontString>
				<FontString name="$parentAccountVersion" parentKey="accountVersion" inherits="GameFontNormal">
					<Anchors>
						<Anchor point="TOPLEFT" relativePoint="BOTTOMLEFT" relativeTo="$parentVersion">
							<Offset>
								<AbsDimension x="10" y="0"/>
							</Offset>
						</Anchor>
					</Anchors>
				</FontString>
				<FontString name="$parentCharacterVersion" parentKey="characterVersion" inherits="GameFontNormal">
					<Anchors>
						<Anchor point="TOPLEFT" relativePoint="BOTTOMLEFT" relativeTo="$parentAccountVersion"/>
					</Anchors>
				</FontString>
				<FontString name="$parentContact" parentKey="contact" inherits="GameFontNormal">
					<Anchors>
						<Anchor point="TOP" relativePoint="BOTTOM" relativeTo="$parentCharacterVersion">
							<Offset>
								<AbsDimension x="0" y="-15"/>
							</Offset>
						</Anchor>
						<Anchor point="LEFT">
							<Offset>
								<AbsDimension x="10" y="0"/>
							</Offset>
						</Anchor>
					</Anchors>
				</FontString>
				<FontString name="$parentWebpage" parentKey="webpage" inherits="GameFontNormal">
					<Anchors>
						<Anchor point="TOPLEFT" relativePoint="BOTTOMLEFT" relativeTo="$parentContact"/>
					</Anchors>
				</FontString>
				<FontString name="$parentDescription" parentKey="description" inherits="GameFontHighlight">
					<Anchors>
						<Anchor point="TOPLEFT" relativePoint="BOTTOMLEFT" relativeTo="$parentWebpage">
							<Offset>
								<AbsDimension x="0" y="-25"/>
							</Offset>
						</Anchor>
					</Anchors>
				</FontString>
			</Layer>
			<Layer level="BACKGROUND">
				<Texture setAllPoints="true">
					<!--Plain black background with 80% alpha-->
					<Color r="0" g="0" b="0" a="0.8"/>
				</Texture>
			</Layer>
		</Layers>
		<Frames>
			<Button name="$parentWeights" parentKey="weights" inherits="ww_localizedButton" text="CONFIG_WEIGHTS">
				<Size>
					<AbsDimension x="150" y="22"/>
				</Size>
				<Anchors>
					<Anchor point="TOP" relativePoint="BOTTOM" relativeTo="$parentDescription">
						<Offset>
							<AbsDimension x="0" y="-25"/>
						</Offset>
					</Anchor>
				</Anchors>
				<Scripts>
					<OnClick>
						ww_commandHandler("weights")
					</OnClick>
				</Scripts>
			</Button>
		</Frames>
		<Scripts>
			<OnLoad>
				self.name = "WeightsWatcher"
				self.okay = function(...)
						ww_config.originalOpts = nil
					end
				self.cancel = function(...)
						ww_vars.options = ww_config.originalOpts
						ww_config.originalOpts = nil
						WeightsWatcher.ResetTables()
					end
				self.refresh = function(...)
						self.version:SetText(string.format(ww_localization["CONF_WW_VER"], GetAddOnMetadata("WeightsWatcher", "Version")))
						self.accountVersion:SetText(string.format(ww_localization["CONF_ACCT_VER"], ww_vars.dataMajorVersion, ww_vars.dataMinorVersion))
						self.characterVersion:SetText(string.format(ww_localization["CONF_CHAR_VER"], ww_charVars.dataMajorVersion, ww_charVars.dataMinorVersion))
						self.contact:SetText(string.format(ww_localization["CONF_CONTACT"], "WeightsWatcher@gmail.com"))
						self.webpage:SetText(string.format(ww_localization["CONF_WEBPAGE"], "http://wowinterface.com/downloads/\n         info15289-WeightsWatcher.html"))
						self.description:SetText(ww_localization["CONF_DESC"])
						self.refresh = function(...)
								ww_config.originalOpts = ww_config.originalOpts or ww_deepTableCopy(ww_vars.options)
							end
						self.refresh(...)
					end
				InterfaceOptions_AddCategory(self)
			</OnLoad>
		</Scripts>
	</Frame>
	<Include file="config-calculation.xml"/>
	<Include file="config-display.xml"/>
	<Include file="config-gems.xml"/>
	<Include file="config-enchants.xml"/>
</Ui>