<Ui xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns="http://www.blizzard.com/wow/ui/">
	
	<Button name="AltoTabTemplate" inherits="CharacterFrameTabButtonTemplate" virtual="true">
		<Scripts>
			<OnClick>
				Altoholic.Tabs:OnClick(self:GetID());
			</OnClick>
		</Scripts>
	</Button>

	<!-- Item template -->
	<Button name="AltoBagItemTemplate" inherits="ItemButtonTemplate" hidden="true" virtual="true">
		<Frames>
			<Cooldown name="$parentCooldown" inherits="CooldownFrameTemplate"/>
		</Frames>
		<Scripts>
			<OnLoad>
				local level = self:GetParent():GetFrameLevel()
				self:SetFrameLevel(level + 1)
				self:RegisterForClicks("LeftButtonDown", "RightButtonDown");
			</OnLoad>
			<OnEnter>
				Altoholic:Item_OnEnter(self)
			</OnEnter>
			<OnLeave>
				GameTooltip:Hide();
			</OnLeave>
			<OnClick>
				Altoholic:Item_OnClick(self, button)
			</OnClick>
		</Scripts>
	</Button>

	<Button name="AltoContainerTemplate" hidden="true" virtual="true">
		<Size>
			<AbsDimension x="615" y="41"/>
		</Size>
		<Frames>
			<Button name="$parentItem1" inherits="AltoBagItemTemplate">
				<Anchors>
					<Anchor point="BOTTOMLEFT" relativeTo="$parent" relativePoint="BOTTOMLEFT">
						<Offset>
							<AbsDimension x="17" y="0"/>
						</Offset>
					</Anchor>
				</Anchors>
			</Button>
			<Button name="$parentItem2" inherits="AltoBagItemTemplate">
				<Anchors>
					<Anchor point="BOTTOMLEFT" relativeTo="$parentItem1" relativePoint="BOTTOMRIGHT">
						<Offset>
							<AbsDimension x="5" y="0"/>
						</Offset>
					</Anchor>
				</Anchors>
			</Button>
			<Button name="$parentItem3" inherits="AltoBagItemTemplate">
				<Anchors>
					<Anchor point="BOTTOMLEFT" relativeTo="$parentItem2" relativePoint="BOTTOMRIGHT">
						<Offset>
							<AbsDimension x="5" y="0"/>
						</Offset>
					</Anchor>
				</Anchors>
			</Button>
			<Button name="$parentItem4" inherits="AltoBagItemTemplate">
				<Anchors>
					<Anchor point="BOTTOMLEFT" relativeTo="$parentItem3" relativePoint="BOTTOMRIGHT">
						<Offset>
							<AbsDimension x="5" y="0"/>
						</Offset>
					</Anchor>
				</Anchors>
			</Button>
			<Button name="$parentItem5" inherits="AltoBagItemTemplate">
				<Anchors>
					<Anchor point="BOTTOMLEFT" relativeTo="$parentItem4" relativePoint="BOTTOMRIGHT">
						<Offset>
							<AbsDimension x="5" y="0"/>
						</Offset>
					</Anchor>
				</Anchors>
			</Button>
			<Button name="$parentItem6" inherits="AltoBagItemTemplate">
				<Anchors>
					<Anchor point="BOTTOMLEFT" relativeTo="$parentItem5" relativePoint="BOTTOMRIGHT">
						<Offset>
							<AbsDimension x="5" y="0"/>
						</Offset>
					</Anchor>
				</Anchors>
			</Button>
			<Button name="$parentItem7" inherits="AltoBagItemTemplate">
				<Anchors>
					<Anchor point="BOTTOMLEFT" relativeTo="$parentItem6" relativePoint="BOTTOMRIGHT">
						<Offset>
							<AbsDimension x="5" y="0"/>
						</Offset>
					</Anchor>
				</Anchors>
			</Button>
			<Button name="$parentItem8" inherits="AltoBagItemTemplate">
				<Anchors>
					<Anchor point="BOTTOMLEFT" relativeTo="$parentItem7" relativePoint="BOTTOMRIGHT">
						<Offset>
							<AbsDimension x="5" y="0"/>
						</Offset>
					</Anchor>
				</Anchors>
			</Button>
			<Button name="$parentItem9" inherits="AltoBagItemTemplate">
				<Anchors>
					<Anchor point="BOTTOMLEFT" relativeTo="$parentItem8" relativePoint="BOTTOMRIGHT">
						<Offset>
							<AbsDimension x="5" y="0"/>
						</Offset>
					</Anchor>
				</Anchors>
			</Button>
			<Button name="$parentItem10" inherits="AltoBagItemTemplate">
				<Anchors>
					<Anchor point="BOTTOMLEFT" relativeTo="$parentItem9" relativePoint="BOTTOMRIGHT">
						<Offset>
							<AbsDimension x="5" y="0"/>
						</Offset>
					</Anchor>
				</Anchors>
			</Button>
			<Button name="$parentItem11" inherits="AltoBagItemTemplate">
				<Anchors>
					<Anchor point="BOTTOMLEFT" relativeTo="$parentItem10" relativePoint="BOTTOMRIGHT">
						<Offset>
							<AbsDimension x="5" y="0"/>
						</Offset>
					</Anchor>
				</Anchors>
			</Button>
			<Button name="$parentItem12" inherits="AltoBagItemTemplate">
				<Anchors>
					<Anchor point="BOTTOMLEFT" relativeTo="$parentItem11" relativePoint="BOTTOMRIGHT">
						<Offset>
							<AbsDimension x="5" y="0"/>
						</Offset>
					</Anchor>
				</Anchors>
			</Button>
			<Button name="$parentItem13" inherits="AltoBagItemTemplate">
				<Anchors>
					<Anchor point="BOTTOMLEFT" relativeTo="$parentItem12" relativePoint="BOTTOMRIGHT">
						<Offset>
							<AbsDimension x="5" y="0"/>
						</Offset>
					</Anchor>
				</Anchors>
			</Button>
			<Button name="$parentItem14" inherits="AltoBagItemTemplate">
				<Anchors>
					<Anchor point="BOTTOMLEFT" relativeTo="$parentItem13" relativePoint="BOTTOMRIGHT">
						<Offset>
							<AbsDimension x="5" y="0"/>
						</Offset>
					</Anchor>
				</Anchors>
			</Button>
		</Frames>
	</Button>

	<!-- Navigation -->
	<Button name="AltoMenuItemTemplate" hidden="true" virtual="true">
		<Size>
			<AbsDimension x="136" y="20"/>
		</Size>
		<Layers>
			<Layer level="BACKGROUND">
				<Texture name="$parentLines" file="Interface\AuctionFrame\UI-AuctionFrame-FilterLines">
					<Size>
						<AbsDimension x="7" y="20"/>
					</Size>
					<Anchors>
						<Anchor point="LEFT">
							<Offset>
								<AbsDimension x="13" y="0"/>
							</Offset>
						</Anchor>
					</Anchors>
					<TexCoords left="0" right="0.4375" top="0" bottom="0.625"/>
				</Texture>
			</Layer>
		</Layers>
		<NormalTexture name="$parentNormalTexture" file="Interface\AuctionFrame\UI-AuctionFrame-FilterBg">
			<TexCoords left="0" right="0.53125" top="0" bottom="0.625"/>
		</NormalTexture>
		<HighlightTexture file="Interface\PaperDollInfoFrame\UI-Character-Tab-Highlight" alphaMode="ADD"/>
		<ButtonText name="$parentNormalText">
			<Size>
				<AbsDimension x="128" y="8"/>
			</Size>
			<Anchors>
				<Anchor point="LEFT">
					<Offset>
						<AbsDimension x="4" y="0"/>
					</Offset>
				</Anchor>
			</Anchors>
		</ButtonText>
		<NormalFont style="GameFontNormalSmallLeft"/>
		<HighlightFont style="GameFontHighlightSmallLeft"/>
	</Button>

	<Button name="AltoMenuNamedIconTemplate" virtual="true">
		<Size>
			<AbsDimension x="136" y="40"/>
		</Size>
		<Layers>
			<Layer level="BORDER">
				<Texture file="Interface\Icons\INV_BannerPVP_02">
					<Size x="36" y="36"/>
					<Anchors>
						<Anchor point="TOPLEFT" x="0" y="0"/>
					</Anchors>
				</Texture>
				<Texture file="Interface\AuctionFrame\UI-AuctionItemNameFrame">
					<Size x="110" y="36"/>
					<Anchors>
						<Anchor point="TOPLEFT" x="40" y="0"/>
					</Anchors>
					<TexCoords left="0.15625" right="0.83203125" top="0.171875" bottom="0.796875"/>
				</Texture>
			</Layer>
			<Layer level="OVERLAY">
				<FontString name="$parentText" inherits="GameFontNormal" justifyH="CENTER" text="Reputations">
					<Size>
						<AbsDimension x="80" y="18"/>
					</Size>
					<Anchors>
						<Anchor point="TOPLEFT">
							<Offset>
								<AbsDimension x="50" y="-9"/>
							</Offset>
						</Anchor>
					</Anchors>
					<Color r="1" g="1" b="1" /> 
				</FontString>
			</Layer>
		</Layers>
	</Button>

	
	<Button name="AltoSortButtonTemplate" virtual="true">
		<Layers>
			<Layer level="BACKGROUND">
				<Texture name="$parentLeft" file="Interface\FriendsFrame\WhoFrame-ColumnTabs">
					<Size>
						<AbsDimension x="5" y="19"/>
					</Size>
					<Anchors>
						<Anchor point="TOPLEFT"/>
					</Anchors>
					<TexCoords left="0" right="0.078125" top="0" bottom="0.59375"/>
				</Texture>
				<Texture name="$parentRight" file="Interface\FriendsFrame\WhoFrame-ColumnTabs">
					<Size>
						<AbsDimension x="4" y="19"/>
					</Size>
					<Anchors>
						<Anchor point="TOPRIGHT"/>
					</Anchors>
					<TexCoords left="0.90625" right="0.96875" top="0" bottom="0.59375"/>
				</Texture>
				<Texture name="$parentMiddle" file="Interface\FriendsFrame\WhoFrame-ColumnTabs">
					<Size>
						<AbsDimension x="10" y="19"/>
					</Size>
					<Anchors>
						<Anchor point="LEFT" relativeTo="$parentLeft" relativePoint="RIGHT"/>
						<Anchor point="RIGHT" relativeTo="$parentRight" relativePoint="LEFT"/>
					</Anchors>
					<TexCoords left="0.078125" right="0.90625" top="0" bottom="0.59375"/>
				</Texture>
			</Layer>
		</Layers>
		<ButtonText name="$parentText">
			<Anchors>
				<Anchor point="LEFT">
					<Offset>
						<AbsDimension x="8" y="0"/>
					</Offset>
				</Anchor>
			</Anchors>
		</ButtonText>
		<NormalFont style="GameFontHighlightSmall"/>
		<NormalTexture name="$parentArrow" file="Interface\Buttons\UI-SortArrow">
			<Size>
				<AbsDimension x="9" y="8"/>
			</Size>
			<Anchors>
				<Anchor point="LEFT" relativeTo="$parentText" relativePoint="RIGHT">
					<Offset>
						<AbsDimension x="3" y="-2"/>
					</Offset>
				</Anchor>
			</Anchors>
			<TexCoords left="0" right="0.5625" top="0" bottom="1.0"/>
		</NormalTexture>
		<HighlightTexture file="Interface\PaperDollInfoFrame\UI-Character-Tab-Highlight" alphaMode="ADD">
			<Size>
				<AbsDimension x="5" y="24"/>
			</Size>
			<Anchors>
				<Anchor point="LEFT">
					<Offset>
						<AbsDimension x="0" y="0"/>
					</Offset>
				</Anchor>
				<Anchor point="RIGHT">
					<Offset>
						<AbsDimension x="4" y="0"/>
					</Offset>
				</Anchor>
			</Anchors>
		</HighlightTexture>
		<Scripts>
			<OnLoad>
				_G[ self:GetName() .."Arrow" ]:Hide()
			</OnLoad>
		</Scripts>
	</Button>
	
	<!-- IconList, used by Pets & Achievements -->
	<Button name="AltoIconListItemTemplate" hidden="true" virtual="true">
		<Size>
			<AbsDimension x="37" y="37"/>
		</Size>
		<Layers> 
			<Layer level="BACKGROUND"> 
				<Texture name="$parent_Background">
					<Size>
						<AbsDimension x="33" y="33"/>
					</Size>
					<Anchors>
						<Anchor point="LEFT">
							<Offset>
								<AbsDimension x="2" y="0"/>
							</Offset>
						</Anchor>
					</Anchors>
					<Color r="0.2" g="0.2" b="0.2" a="1" /> 
				</Texture> 
			</Layer>
			<Layer level="OVERLAY"> 
				<FontString name="$parentName" inherits="GameFontNormalSmall" justifyH="CENTER" >
					<Size>
						<AbsDimension x="30" y="18"/>
					</Size>
					<Anchors>
						<Anchor point="BOTTOMRIGHT">
							<Offset>
								<AbsDimension x="5" y="0"/>
							</Offset>
						</Anchor>
					</Anchors>
					<Color r="1" g="1" b="1" /> 
				</FontString>
			</Layer>
		</Layers>
		<Scripts>
			<OnLoad>
				local level = self:GetParent():GetFrameLevel()
				self:SetFrameLevel(level + 1)
				self:RegisterForClicks("LeftButtonDown", "RightButtonDown")
			</OnLoad>
			<OnLeave>
				AltoTooltip:Hide();
			</OnLeave>
		</Scripts>
		<Backdrop name="$parentBackdrop" bgFile="Interface\TutorialFrame\TutorialFrameBackground" edgeFile="Interface\Tooltips\UI-Tooltip-Border" tile="true">
			<EdgeSize>
				<AbsValue val="8"/>
			</EdgeSize>
			<TileSize>
				<AbsValue val="36"/>
			</TileSize>
			<BackgroundInsets>
				<AbsInset left="5" right="5" top="5" bottom="5"/>
			</BackgroundInsets>
			<Color r="1" g="1" b="1" a="0"/>
		</Backdrop>
	</Button>
		
	<Button name="AltoIconListtEntryTemplate" virtual="true">
		<Size>
			<AbsDimension x="615" y="38"/>
		</Size>
		<Layers>
			<Layer level="BACKGROUND">
				<FontString name="$parentName" inherits="GameFontNormal" justifyH="LEFT" justifyV="MIDDLE">
					<Size>
						<AbsDimension x="160" y="37"/>
					</Size>
					<Anchors>
						<Anchor point="TOPLEFT">
							<Offset>
								<AbsDimension x="10" y="0"/>
							</Offset>
						</Anchor>
					</Anchors>
				</FontString>
			</Layer>
		</Layers>
		<Frames>
			<Button name="$parentItem1" inherits="AltoIconListItemTemplate">
				<Anchors>
					<Anchor point="BOTTOMLEFT" relativeTo="$parent" relativePoint="BOTTOMLEFT">
						<Offset>
							<AbsDimension x="185" y="0"/>
						</Offset>
					</Anchor>
				</Anchors>
			</Button>
			<Button name="$parentItem2" inherits="AltoIconListItemTemplate">
				<Anchors>
					<Anchor point="BOTTOMLEFT" relativeTo="$parentItem1" relativePoint="BOTTOMRIGHT">
						<Offset>
							<AbsDimension x="5" y="0"/>
						</Offset>
					</Anchor>
				</Anchors>
			</Button>
			<Button name="$parentItem3" inherits="AltoIconListItemTemplate">
				<Anchors>
					<Anchor point="BOTTOMLEFT" relativeTo="$parentItem2" relativePoint="BOTTOMRIGHT">
						<Offset>
							<AbsDimension x="5" y="0"/>
						</Offset>
					</Anchor>
				</Anchors>
			</Button>
			<Button name="$parentItem4" inherits="AltoIconListItemTemplate">
				<Anchors>
					<Anchor point="BOTTOMLEFT" relativeTo="$parentItem3" relativePoint="BOTTOMRIGHT">
						<Offset>
							<AbsDimension x="5" y="0"/>
						</Offset>
					</Anchor>
				</Anchors>
			</Button>
			<Button name="$parentItem5" inherits="AltoIconListItemTemplate">
				<Anchors>
					<Anchor point="BOTTOMLEFT" relativeTo="$parentItem4" relativePoint="BOTTOMRIGHT">
						<Offset>
							<AbsDimension x="5" y="0"/>
						</Offset>
					</Anchor>
				</Anchors>
			</Button>
			<Button name="$parentItem6" inherits="AltoIconListItemTemplate">
				<Anchors>
					<Anchor point="BOTTOMLEFT" relativeTo="$parentItem5" relativePoint="BOTTOMRIGHT">
						<Offset>
							<AbsDimension x="5" y="0"/>
						</Offset>
					</Anchor>
				</Anchors>
			</Button>
			<Button name="$parentItem7" inherits="AltoIconListItemTemplate">
				<Anchors>
					<Anchor point="BOTTOMLEFT" relativeTo="$parentItem6" relativePoint="BOTTOMRIGHT">
						<Offset>
							<AbsDimension x="5" y="0"/>
						</Offset>
					</Anchor>
				</Anchors>
			</Button>
			<Button name="$parentItem8" inherits="AltoIconListItemTemplate">
				<Anchors>
					<Anchor point="BOTTOMLEFT" relativeTo="$parentItem7" relativePoint="BOTTOMRIGHT">
						<Offset>
							<AbsDimension x="5" y="0"/>
						</Offset>
					</Anchor>
				</Anchors>
			</Button>
			<Button name="$parentItem9" inherits="AltoIconListItemTemplate">
				<Anchors>
					<Anchor point="BOTTOMLEFT" relativeTo="$parentItem8" relativePoint="BOTTOMRIGHT">
						<Offset>
							<AbsDimension x="5" y="0"/>
						</Offset>
					</Anchor>
				</Anchors>
			</Button>
			<Button name="$parentItem10" inherits="AltoIconListItemTemplate">
				<Anchors>
					<Anchor point="BOTTOMLEFT" relativeTo="$parentItem9" relativePoint="BOTTOMRIGHT">
						<Offset>
							<AbsDimension x="5" y="0"/>
						</Offset>
					</Anchor>
				</Anchors>
			</Button>
		</Frames>
	</Button>
	
	<Button name="AltoMenuIconTemplate" virtual="true">
		<Size>
			<AbsDimension x="36" y="36"/>
		</Size>
		<Layers>
			<Layer level="BORDER">
				<Texture name="$parentIconTexture"/>
			</Layer>
		</Layers>
		<Frames>
			<Frame name="$parentShine" inherits="AutoCastShineTemplate">
				<Anchors>
					<Anchor point="CENTER">
						<Offset>
							<AbsDimension x="0" y="0"/>
						</Offset>
					</Anchor>
				</Anchors>
				<Size>
					<AbsDimension x="34" y="34"/>
				</Size>
			</Frame>
		</Frames>

		<PushedTexture file="Interface\Buttons\UI-Quickslot-Depress"/>
		<HighlightTexture file="Interface\Buttons\ButtonHilight-Square" alphaMode="ADD"/>
	</Button>
	
	<Frame name="AltoRightClickMenuTemplate" inherits="UIDropDownMenuTemplate" hidden="true" virtual="true">
		<Size>
			<AbsDimension x="100" y="40"/>
		</Size>
	</Frame>
	
</Ui>