<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">
	
	<!-- TOOLTIP -->

	<GameTooltip virtual="true" name="ArkScanTooltipTemplate" inherits="GameTooltipTemplate">
		<Scripts>
			<Onload>
				GameTooltip_OnLoad( self )
				self:SetOwner( UIParent, "ANCHOR_NONE" )
			</Onload>
			<OnTooltipAddMoney>
				<!-- override -->
			</OnTooltipAddMoney>
			<OnTooltipCleared>
				<!-- override -->
			</OnTooltipCleared>
		</Scripts>
	</GameTooltip>
	
	
	<!-- FONTS -->
	
	<Font virtual="true" name="ARKINV_GameFontNormal" font="Fonts\FRIZQT__.TTF" outline="NORMAL">
		<FontHeight>
			<AbsValue val="12" />
		</FontHeight>
		<Color r="1.0" g="0.82" b="0" />
	</Font>
	
	<Font virtual="true" name="ARKINV_GameFontHighlight" inherits="ARKINV_GameFontNormal" outline="NORMAL">
		<Color r="1.0" g="1.0" b="1.0" />
	</Font>
	
	<Font virtual="true" name="ARKINV_GameFontDisable" inherits="ARKINV_GameFontNormal" outline="NORMAL">
		<Color r="0.5" g="0.5" b="0.5" />
	</Font>
	
	<Font virtual="true" name="ARKINV_GameFontNormalSmall" inherits="ARKINV_GameFontNormal" font="Fonts\FRIZQT__.TTF" outline="NORMAL">
		<FontHeight>
			<AbsValue val="10" />
		</FontHeight>
	</Font>

	<Font virtual="true" name="ARKINV_GameFontNormalLarge" inherits="ARKINV_GameFontNormal" font="Fonts\FRIZQT__.TTF" outline="NORMAL">
		<FontHeight>
			<AbsValue val="16" />
		</FontHeight>
	</Font>

	<Font virtual="true" name="ARKINV_GameFontNormalHuge" inherits="ARKINV_GameFontNormal" font="Fonts\FRIZQT__.TTF" outline="NORMAL">
		<FontHeight>
			<AbsValue val="20" />
		</FontHeight>
	</Font>
	
	<Font virtual="true" name="ARKINV_NewItemFont" font="Fonts\ARIALN.TTF" outline="NORMAL">
		<FontHeight>
			<AbsValue val="11" />
		</FontHeight>
		<Color r="1" g="1" b="1" />
	</Font>

	<Font virtual="true" name="ARKINV_TableRowFont" inherits="ARKINV_GameFontNormal" font="Fonts\FRIZQT__.TTF" outline="NORMAL">
		<FontHeight>
			<AbsValue val="14" />
		</FontHeight>
	</Font>

	<Font virtual="true" name="ARKINV_DataEntryFont" inherits="ARKINV_GameFontNormal" font="Fonts\FRIZQT__.TTF" outline="NORMAL">
		<FontHeight>
			<AbsValue val="14" />
		</FontHeight>
		<Color r="1" g="1" b="1" />
	</Font>

	<Font virtual="true" name="ARKINV_DataEntryLabelFont" inherits="ARKINV_DataEntryFont" outline="NORMAL">
		<Color r="0" g="1" b="0" />
	</Font>

	<Font virtual="true" name="ARKINV_DataEntryFontDisable" inherits="ARKINV_TableRowFont" outline="NORMAL">
		<Color r="0.5" g="0.5" b="0.5" />
	</Font>


<!-- TEXTURES -->

	<Texture virtual="true" name="ARKINV_TextureUnknown" file="Interface\Icons\INV_Misc_QuestionMark">
		<Size x="20" y="20"  />
	</Texture>
	
	<Texture virtual="true" name="ARKINV_TextureHighlight" setAllPoints="true" hidden="true">
		<Color r="1" g="1" b="0" a="0.2" />
	</Texture>
	
	<Texture virtual="true" name="ARKINV_TextureSelected" inherits="ARKINV_TextureHighlight" hidden="true">
		<Color r="1" g="1" b="1" a="0.2" />
	</Texture>

	<Texture virtual="true" name="ARKINV_TextureTransparent" inherits="ARKINV_TextureHighlight">
		<Color r="0" g="0" b="0" a="0" />
	</Texture>


<!-- EDITBOX -->

	<EditBox virtual="true" name="ARKINV_TemplateEditBoxNoLabel" inherits="InputBoxTemplate" historyLines="0" autoFocus="false">
		
		<FontString name="$parentNeedsToBeHere" inherits="ARKINV_DataEntryFont" />
		
		<Scripts>
		
			<OnEscapePressed>
				self:ClearFocus( )
			</OnEscapePressed>
			
		</Scripts>
		
	</EditBox>

	<EditBox virtual="true" name="ARKINV_TemplateEditBox" inherits="ARKINV_TemplateEditBoxNoLabel">

		<Layers>
		
			<Layer level="ARTWORK">
			
				<FontString name="$parentLabel" inherits="ARKINV_DataEntryLabelFont">
					<Anchors>
						<Anchor point="RIGHT" relativePoint="LEFT" x="-10" y="0" />
					</Anchors>
				</FontString>
				
			</Layer>
			
		</Layers>
		
	</EditBox>


<!-- FRAMES -->

	<Frame virtual="true" name="ARKINV_Border">
		<Anchors>
			<Anchor point="TOPLEFT" />
			<Anchor point="BOTTOMRIGHT" />
		</Anchors>
	</Frame>
	
	<Frame virtual="true" name="ARKINV_BorderHighlight" hidden="true">
		<Layers>
			<Layer level="BACKGROUND">
				<Texture file="Interface\Buttons\CheckButtonHilight" alphaMode="ADD" />
			</Layer>
		</Layers>
	</Frame>
	
	<Frame virtual="true" name="ARKINV_BorderPulse" inherits="ARKINV_BorderHighlight">
		<Animations>
			<AnimationGroup parentKey="glow" looping="REPEAT">
				<Alpha change="-1.0" duration="0.6" order="1"/>
				<Alpha change="1.0" duration="0.6" order="2"/>
			</AnimationGroup>
		</Animations>
		<Scripts>
			<OnShow>
				self.glow:Play( )
			</OnShow>
		</Scripts>
	</Frame>
	
	<Frame virtual="true" name="ARKINV_TemplateFrameBasic">
		<Frames>
			<Frame name="$parentArkBorder" inherits="ARKINV_Border" />
		</Frames>
	</Frame>
	
	<Frame virtual="true" name="ARKINV_TemplateFrameStandard" inherits="ARKINV_TemplateFrameBasic">
		
		<Size x="20" y="34" />
		
		<Layers>
			<Layer level="BACKGROUND">
				<Texture name="$parentBackground">
					<Anchors>
						<Anchor point="TOPLEFT" x="3" y="-3" />
						<Anchor point="BOTTOMRIGHT" x="-3" y="3" />
					</Anchors>
					<Color r="0" g="0" b="0" a="0.9" />
				</Texture>
			</Layer>
		</Layers>
		
	</Frame>

	<Button virtual="true" name="ARKINV_TemplateButton" inherits="OptionsButtonTemplate">
		<Size x="18" y="18" />
		<Scripts>
			<OnLeave>
				ArkInventory.GameTooltipHide( )
			</OnLeave>
		</Scripts>
	</Button>
	
	<Button virtual="true" name="ARKINV_TemplateButtonLocation" inherits="ARKINV_TemplateButton">
		<Size x="20" y="20" />
		<NormalTexture file="Interface\Icons\INV_Misc_QuestionMark" />
		<PushedTexture file="Interface\Icons\INV_Misc_QuestionMark" />
		<DisabledTexture file="Interface\Icons\INV_Misc_QuestionMark" />
		<HighlightTexture file="Interface\Icons\INV_Misc_QuestionMark" alphaMode="ADD" />
		<Scripts>
			<OnLoad>
				self:RegisterForClicks( "LeftButtonUp", "RightButtonUp" )
			</OnLoad>
			<OnClick>
				ArkInventory.MenuLocationOpen( self:GetParent( ):GetParent( ) )
			</OnClick>
			<OnEnter>
				ArkInventory.GameTooltipSetText( self, ArkInventory.Global.Location[self:GetID( )].Name )
			</OnEnter>
		</Scripts>
	</Button>

	<Button virtual="true" name="ARKINV_TemplateButtonAction">
		<Size x="20" y="20" />
		<NormalTexture file="Interface\Icons\INV_Misc_QuestionMark" />
		<PushedTexture file="Interface\Icons\INV_Misc_QuestionMark" />
		<DisabledTexture file="Interface\Icons\INV_Misc_QuestionMark" />
		<HighlightTexture file="Interface\Icons\INV_Misc_QuestionMark" alphaMode="ADD" />
		<Scripts>
			<OnLoad>
				self:RegisterForClicks( "LeftButtonUp", "RightButtonUp" )
			</OnLoad>
			<OnLeave>
				ArkInventory.GameTooltipHide( )
			</OnLeave>
		</Scripts>
	</Button>

	<Button virtual="true" name="ARKINV_TemplateButtonItem" inherits="ContainerFrameItemButtonTemplate" hidden="true">
		
		<NormalTexture name="$parentNormalTexture" file="Interface\Buttons\UI-PassiveHighlight" >
			<Anchors>
				<Anchor point="TOPLEFT" />
				<Anchor point="BOTTOMRIGHT" />
			</Anchors>
		</NormalTexture>
		
		<PushedTexture file="Interface\Buttons\UI-PassiveOverlay" >
			<Size x="64" y="64" />
			<Anchors>
				<Anchor point="CENTER" />
			</Anchors>
		</PushedTexture>
		
		<Frames>
			
			<Frame name="$parentArkBorder" inherits="ARKINV_Border" />
			
			<Frame name="$parentArkNew">
			
				<Anchors>
					<Anchor point="TOPLEFT" x="0" y="-2" />
					<Anchor point="BOTTOMRIGHT" relativeTo="$parent" relativePoint="TOPRIGHT" x="0" y="-12" />
				</Anchors>
				
				<Layers>
					<Layer level="BORDER">
						<FontString name="$parentText" inherits="ARKINV_NewItemFont" justifyH="CENTER" hidden="true" />
					</Layer>
				</Layers>
				
			</Frame>
			
		</Frames>
		
		<Scripts>
			
			<OnLoad>
				ArkInventory.Frame_Item_OnLoad( self )
			</OnLoad>
			
			<OnEnter>
				ArkInventory.Frame_Item_OnEnter( self )
			</OnEnter>
			
			<OnDragStart>
				ArkInventory.Frame_Item_OnDrag( self )
			</OnDragStart>
			
			<OnReceiveDrag>
				ArkInventory.Frame_Item_OnDrag( self )
			</OnReceiveDrag>
			
			<OnMouseUp>
				ArkInventory.Frame_Item_OnMouseUp( self, button )
			</OnMouseUp>
			
		</Scripts>
		
	</Button>
	
	<Button virtual="true" name="ARKINV_TemplateButtonVaultItem" inherits="ARKINV_TemplateButtonItem" hidden="true">
		
		<Scripts>
			
			<OnClick>
				ArkInventory.Frame_Vault_Item_OnClick( self, button, down )
			</OnClick>
			
			<OnDragStart>
				ArkInventory.Frame_Vault_Item_OnClick( self )
			</OnDragStart>
			
			<OnReceiveDrag>
				ArkInventory.Frame_Vault_Item_OnClick( self )
			</OnReceiveDrag>
			
		</Scripts>
		
	</Button>

	<Button virtual="true" name="ARKINV_TemplateButtonMountItem" inherits="ARKINV_TemplateButtonItem" hidden="true">
		
		<Frames>
			
			<Frame parentKey="active" inherits="ARKINV_BorderPulse" setAllPoints="true" />
			
		</Frames>
		
		<Scripts>
			
			<OnClick>
				ArkInventory.Frame_Item_Mount_OnClick( self, button, down )
			</OnClick>
			
			<OnDragStart>
				ArkInventory.Frame_Item_Mount_OnDragStart( self )
			</OnDragStart>
			
			<OnReceiveDrag>
				-- do nothing
			</OnReceiveDrag>
			
		</Scripts>
		
	</Button>
	
	<Button virtual="true" name="ARKINV_TemplateButtonBattlepetItem" inherits="ARKINV_TemplateButtonItem" hidden="true">
		
		<Frames>
			
			<Frame parentKey="active" inherits="ARKINV_BorderPulse" setAllPoints="true" />
			
			<Frame parentKey="slotted" inherits="ARKINV_BorderHighlight" setAllPoints="true" />
			
			<Frame parentKey="dead" hidden="true">
				<Size x="26" y="26" />
				<Anchors>
					<Anchor point="CENTER" />
				</Anchors>
				<Layers>
					<Layer level="OVERLAY">
						<Texture file="Interface\PetBattles\DeadPetIcon" />
					</Layer>
				</Layers>
			</Frame>
			
			<Frame parentKey="favorite" hidden="true">
				<Size x="26" y="26" />
				<Anchors>
					<Anchor point="TOPLEFT" x="-8" y="8" />
				</Anchors>
				<Layers>
					<Layer level="OVERLAY">
						<Texture file="Interface\PetBattles\PetJournal">
							<TexCoords left="0.11328125" right="0.16210938" top="0.02246094" bottom="0.04687500" />	
						</Texture>
					</Layer>
				</Layers>
			</Frame>
			
			
			<Frame parentKey="locked" hidden="true">
				<Size x="26" y="26" />
				<Anchors>
					<Anchor point="CENTER" />
				</Anchors>
				<Layers>
					<Layer level="OVERLAY">
						<Texture file="Interface\PetBattles\PetBattle-LockIcon" />
					</Layer>
				</Layers>
			</Frame>
			
		</Frames>
			
		<Scripts>
			
			<OnClick>
				ArkInventory.Frame_Item_Battlepet_OnClick( self, button, down )
			</OnClick>
			
			<OnDragStart>
				ArkInventory.Frame_Item_Battlepet_OnDragStart( self )
			</OnDragStart>
			
			<OnReceiveDrag>
				-- do nothing
			</OnReceiveDrag>
			
		</Scripts>
		
	</Button>
	
	<Button virtual="true" name="ARKINV_TemplateButtonViewOnlyItem" inherits="ARKINV_TemplateButtonItem" hidden="true">

		<Scripts>
		
			<OnClick>
				-- do nothing
			</OnClick>
			
			<OnDragStart>
				-- do nothing
			</OnDragStart>
			
			<OnReceiveDrag>
				-- do nothing
			</OnReceiveDrag>
			
			<OnMouseUp>
				ArkInventory.Frame_Item_OnMouseUp( self, button )
			</OnMouseUp>

		</Scripts>

	</Button>

	<Button virtual="true" name="ARKINV_TemplateButtonItemTainted" inherits="ContainerFrameItemButtonTemplate" hidden="true">
		
		<NormalTexture name="$parentNormalTexture" file="Interface\Buttons\UI-PassiveHighlight" >
			<Anchors>
				<Anchor point="TOPLEFT" />
				<Anchor point="BOTTOMRIGHT" />
			</Anchors>
		</NormalTexture>
		
		<PushedTexture file="Interface\Buttons\UI-PassiveOverlay" >
			<Size x="64" y="64" />
			<Anchors>
				<Anchor point="CENTER" />
			</Anchors>
		</PushedTexture>
		
		<Layers>
			<Layer level="OVERLAY">
				<Texture name="$parentTainted" setAllPoints="true" hidden="false">
					<Color r="0.7" g="0.1" b="1.0" a="0.4" />
				</Texture>
			</Layer>
		</Layers>
		
		<Frames>
			
			<Frame name="$parentArkBorder" inherits="ARKINV_Border" />
			
		</Frames>
		
		<Scripts>
			
			<OnLoad>
				ArkInventory.Frame_Item_Tainted_OnLoad( self )
			</OnLoad>
			
			<OnEnter>
				ArkInventory.Frame_Tainted_OnEnter( self )
			</OnEnter>
			
			<OnClick>
				-- do nothing
			</OnClick>
			
			<OnDragStart>
				-- do nothing
			</OnDragStart>
			
			<OnReceiveDrag>
				-- do nothing
			</OnReceiveDrag>
			
			<OnMouseUp>
				-- do nothing
			</OnMouseUp>
			
		</Scripts>
		
	</Button>
	
	<Button virtual="true" name="ARKINV_TemplateButtonBarEdit" inherits="ARKINV_TemplateButtonItem" hidden="true">

		<Size x="30" y="30" />
		
		<Anchors>
			<Anchor point="TOPLEFT" />
		</Anchors>

		<Layers>
			<Layer level="BORDER">
				<FontString name="$parentEditText" inherits="ARKINV_GameFontNormalHuge" justifyH="CENTER" justifyV="MIDDLE">
					<Anchors>
						<Anchor point="CENTER" />
					</Anchors>
				</FontString>
			</Layer>
		</Layers>

		<Scripts>
			
			<OnLoad>
				ArkInventory.Frame_Bar_OnLoad( self )
				SetItemButtonTexture( self, [[Interface\Buttons\WHITE8X8]] )
				SetItemButtonTextureVertexColor( self, 0.5, 0.1, 0.1, 0.3 )
			</OnLoad>
			
			<OnEnter>
				ArkInventory.GameTooltipSetText( self, string.format( ArkInventory.Localise["MENU_BAR_TITLE"], self:GetID( ) ) )
			</OnEnter>
			
			<OnDragStart>
				<!-- over-ride template -->
			</OnDragStart>
			
			<OnReceiveDrag>
				<!-- over-ride template -->
			</OnReceiveDrag>
			
			<OnUpdate>
				<!-- over-ride template -->
			</OnUpdate>
			
			<OnEvent>
				<!-- over-ride template -->
			</OnEvent>
			
			<OnMouseUp>
				ArkInventory.MenuBarOpen( self )
			</OnMouseUp>
		
			<OnShow>
				_G[string.format( "%s%s", self:GetName( ), "EditText" )]:SetText( self:GetID( ) )
			</OnShow>
			
			<OnClick>
				<!-- over-ride template -->
			</OnClick>

		</Scripts>
		
	</Button>

	<Button virtual="true" name="ARKINV_TemplateButtonClose" inherits="ARKINV_TemplateButton">
		<Size x="20" y="20" />
		<NormalTexture file="Interface\Buttons\UI-Panel-MinimizeButton-Up">
			<TexCoords left="0.25" right="0.75" top="0.25" bottom="0.75" />
		</NormalTexture>
		<PushedTexture file="Interface\Buttons\UI-Panel-MinimizeButton-Down">
			<TexCoords left="0.25" right="0.75" top="0.25" bottom="0.75" />
		</PushedTexture>
		<HighlightTexture file="Interface\Buttons\UI-Panel-MinimizeButton-Highlight" alphaMode="ADD">
			<TexCoords left="0.25" right="0.75" top="0.25" bottom="0.75" />
		</HighlightTexture>
	</Button>

	<Button virtual="true" name="ARKINV_TemplateButtonClear" inherits="ARKINV_TemplateButton">
		<Size x="20" y="20" />
		<NormalTexture file="Interface\Buttons\UI-GroupLoot-Pass-Up" />
		<PushedTexture file="Interface\Buttons\UI-GroupLoot-Pass-Down" />
		<HighlightTexture file="Interface\Buttons\UI-GroupLoot-Pass-Highlight" alphaMode="ADD" />
		<Scripts>
			<OnClick>
				local filter = _G[string.format( "%s%s", self:GetParent( ):GetName( ), "Filter" )]
				if filter then
					filter:SetText( "" )
					filter:ClearFocus( )
				end
			</OnClick>
			<OnEnter>
				ArkInventory.GameTooltipSetText( self, ArkInventory.Localise["CLEAR"] )
			</OnEnter>
		</Scripts>
		
	</Button>
	
	<Button virtual="true" name="ArkInventory_ChangerPlayerMainTemplate" inherits="PaperDollItemSlotButtonTemplate">
		
		<NormalTexture name="$parentNormalTexture" file="Interface\Buttons\UI-PassiveHighlight" >
			<Anchors>
				<Anchor point="TOPLEFT" />
				<Anchor point="BOTTOMRIGHT" />
			</Anchors>
		</NormalTexture>
		
		<PushedTexture file="Interface\Buttons\UI-PassiveOverlay" >
			<Size x="64" y="64" />
			<Anchors>
				<Anchor point="CENTER" />
			</Anchors>
		</PushedTexture>
		
		<Frames>
			<Frame name="$parentArkBorder" inherits="ARKINV_Border" />
		</Frames>
		
		<Scripts>
			
			<OnLoad>
				ArkInventory.Frame_Changer_Primary_OnLoad( self )
			</OnLoad>
			
			<OnEvent>
				<!-- over-ride template -->
			</OnEvent>
			
			<OnShow>
				<!-- over-ride template -->
			</OnShow>

			<OnHide>
				<!-- over-ride template -->
			</OnHide>

			<OnClick>
				ArkInventory.Frame_Changer_Primary_OnClick( self, button, down )
			</OnClick>
			
            <OnDragStart>
				<!-- over-ride template -->
            </OnDragStart>

			<OnReceiveDrag>
				ArkInventory.Frame_Changer_Primary_OnClick( self )
			</OnReceiveDrag>
			
			<OnEnter>
				ArkInventory.Frame_Changer_Primary_OnEnter( self )
			</OnEnter>
			
			<OnLeave>
				ArkInventory.Frame_Changer_Generic_OnLeave( self )
			</OnLeave>

		</Scripts>

	</Button>
	
	<Button virtual="true" name="ArkInventory_ChangerBankMainTemplate" inherits="ArkInventory_ChangerPlayerMainTemplate">

		<Scripts>

			<OnLoad>
				ArkInventory.Frame_Changer_Primary_OnLoad( self )
			</OnLoad>
			
			<OnClick>
				ArkInventory.Frame_Changer_Primary_OnClick( self, button, down )
			</OnClick>

	        <OnReceiveDrag>
	            ArkInventory.Frame_Changer_Primary_OnClick( self )
	        </OnReceiveDrag>
			
			<OnEnter>
				ArkInventory.Frame_Changer_Primary_OnEnter( self )
			</OnEnter>

		</Scripts>
		
	</Button>
	
	<Button virtual="true" name="ArkInventory_ChangerVaultTabTemplate" inherits="ArkInventory_ChangerPlayerMainTemplate" hidden="true">
	
		<Scripts>
	
			<OnLoad>
				ArkInventory.Frame_Changer_Vault_Tab_OnLoad( self )
			</OnLoad>
			
			<OnClick>
				ArkInventory.Frame_Changer_Vault_Tab_OnClick( self, button, down )
			</OnClick>

	        <OnReceiveDrag>
	            ArkInventory.Frame_Changer_Vault_Tab_OnClick( self )
	        </OnReceiveDrag>
			
			<OnEnter>
				ArkInventory.Frame_Changer_Vault_Tab_OnEnter( self )
			</OnEnter>
			
		</Scripts>
			
	</Button>
	
	<Button virtual="true" name="ArkInventory_ChangerVaultActionTemplate" inherits="ARKINV_TemplateButton" hidden="true">
		
		<Size x="30" y="30" />
		
		<NormalTexture file="Interface\Buttons\UI-SpellbookIcon-NextPage-Up" />
		
		<PushedTexture file="Interface\Buttons\UI-SpellbookIcon-NextPage-Down" />
		
		<Scripts>
			
			<OnLoad>
				ArkInventory.Frame_Changer_Vault_Action_OnLoad( self )
			</OnLoad>
			
			<OnClick>
				ArkInventory.Frame_Changer_Vault_Action_OnClick( self, button, down )
			</OnClick>
			
	        <OnReceiveDrag>
	            -- do nothing
	        </OnReceiveDrag>
			
			<OnEnter>
				ArkInventory.Frame_Changer_Vault_Action_OnEnter( self )
			</OnEnter>
			
		</Scripts>
			
	</Button>
	
	<Button virtual="true" name="ArkInventory_ChangerGenericExtraTemplate" inherits="ArkInventory_ChangerPlayerMainTemplate">
		
		<Scripts>
			
			<OnLoad>
				ArkInventory.Frame_Changer_Secondary_OnLoad( self )
			</OnLoad>
			
			<OnClick>
				ArkInventory.Frame_Changer_Secondary_OnClick( self, button, down )
			</OnClick>
			
			<OnDragStart>
				ArkInventory.Frame_Changer_Secondary_OnDragStart( self )
			</OnDragStart>
			
			<OnReceiveDrag>
				ArkInventory.Frame_Changer_Secondary_OnReceiveDrag( self )
			</OnReceiveDrag>
			
			<OnEnter>
				ArkInventory.Frame_Changer_Secondary_OnEnter( self )
			</OnEnter>
			
		</Scripts>
		
	</Button>
	
	<Button virtual="true" name="ArkInventory_ChangerBattlepetTemplate" inherits="ARKINV_TemplateButtonBattlepetItem" hidden="false">
		<Scripts>
			
			<OnLoad>
				ArkInventory.Frame_Changer_Battlepet_OnLoad( self )
			</OnLoad>
			
			<OnClick>
				ArkInventory.Frame_Changer_Battlepet_OnClick( self )
			</OnClick>
			
			<OnDragStart>
				ArkInventory.Frame_Changer_Battlepet_OnDragStart( self )
			</OnDragStart>
			
			<OnReceiveDrag>
				ArkInventory.Frame_Changer_Battlepet_OnClick( self )
			</OnReceiveDrag>
			
			<OnEnter>
				ArkInventory.Frame_Changer_Battlepet_OnEnter( self )
			</OnEnter>
			
			<OnLeave>
				ArkInventory.Frame_Changer_Battlepet_OnLeave( self )
			</OnLeave>
			
		</Scripts>
		
	</Button>
	
	
	
	
	<Frame virtual="true" name="ARKINV_TemplateFrameBar" inherits="ARKINV_TemplateFrameStandard">

		<Size x="20" y="20" />

		<Layers>
			<Layer level="BORDER">
				<FontString name="$parentLabel" inherits="ARKINV_GameFontNormal" justifyH="LEFT" hidden="true">
					<Anchors>
						<Anchor point="TOPLEFT" x="4" y="-4" />
						<Anchor point="RIGHT" x="-4" y="0" />
					</Anchors>
				</FontString>
			</Layer>
		</Layers>
		
		<Frames>
			<Button name="$parentEdit" inherits="ARKINV_TemplateButtonBarEdit" hidden="true" />
		</Frames>
		
		<Scripts>
			<OnLoad>
				ArkInventory.Frame_Bar_OnLoad( self )
			</OnLoad>
		</Scripts>

	</Frame>
	
	<Frame virtual="true" name="ARKINV_TemplateFrameBag">

		<Size x="1" y="1" />

		<Anchors>
			<Anchor point="TOPLEFT" />
		</Anchors>
		
		<Scripts>
			<OnLoad>
				ArkInventory.Frame_Bag_OnLoad( self )
			</OnLoad>
		</Scripts>
		
	</Frame>
	
	<Frame virtual="true" name="ARKINV_TemplateFrameMainTitle" inherits="ARKINV_TemplateFrameStandard">

		<Size x="400" y="40" />

		<Anchors>
			<Anchor point="TOPLEFT" />
			<Anchor point="RIGHT" />
		</Anchors>
		
		<Frames>
		
			<Button name="$parentLocation0" inherits="ARKINV_TemplateButtonAction">
				<Size x="42" y="42" />
				<Anchors>
					<Anchor point="TOPLEFT" x="8" y="-8" />
				</Anchors>
				<Scripts>
					<OnClick>
						ArkInventory.MenuMainOpen( self )
					</OnClick>
					<OnEnter>
						ArkInventory.GameTooltipSetText( self, ArkInventory.Localise["MENU"] )
					</OnEnter>
				</Scripts>
			</Button>
			
			<Button name="$parentClose" inherits="ARKINV_TemplateButtonClose">
				<Anchors>
					<Anchor point="TOPRIGHT" x="-8" y="-8" />
				</Anchors>
				<Scripts>
					<OnClick>
						ArkInventory.Frame_Main_Hide( self:GetParent( ):GetParent( ):GetID( ) )
					</OnClick>
				</Scripts>
			</Button>
			
			
			<!-- top action button row -->
			<Button name="$parentActionButton11" inherits="ARKINV_TemplateButtonAction">
				<Anchors>
					<Anchor point="RIGHT" relativeTo="$parentClose" relativePoint="LEFT" x="-3" y="0" />
				</Anchors>
			</Button>
			
			<Button name="$parentActionButton12" inherits="ARKINV_TemplateButtonAction">
				<Anchors>
					<Anchor point="RIGHT" relativeTo="$parentActionButton11" relativePoint="LEFT" x="-3" y="0" />
				</Anchors>
			</Button>
			
			<Button name="$parentActionButton13" inherits="ARKINV_TemplateButtonAction">
				<Anchors>
					<Anchor point="RIGHT" relativeTo="$parentActionButton12" relativePoint="LEFT" x="-3" y="0" />
				</Anchors>
			</Button>
			
			<Button name="$parentActionButton14" inherits="ARKINV_TemplateButtonAction">
				<Anchors>
					<Anchor point="RIGHT" relativeTo="$parentActionButton13" relativePoint="LEFT" x="-3" y="0" />
				</Anchors>
			</Button>
			
			
			<!-- bottom action button row -->
			<Button name="$parentActionButton21" inherits="ARKINV_TemplateButtonAction">
				<Anchors>
					<Anchor point="TOP" relativeTo="$parentActionButton11" relativePoint="BOTTOM" x="0" y="-2" />
				</Anchors>
			</Button>
			
			<Button name="$parentActionButton22" inherits="ARKINV_TemplateButtonAction">
				<Anchors>
					<Anchor point="RIGHT" relativeTo="$parentActionButton21" relativePoint="LEFT" x="-3" y="0" />
				</Anchors>
			</Button>
			
			<Button name="$parentActionButton23" inherits="ARKINV_TemplateButtonAction">
				<Anchors>
					<Anchor point="RIGHT" relativeTo="$parentActionButton22" relativePoint="LEFT" x="-3" y="0" />
				</Anchors>
			</Button>

			<Button name="$parentActionButton24" inherits="ARKINV_TemplateButtonAction">
				<Anchors>
					<Anchor point="RIGHT" relativeTo="$parentActionButton23" relativePoint="LEFT" x="-3" y="0" />
				</Anchors>
			</Button>
			
			
			<Frame>
				<Layers>
					<Layer level="ARTWORK">
						<FontString name="$parentWho" inherits="ARKINV_GameFontNormalHuge" justifyH="LEFT" text="?">
							<Anchors>
								<Anchor point="TOP" relativeTo="$parentLocation0" relativePoint="TOP" />
								<Anchor point="BOTTOMLEFT" relativeTo="$parentLocation0" relativePoint="BOTTOMRIGHT" />
								<Anchor point="RIGHT" relativeTo="$parentActionButton24" relativePoint="LEFT" />
							</Anchors>
						</FontString>
					</Layer>
				</Layers>
			</Frame>

		</Frames>

	</Frame>

	<Frame virtual="true" name="ARKINV_TemplateFrameMainSearch" inherits="ARKINV_TemplateFrameStandard">

		<Size x="2" y="40" />

		<Anchors>
			<Anchor point="TOPLEFT" relativeTo="$parentTitle" relativePoint="BOTTOMLEFT" x="0" y="4" />
			<Anchor point="RIGHT" />
		</Anchors>
		
		<Frames>
		
			<Button name="$parentClear" inherits="ARKINV_TemplateButtonClear">
				<Anchors>
					<Anchor point="RIGHT" x="-8" y="0" />
				</Anchors>
			</Button>
			
			<EditBox name="$parentFilter" inherits="ARKINV_TemplateEditBox" letters="80">
			
				<Size x="2" y="20" />
				
				<Anchors>
					<Anchor point="LEFT" x="120" y="0" />
					<Anchor point="RIGHT" relativeTo="$parentClear" relativePoint="LEFT" x="-2" y="0" />
				</Anchors>
				
				<Scripts>
					
					<OnLoad>
						ArkInventory.UiSetEditBoxLabel( self, string.format( "%s:", ArkInventory.Localise["SEARCH"] ) )
					</OnLoad>
					
					<OnShow>
						self:SetText( "" )
						self:ClearFocus( )
					</OnShow>
					
					<OnCursorChanged>
						ArkInventory.Frame_Main_Search( self:GetParent( ):GetParent( ):GetName( ) )
					</OnCursorChanged>
					
					<OnEnterPressed>
						self:ClearFocus( )
					</OnEnterPressed>
					
				</Scripts>
				
			</EditBox>
			
		</Frames>
		
	</Frame>
	
	<Frame virtual="true" name="ARKINV_TemplateFrameMainContainer" inherits="ARKINV_TemplateFrameStandard">

		<Size x="400" y="40" />

		<Anchors>
			<Anchor point="TOPLEFT" relativeTo="$parentSearch" relativePoint="BOTTOMLEFT" x="0" y="4" />
			<Anchor point="RIGHT" />
		</Anchors>

		<Frames>
			<Frame name="$parentBar" />
			<Frame name="$parentBag" />
		</Frames>

		<Scripts>
			<OnLoad>
				ArkInventory.Frame_Container_OnLoad( self )
			</OnLoad>
		</Scripts>

	</Frame>
	
	<Frame virtual="true" name="ARKINV_TemplateFrameMainChanger" inherits="ARKINV_TemplateFrameStandard" hidden="false">

		<Size x="1" y="58" />

		<Anchors>
			<Anchor point="TOPLEFT" relativeTo="$parentContainer" relativePoint="BOTTOMLEFT" x="0" y="3" />
			<Anchor point="RIGHT" />
		</Anchors>

	</Frame>
	
	<Frame virtual="true" name="ARKINV_CurrencyTracking" hidden="true">
		<Size x="1" y="1" />
		<Layers>
			<Layer level="ARTWORK">
				<Texture parentKey="icon" name="$parentIcon" inherits="ARKINV_TextureUnknown" hidden="false">
					<Anchors>
						<Anchor point="TOPLEFT" />
					</Anchors>
				</Texture>
				<FontString parentKey="count" name="$parentCount" text="NO DATA" inherits="ARKINV_GameFontNormalLarge" hidden="false">
					<Anchors>
						<Anchor point="LEFT" relativeTo="$parentIcon" relativePoint="RIGHT" />
					</Anchors>
				</FontString>
			</Layer>
		</Layers>
		<Scripts>
			<OnLoad>
				self:SetHeight( self.icon:GetHeight( ) )
			</OnLoad>
			<OnEnter>
				ArkInventory.GameTooltipSetHyperlink( self, GetCurrencyLink( self.currencyID ) )
			</OnEnter>
			<OnLeave>
				ArkInventory.GameTooltipHide( )
			</OnLeave>
			<OnMouseUp>
				if ( IsModifiedClick("CHATLINK") ) then
					HandleModifiedItemClick( GetCurrencyLink( self.currencyID ) )
				else
					ToggleCharacter( "TokenFrame" )
				end
			</OnMouseUp>
		</Scripts>
	</Frame>
	
	<Frame virtual="true" name="ARKINV_TemplateFrameMainStatus" inherits="ARKINV_TemplateFrameStandard" hidden="false">
		
		<Anchors>
			<Anchor point="TOPLEFT" relativeTo="$parentChanger" relativePoint="BOTTOMLEFT" x="0" y="3" />
			<Anchor point="RIGHT" />
		</Anchors>
		
		<Layers>
			<Layer level="ARTWORK">
				
				<FontString name="$parentEmptyText" inherits="ARKINV_GameFontNormalLarge" justifyH="LEFT" text="NO DATA">
					<Anchors>
						<Anchor point="LEFT" x="10" y="0" />
					</Anchors>
					<Color r="1" g="1" b="1" a="1" />
				</FontString>
				
			</Layer>
		</Layers>
		
		<Frames>
			
			<Frame name="$parentGold" inherits="ArkInventory_SmallMoneyFrameTemplate">
				<Anchors>
					<Anchor point="RIGHT" />
				</Anchors>
				<Scripts>
					<OnLoad>
						ArkInventory.SmallMoneyFrame_OnLoad( self, "STATIC" )
					</OnLoad>
				</Scripts>
			</Frame>
			
			<Frame name="$parentTracking1" inherits="ARKINV_CurrencyTracking" hidden="true">
					<Anchors>
						<Anchor point="LEFT" relativeTo="$parentEmptyText" relativePoint="RIGHT" x="20" y="0" />
					</Anchors>
			</Frame>
		
			<Frame name="$parentTracking2" inherits="ARKINV_CurrencyTracking" hidden="true">
				<Anchors>
					<Anchor point="LEFT" relativeTo="$parentTracking1" relativePoint="RIGHT" />
				</Anchors>
			</Frame>
		
			<Frame name="$parentTracking3" inherits="ARKINV_CurrencyTracking" hidden="true">
				<Anchors>
					<Anchor point="LEFT" relativeTo="$parentTracking2" relativePoint="RIGHT" />
				</Anchors>
			</Frame>
			
		</Frames>
		
	</Frame>

	<Frame virtual="true" name="ARKINV_TemplateFrameMainLog" inherits="ARKINV_TemplateFrameStandard" hidden="true">

		<Anchors>
			<Anchor point="TOPLEFT" relativeTo="$parentContainer" />
			<Anchor point="BOTTOMRIGHT" relativeTo="$parentContainer" />
		</Anchors>
	
		<Layers>
			<Layer level="ARTWORK">
				<FontString name="$parentText" inherits="ARKINV_GameFontNormal" text="Height" hidden="true">
					<Anchor point="TOPLEFT" />
				</FontString>
			</Layer>
		</Layers>

		<Frames>
		
			<ScrollingMessageFrame name="$parentList" fade="false" enableMouse="true">
				<Anchors>
					<Anchor point="TOPLEFT" x="10" y="-10" />
					<Anchor point="BOTTOMRIGHT" x="-40" y="10" />
				</Anchors>
				<FontString inherits="ARKINV_TableRowFont" JustifyH="LEFT" />
				<Scripts>
					<OnHyperlinkClick>
						SetItemRef( link, text, button, chatFrame )
					</OnHyperlinkClick>
					<OnMouseWheel>
						ArkInventory.ScrollingMessageFrame_ScrollWheel( self:GetParent( ), "List", delta )
					</OnMouseWheel>
				</Scripts>
			</ScrollingMessageFrame>

			<Button name="$parentScrollUp" inherits="ARKINV_TemplateButtonAction">
				<Size x="30" y="30" />
				<NormalTexture file="Interface\ChatFrame\UI-ChatIcon-ScrollUp-Up" />
				<PushedTexture file="Interface\ChatFrame\UI-ChatIcon-ScrollUp-Down" />
				<DisabledTexture file="Interface\ChatFrame\UI-ChatIcon-ScrollUp-Disabled" />
				<HighlightTexture file="Interface\Buttons\UI-Common-MouseHilight" alphaMode="ADD" />
				<Anchors>
					<Anchor point="TOPLEFT" relativeTo="$parentList" relativePoint="TOPRIGHT" x="5" y="0" />
				</Anchors>
				<Scripts>
					<OnClick>
						ArkInventory.ScrollingMessageFrame_Scroll( self:GetParent( ), "List", "up" )
					</OnClick>
				</Scripts>
			</Button>


			<Button name="$parentScrollDown" inherits="ARKINV_TemplateButtonAction">
				<Size x="30" y="30" />
				<NormalTexture file="Interface\ChatFrame\UI-ChatIcon-ScrollDown-Up" />
				<PushedTexture file="Interface\ChatFrame\UI-ChatIcon-ScrollDown-Down" />
				<DisabledTexture file="Interface\ChatFrame\UI-ChatIcon-ScrollDown-Disabled" />
				<HighlightTexture file="Interface\Buttons\UI-Common-MouseHilight" alphaMode="ADD" />
				<Anchors>
					<Anchor point="BOTTOMLEFT" relativeTo="$parentList" relativePoint="BOTTOMRIGHT" x="5" y="0" />
				</Anchors>
				<Scripts>
					<OnClick>
						ArkInventory.ScrollingMessageFrame_Scroll( self:GetParent( ), "List", "down" )
					</OnClick>
				</Scripts>
			</Button>

		</Frames>
	
	</Frame>

	<Frame virtual="true" name="ARKINV_TemplateFrameMainInfo" inherits="ARKINV_TemplateFrameStandard" hidden="true">
		
		<Anchors>
			<Anchor point="TOPLEFT" relativeTo="$parentContainer" />
			<Anchor point="BOTTOMRIGHT" relativeTo="$parentContainer" />
		</Anchors>
	
		<Frames>
			
			<ScrollFrame name="$parentScroll" inherits="UIPanelScrollFrameTemplate">
				
				<Anchors>
					<Anchor point="TOP" x="0" y="-10" />
					<Anchor point="LEFT" x="5" y="0" />
					<Anchor point="RIGHT" x="-30" y="0" />
					<Anchor point="BOTTOM" x="0" y="40" />
				</Anchors>
				
				<ScrollChild>
					
					<EditBox name="$parentInfo" historyLines="0" multiLine="true" autoFocus="false">
						
						<Size x="1" y="1" />
						
						<Anchors>
							<Anchor point="TOPLEFT" />
							<Anchor point="BOTTOMRIGHT" />
						</Anchors>
						
						<FontString inherits="ARKINV_DataEntryFont" />
						
						<Scripts>
							
							<OnEscapePressed>
								self:ClearFocus( )
							</OnEscapePressed>
							
							<OnTextChanged>
								ScrollingEdit_OnTextChanged( self )
								ArkInventory.Frame_Vault_Info_Changed( self )
							</OnTextChanged>
							
							<OnCursorChanged>
								ScrollingEdit_OnCursorChanged( self, x, y, w, h )
							</OnCursorChanged>
							
							<OnUpdate>
								ScrollingEdit_OnUpdate( self, elapsed )
							</OnUpdate>
							
							<OnShow>
								self:SetWidth( self:GetParent( ):GetWidth( ) )
							</OnShow>
							
						</Scripts>
						
					</EditBox>
					
				</ScrollChild>
				
				<Scripts>
					<OnMouseDown>
						local obj = _G[self:GetName( ).."Info"]
						if CanEditGuildTabInfo( GetCurrentGuildBankTab( ) ) then
							obj:SetFocus( )
						else
							obj:ClearFocus( )
						end
					</OnMouseDown>
					<OnMouseUp>
						local obj = _G[self:GetName( ).."Info"]
						if CanEditGuildTabInfo( GetCurrentGuildBankTab( ) ) then
							obj:SetFocus( )
						else
							obj:ClearFocus( )
						end
					</OnMouseUp> 
				</Scripts>
				
			</ScrollFrame>
			
			<Button name="$parentSave" inherits="UIPanelButtonTemplate" text="SAVE_CHANGES" hidden="false">
				
				<Size x="1" y="22" />
				
				<Anchors>
					<Anchor point="TOP" relativeTo="$parentScroll" relativePoint="BOTTOM" x="0" y="-5" />
				</Anchors>
				
				<Scripts>
					
					<OnLoad>
						self:SetWidth( _G[self:GetName().."Text"]:GetWidth() + 40 )
					</OnLoad>
					
					<OnClick>
						local obj = _G[self:GetParent( ):GetName( ).."ScrollInfo"]
						SetGuildBankText( GetCurrentGuildBankTab( ), obj:GetText( ) )
						obj:ClearFocus( )
						self:Disable( )
					</OnClick>
					
				</Scripts>
				
			</Button>

		</Frames>
	
	</Frame>

	<Frame virtual="true" name="ARKINV_TemplateFrameMainScanOnly" parent="UIParent" toplevel="true" movable="true" enableMouse="true" hidden="true" frameStrata="MEDIUM">
		<Scripts>
			<OnLoad>
				ArkInventory.Frame_Main_OnLoad( self )
			</OnLoad>
		</Scripts>
	</Frame>

	<Frame virtual="true" name="ARKINV_TemplateFrameMain" parent="UIParent" toplevel="true" movable="true" enableMouse="true" hidden="true" frameStrata="MEDIUM">
		
		<Size x="400" y="180" />
		
		<Anchors>
			<Anchor point="TOPLEFT" />
		</Anchors>
		
		<Frames>
			<Frame name="$parentTitle" inherits="ARKINV_TemplateFrameMainTitle" />
			<Frame name="$parentSearch" inherits="ARKINV_TemplateFrameMainSearch" />
			<Frame name="$parentContainer" inherits="ARKINV_TemplateFrameMainContainer" />
			<Frame name="$parentChanger" inherits="ARKINV_TemplateFrameMainChanger" hidden="false" />
			<Frame name="$parentStatus" inherits="ARKINV_TemplateFrameMainStatus" hidden="false" />
		</Frames>
		
		<Scripts>
			<OnLoad>
				ArkInventory.Frame_Main_OnLoad( self )
			</OnLoad>
			<OnDragStart>
				ArkInventory.FrameDragStart( self )
			</OnDragStart>
			<OnDragStop>
				ArkInventory.FrameDragStop( self )
			</OnDragStop>
			<OnShow>
				ArkInventory.Frame_Main_OnShow( self )
			</OnShow>
			<OnHide>
				ArkInventory.Frame_Main_OnHide( self )
			</OnHide>
		</Scripts>
		
	</Frame>

	<Frame virtual="true" name="ArkInventory_SmallMoneyFrameTemplate">
		
		<Size x="128" y="13" />
		
		<Frames>
			
			<Button name="$parentCopperButton" jumpNavigateEnabled="false">
				
				<Size x="32" y="13" />
				
				<Anchors>
					<Anchor point="RIGHT" x="-13" y="0" />
				</Anchors>
				
				<NormalTexture file="Interface\MoneyFrame\UI-MoneyIcons">
					<Size x="13" y="13" />
					<Anchors>
						<Anchor point="RIGHT" />
					</Anchors>
					<TexCoords left="0.5" right="0.75" top="0" bottom="1" />
				</NormalTexture>
				
				<ButtonText name="$parentText">
					<Anchors>
						<Anchor point="RIGHT" x="-13" y="0" />
					</Anchors>
				</ButtonText>
				
				<NormalFont style="NumberFontNormalRight" />
				
				<PushedTextOffset x="0" y="0" />
				
				<Scripts>
					<OnEnter>
						ArkInventory.MoneyFrame_OnEnter( self:GetParent( ) )
					</OnEnter>
					<OnLeave>
						ArkInventory.GameTooltipHide( )
					</OnLeave>
					<OnClick>
						local parent = self:GetParent( )
						OpenCoinPickupFrame( 1, MoneyTypeInfo[parent.moneyType].UpdateFunc( self ), parent )
						parent.hasPickup = 1
					</OnClick>
				</Scripts>
				
			</Button>
			
			<Button name="$parentSilverButton" jumpNavigateEnabled="false">
				
				<Size x="32" y="13" />
				
				<Anchors>
					<Anchor point="RIGHT" relativeTo="$parentCopperButton" relativePoint="LEFT" x="-4" y="0" />
				</Anchors>
				
				<NormalTexture file="Interface\MoneyFrame\UI-MoneyIcons">
					<Size x="13" y="13" />
					<Anchors>
						<Anchor point="RIGHT" />
					</Anchors>
					<TexCoords left="0.25" right="0.5" top="0" bottom="1" />
				</NormalTexture>
				
				<ButtonText name="$parentText">
					<Anchors>
						<Anchor point="RIGHT" x="-13" y="0" />
					</Anchors>
				</ButtonText>
				
				<NormalFont style="NumberFontNormalRight" />
				
				<PushedTextOffset x="0" y="0" />
		
				<Scripts>
					<OnEnter>
						ArkInventory.MoneyFrame_OnEnter( self:GetParent( ) )
					</OnEnter>
					<OnLeave>
						ArkInventory.GameTooltipHide( )
					</OnLeave>
					<OnClick>
						local parent = self:GetParent( )
						OpenCoinPickupFrame( COPPER_PER_SILVER, MoneyTypeInfo[parent.moneyType].UpdateFunc( self ), parent )
						parent.hasPickup = 1
					</OnClick>
				</Scripts>
				
			</Button>
			
			<Button name="$parentGoldButton" jumpNavigateEnabled="false">
				
				<Size x="32" y="13" />
				
				<Anchors>
					<Anchor point="RIGHT" relativeTo="$parentSilverButton" relativePoint="LEFT" x="-4" y="0" />
				</Anchors>
				
				<NormalTexture file="Interface\MoneyFrame\UI-MoneyIcons">
					<Size x="13" y="13" />
					<Anchors>
						<Anchor point="RIGHT" />
					</Anchors>
					<TexCoords left="0" right="0.25" top="0" bottom="1" />
				</NormalTexture>
				
				<ButtonText name="$parentText">
					<Anchors>
						<Anchor point="RIGHT" x="-13" y="0" />
					</Anchors>
				</ButtonText>
				
				<NormalFont style="NumberFontNormalRight" />
				
				<PushedTextOffset x="0" y="0" />
				
				<Scripts>
					<OnEnter>
						ArkInventory.MoneyFrame_OnEnter( self:GetParent( ) )
					</OnEnter>
					<OnLeave>
						ArkInventory.GameTooltipHide( )
					</OnLeave>
					<OnClick>
						local parent = self:GetParent( )
						OpenCoinPickupFrame( COPPER_PER_GOLD, MoneyTypeInfo[parent.moneyType].UpdateFunc( self ), parent )
						parent.hasPickup = 1
					</OnClick>
				</Scripts>
				
			</Button>
			
		</Frames>
		
		<Scripts>
			<OnLoad>
				ArkInventory.SmallMoneyFrame_OnLoad( self )
			</OnLoad>
			<OnEvent>
				ArkInventory.MoneyFrame_OnEvent( self, event, ... )
			</OnEvent>
			<OnShow>
				ArkInventory.MoneyFrame_UpdateMoney( self )
			</OnShow>
			<OnHide>
				if ( self.hasPickup == 1 ) then
					CoinPickupFrame:Hide( );
					self.hasPickup = 0;
				end
			</OnHide>
		</Scripts>
		
	</Frame>
	
	<Button virtual="true" name="ARKINV_TemplateTableRow" mouseEnabled="true" hidden="true">
	
		<Size x="1" y="1" />
		
		<Anchors>
			<Anchor point="LEFT" />
			<Anchor point="RIGHT" x="-20" y="0" />
		</Anchors>
		
		<Layers>
		
			<Layer level="OVERLAY">
			
				<!-- objects in this layer are rearranged via LUA for each table -->
				
				<Texture name="$parentT1" inherits="ARKINV_TextureUnknown" hidden="true" />
				<Texture name="$parentT2" inherits="ARKINV_TextureUnknown" hidden="true" />
				<Texture name="$parentT3" inherits="ARKINV_TextureUnknown" hidden="true" />
				<Texture name="$parentT4" inherits="ARKINV_TextureUnknown" hidden="true" />
				<Texture name="$parentT5" inherits="ARKINV_TextureUnknown" hidden="true" />
				
				<FontString name="$parentC1" inherits="ARKINV_TableRowFont" hidden="true" />
				<FontString name="$parentC2" inherits="ARKINV_TableRowFont" hidden="true" />
				<FontString name="$parentC3" inherits="ARKINV_TableRowFont" hidden="true" />
				<FontString name="$parentC4" inherits="ARKINV_TableRowFont" hidden="true" />
				<FontString name="$parentC5" inherits="ARKINV_TableRowFont" hidden="true" />
				
				<FontString name="$parentData" inherits="ARKINV_TableRowFont" hidden="true" />
				
			</Layer>
			
			<Layer level="BACKGROUND">

				<FontString name="$parentId" inherits="ARKINV_TableRowFont" hidden="true" />
			
				<Texture name="$parentHighlight" inherits="ARKINV_TextureHighlight">
					<Anchors>
						<Anchor point="TOPLEFT" x="5" y="0" />
						<Anchor point="BOTTOMRIGHT" x="-5" y="0" />
					</Anchors>
				</Texture>

				<Texture name="$parentSelected" inherits="ARKINV_TextureSelected">
					<Anchors>
						<Anchor point="TOPLEFT" x="5" y="0" />
						<Anchor point="BOTTOMRIGHT" x="-5" y="0" />
					</Anchors>
				</Texture>

			</Layer>

		</Layers>

		<Scripts>

			<OnLoad>
			
				self:RegisterForClicks( "LeftButtonUp", "RightButtonUp" )
				
				function self.ArkTableRowOnClick( button )
					local obj = _G[self:GetParent( ):GetName( )]
					if obj and obj["ArkTableRowOnClick"] then
						obj.ArkTableRowOnClick( self, button )
					end
				end
				
				function self.ArkTableRowOnEnter( )
					local obj = _G[self:GetParent( ):GetName( )]
					if obj and obj["ArkTableRowOnEnter"] then
						obj.ArkTableRowOnEnter( self )
					end
				end
				
				function self.ArkTableRowOnLeave( )
					local obj = _G[self:GetParent( ):GetName( )]
					if obj and obj["ArkTableRowOnLeave"] then
						obj.ArkTableRowOnLeave( self )
					end
				end
				
			</OnLoad>

			<OnEnter>
				_G[string.format( "%s%s", self:GetName( ), "Highlight" )]:Show( )
				self.ArkTableRowOnEnter( )
			</OnEnter>

			<OnLeave>
				_G[string.format( "%s%s", self:GetName( ), "Highlight" )]:Hide( )
				self.ArkTableRowOnLeave( )
			</OnLeave>

			<OnClick>
				
				if button == "LeftButton" then
					
					PlaySound( "igMainMenuOptionCheckBoxOn" )
					
					local f = self:GetName( )
					--ArkInventory.Output( "OnClick( ", f, ", ", button, " )" )
					
					local parent = self:GetParent( ):GetName( )
					
					local cs = _G[string.format( parent, "ArkSelectedRow" )]:GetText( )
					local ns = tostring( self:GetID( ) )
					
					if ns == "0" then
						ArkInventory.Output( "XML [", self:GetName( ), "] has no ID" )
						return
					end
					
					
					-- show/hide the "selected" background
					if cs ~= "-1" then
						_G[string.format( "%s%s%s%s", parent, "Row", cs, "Selected" )]:Hide( )
					end
					
					if cs == ns then
						_G[string.format( "%s%s", parent, "ArkSelectedRow" )]:SetText( "-1" )
						_G[string.format( "%s%s", parent, "ArkSelectedId" )]:SetText( "-1" )
					else
						_G[string.format( "%s%s", parent, "ArkSelectedRow" )]:SetText( ns )
						_G[string.format( "%s%s", parent, "ArkSelectedId" )]:SetText( _G[string.format( "%s%s", f, "Id" )]:GetText( ) )
						_G[string.format( "%s%s", f, "Selected" )]:Show( )
					end
					
				end
				
				self.ArkTableRowOnClick( button )
				
			</OnClick>
			
		</Scripts>
		
	</Button>

	
<!-- ADDON FRAME STARTS HERE -->
	
	<Frame hidden="true">
		<Scripts>
			<OnLoad>
				ArkInventory.OnLoad( )
			</OnLoad>
		</Scripts>
	</Frame>
	
	<Frame name="ARKINV_Frame1" inherits="ARKINV_TemplateFrameMain" id="1" /> <!-- bag -->
	
	<Frame parent="ARKINV_Frame1Changer" name="$parentWindow" hidden="false">
	
		<Size x="1" y="1" />
	
		<Anchors>
			<Anchor point="LEFT" />
			<Anchor point="RIGHT" />
		</Anchors>
	
		<Frames>
		
			<CheckButton name="$parentBag1" inherits="ArkInventory_ChangerPlayerMainTemplate">
				<Anchors>
					<Anchor point="LEFT" x="8" y="0" />
				</Anchors>
			</CheckButton>
			
			<CheckButton name="$parentBag2" inherits="ArkInventory_ChangerGenericExtraTemplate">
				<Anchors>
					<Anchor point="LEFT" relativeTo="$parentBag1" relativePoint="RIGHT" x="5" y="0" />
				</Anchors>
			</CheckButton>
			
			<CheckButton name="$parentBag3" inherits="ArkInventory_ChangerGenericExtraTemplate">
				<Anchors>
					<Anchor point="LEFT" relativeTo="$parentBag2" relativePoint="RIGHT" x="5" y="0" />
				</Anchors>
			</CheckButton>

			<CheckButton name="$parentBag4" inherits="ArkInventory_ChangerGenericExtraTemplate">
				<Anchors>
					<Anchor point="LEFT" relativeTo="$parentBag3" relativePoint="RIGHT" x="5" y="0" />
				</Anchors>
			</CheckButton>
		
			<CheckButton name="$parentBag5" inherits="ArkInventory_ChangerGenericExtraTemplate">
				<Anchors>
					<Anchor point="LEFT" relativeTo="$parentBag4" relativePoint="RIGHT" x="5" y="0" />
				</Anchors>
			</CheckButton>

		</Frames>
		
	</Frame>
	
	

	
	<Frame name="ARKINV_Frame3" inherits="ARKINV_TemplateFrameMain" id="3" /> <!-- bank -->
	
	<Frame parent="ARKINV_Frame3Changer" name="$parentWindow" hidden="false">

		<Size x="1" y="1" />
	
		<Anchors>
			<Anchor point="TOPLEFT" />
			<Anchor point="BOTTOMRIGHT" />
		</Anchors>
	
		<Frames>
		
			<Button name="$parentBag1" inherits="ArkInventory_ChangerBankMainTemplate">

				<Anchors>
					<Anchor point="LEFT" x="10" y="0" />
				</Anchors>
				
			</Button>
			
			<Button name="$parentBag2" inherits="ArkInventory_ChangerGenericExtraTemplate">
				<Anchors>
					<Anchor point="LEFT" relativeTo="$parentBag1" relativePoint="RIGHT" x="5" y="0" />
				</Anchors>
			</Button>
			
			<Button name="$parentBag3" inherits="ArkInventory_ChangerGenericExtraTemplate">
				<Anchors>
					<Anchor point="LEFT" relativeTo="$parentBag2" relativePoint="RIGHT" x="5" y="0" />
				</Anchors>
			</Button>
			
			<Button name="$parentBag4" inherits="ArkInventory_ChangerGenericExtraTemplate">
				<Anchors>
					<Anchor point="LEFT" relativeTo="$parentBag3" relativePoint="RIGHT" x="5" y="0" />
				</Anchors>
			</Button>
			
			<Button name="$parentBag5" inherits="ArkInventory_ChangerGenericExtraTemplate">
				<Anchors>
					<Anchor point="LEFT" relativeTo="$parentBag4" relativePoint="RIGHT" x="5" y="0" />
				</Anchors>
			</Button>
			
			<Button name="$parentBag6" inherits="ArkInventory_ChangerGenericExtraTemplate">
				<Anchors>
					<Anchor point="LEFT" relativeTo="$parentBag5" relativePoint="RIGHT" x="5" y="0" />
				</Anchors>
			</Button>

			<Button name="$parentBag7" inherits="ArkInventory_ChangerGenericExtraTemplate">
				<Anchors>
					<Anchor point="LEFT" relativeTo="$parentBag6" relativePoint="RIGHT" x="5" y="0" />
				</Anchors>
			</Button>
			
			<Button name="$parentBag8" inherits="ArkInventory_ChangerGenericExtraTemplate">
				<Anchors>
					<Anchor point="LEFT" relativeTo="$parentBag7" relativePoint="RIGHT" x="5" y="0" />
				</Anchors>
			</Button>

			<Frame name="$parentPurchaseInfo">
			
				<Size x="130" y="38" />
				
				<Anchors>
					<Anchor point="RIGHT" />
				</Anchors>
				
				<Layers>
					<Layer level="BACKGROUND">
						<FontString name="$parentSlotCost" inherits="ARKINV_GameFontNormal" text="COSTS_LABEL">
							<Size x="0" y="12" />
							<Anchors>
								<Anchor point="TOPLEFT" />
							</Anchors>
						</FontString>
					</Layer>
				</Layers>

				<Frames>

					<Button name="$parentPurchaseButton" inherits="UIPanelButtonTemplate" text="BANKSLOTPURCHASE">
						<Size x="124" y="21" />
						<Anchors>
							<Anchor point="BOTTOMLEFT" />
						</Anchors>
						<Scripts>
							<OnClick>
								PlaySound( "igMainMenuOption" )
								StaticPopup_Show( "CONFIRM_BUY_BANK_SLOT" )
							</OnClick>
						</Scripts>
					</Button>

					<Frame name="$parentDetailMoneyFrame" inherits="ArkInventory_SmallMoneyFrameTemplate">
					
						<Anchors>
							<Anchor point="LEFT" relativeTo="$parentSlotCost" relativePoint="RIGHT" x="10" y="0" />
						</Anchors>
						
						<Scripts>
							<OnLoad>
								ArkInventory.SmallMoneyFrame_OnLoad( self, "STATIC" )
							</OnLoad>
						</Scripts>
						
					</Frame>
					
				</Frames>

			</Frame>

		</Frames>
		
	</Frame>


	<Frame name="ARKINV_Frame4" inherits="ARKINV_TemplateFrameMain" id="4"> <!-- vault -->
	
		<Frames>
			
			<Frame name="$parentLog" inherits="ARKINV_TemplateFrameMainLog" />
			<Frame name="$parentInfo" inherits="ARKINV_TemplateFrameMainInfo" />

		</Frames>
	
	</Frame>
	
	<Frame parent="ARKINV_Frame4Changer" name="$parentWindow" hidden="false">

		<Size x="1" y="1" />
	
		<Anchors>
			<Anchor point="TOPLEFT" />
			<Anchor point="BOTTOMRIGHT" />
		</Anchors>
	
		<Frames>
			
			<Button name="$parentBag1" inherits="ArkInventory_ChangerVaultTabTemplate">
				<Anchors>
					<Anchor point="LEFT" x="10" y="0" />
				</Anchors>
			</Button>
			
			<Button name="$parentBag2" inherits="ArkInventory_ChangerVaultTabTemplate">
				<Anchors>
					<Anchor point="LEFT" relativeTo="$parentBag1" relativePoint="RIGHT" x="5" y="0" />
				</Anchors>
			</Button>
			
			<Button name="$parentBag3" inherits="ArkInventory_ChangerVaultTabTemplate">
				<Anchors>
					<Anchor point="LEFT" relativeTo="$parentBag2" relativePoint="RIGHT" x="5" y="0" />
				</Anchors>
			</Button>
			
			<Button name="$parentBag4" inherits="ArkInventory_ChangerVaultTabTemplate">
				<Anchors>
					<Anchor point="LEFT" relativeTo="$parentBag3" relativePoint="RIGHT" x="5" y="0" />
				</Anchors>
			</Button>
			
			<Button name="$parentBag5" inherits="ArkInventory_ChangerVaultTabTemplate">
				<Anchors>
					<Anchor point="LEFT" relativeTo="$parentBag4" relativePoint="RIGHT" x="5" y="0" />
				</Anchors>
			</Button>
			
			<Button name="$parentBag6" inherits="ArkInventory_ChangerVaultTabTemplate">
				<Anchors>
					<Anchor point="LEFT" relativeTo="$parentBag5" relativePoint="RIGHT" x="5" y="0" />
				</Anchors>
			</Button>
			
			<Button name="$parentBag7" inherits="ArkInventory_ChangerVaultTabTemplate">
				<Anchors>
					<Anchor point="LEFT" relativeTo="$parentBag6" relativePoint="RIGHT" x="5" y="0" />
				</Anchors>
			</Button>
			
			<Button name="$parentBag8" inherits="ArkInventory_ChangerVaultTabTemplate">
				<Anchors>
					<Anchor point="LEFT" relativeTo="$parentBag7" relativePoint="RIGHT" x="5" y="0" />
				</Anchors>
			</Button>
			
			<Button name="$parentBag9" inherits="ArkInventory_ChangerVaultTabTemplate">
				<Anchors>
					<Anchor point="LEFT" relativeTo="$parentBag8" relativePoint="RIGHT" x="5" y="0" />
				</Anchors>
			</Button>
			
			<Button name="$parentAction" inherits="ArkInventory_ChangerVaultActionTemplate">
				<Anchors>
					<Anchor point="RIGHT" x="-10" y="0" />
				</Anchors>
			</Button>
			
			<Button name="$parentWithdrawButton" inherits="UIPanelButtonTemplate" text="WITHDRAW" hidden="true">
				
				<Size x="124" y="21" />
				
				<Anchors>
					<Anchor point="BOTTOMRIGHT" x="-5" y="5" />
				</Anchors>
				
				<Scripts>
					<OnClick>
						PlaySound( "igMainMenuOption" )
						StaticPopup_Hide( "GUILDBANK_DEPOSIT" )
						if StaticPopup_Visible( "GUILDBANK_WITHDRAW" ) then
							StaticPopup_Hide( "GUILDBANK_WITHDRAW" )
						else
							StaticPopup_Show( "GUILDBANK_WITHDRAW" )
						end
					</OnClick>
				</Scripts>
				
			</Button>
			
			<Frame name="$parentGoldAvailable" inherits="ArkInventory_SmallMoneyFrameTemplate" hidden="true">
				
				<Anchors>
					<Anchor point="RIGHT" relativeTo="$parentWithdrawButton" relativePoint="LEFT" />
				</Anchors>
				
				<Scripts>
					<OnLoad>
						ArkInventory.SmallMoneyFrame_OnLoad( self, "GUILDBANK_WITHDRAW" )
					</OnLoad>
				</Scripts>
				
			</Frame>

			<Button name="$parentDepositButton" inherits="UIPanelButtonTemplate" text="DEPOSIT" hidden="true">
					
				<Size x="124" y="21" />
				
				<Anchors>
					<Anchor point="RIGHT" relativeTo="$parentGoldAvailable" relativePoint="LEFT" x="-5" y="0" />
				</Anchors>
				
				<Scripts>
					<OnClick>
						PlaySound( "igMainMenuOption" )
						StaticPopup_Hide( "GUILDBANK_WITHDRAW" )
						if StaticPopup_Visible( "GUILDBANK_DEPOSIT") then
							StaticPopup_Hide( "GUILDBANK_DEPOSIT" )
						else
							StaticPopup_Show( "GUILDBANK_DEPOSIT" )
						end
					</OnClick>
				</Scripts>
				
			</Button>
			
			<Frame name="$parentGoldTotal" inherits="ArkInventory_SmallMoneyFrameTemplate" hidden="true">
					
				<Anchors>
					<Anchor point="RIGHT" relativeTo="$parentDepositButton" relativePoint="LEFT" />
				</Anchors>

				<Scripts>
					<OnLoad>
						ArkInventory.SmallMoneyFrame_OnLoad( self, "GUILDBANK" )
					</OnLoad>
				</Scripts>
				
			</Frame>
			
			<Frame name="$parentPurchaseInfo" hidden="true">
			
				<Size x="130" y="38" />
				
				<Anchors>
					<Anchor point="BOTTOM" relativeTo="$parentWithdrawButton" relativePoint="BOTTOM" />
					<Anchor point="RIGHT" relativeTo="$parentGoldAvailable" relativePoint="LEFT" x="-5" y="0" />
				</Anchors>
				
				<Layers>
					<Layer level="BACKGROUND">
						<FontString name="$parentSlotCost" inherits="ARKINV_GameFontNormal" text="COSTS_LABEL">
							<Size x="0" y="12" />
							<Anchors>
								<Anchor point="TOPLEFT" />
							</Anchors>
						</FontString>
					</Layer>
				</Layers>

				<Frames>

					<Button name="$parentPurchaseButton" inherits="UIPanelButtonTemplate" text="BANKSLOTPURCHASE">
						<Size x="124" y="21" />
						<Anchors>
							<Anchor point="BOTTOMLEFT" />
						</Anchors>
						<Scripts>
							<OnClick>
								PlaySound( "igMainMenuOption" )
								StaticPopup_Show( "CONFIRM_BUY_GUILDBANK_TAB" )
							</OnClick>
						</Scripts>
					</Button>

					<Frame name="$parentDetailMoneyFrame" inherits="ArkInventory_SmallMoneyFrameTemplate">
					
						<Anchors>
							<Anchor point="LEFT" relativeTo="$parentSlotCost" relativePoint="RIGHT" x="10" y="0" />
						</Anchors>
						
						<Scripts>
							<OnLoad>
								ArkInventory.MoneyFrame_SetType( self, "STATIC" )
							</OnLoad>
						</Scripts>
						
					</Frame>
					
				</Frames>
				
			</Frame>
			
		</Frames>
		
	</Frame>

	
	<Frame name="ARKINV_Frame5" inherits="ARKINV_TemplateFrameMain" id="5" /> <!-- mailbox -->

	<Frame name="ARKINV_Frame6" inherits="ARKINV_TemplateFrameMain" id="6" /> <!-- wearing -->

	<Frame name="ARKINV_Frame7" inherits="ARKINV_TemplateFrameMain" id="7" /> <!-- pets -->
	
	<Frame parent="ARKINV_Frame7Changer" name="$parentWindow" hidden="false">
		
		<Size x="1" y="1" />
		
		<Anchors>
			<Anchor point="TOPLEFT" />
			<Anchor point="BOTTOMRIGHT" />
		</Anchors>
		
		<Frames>
			
			<Button name="$parentBag1" inherits="ArkInventory_ChangerBattlepetTemplate" id="1">
				<Anchors>
					<Anchor point="BOTTOMRIGHT" relativeTo="$parent" relativePoint="BOTTOMLEFT" x="50" y="10" />
				</Anchors>
			</Button>
			
			<Button name="$parentBag2" inherits="ArkInventory_ChangerBattlepetTemplate" id="2">
				<Anchors>
					<Anchor point="BOTTOMRIGHT" relativeTo="$parentBag1" x="50" y="0" />
				</Anchors>
			</Button>
			
			<Button name="$parentBag3" inherits="ArkInventory_ChangerBattlepetTemplate" id="3">
				<Anchors>
					<Anchor point="BOTTOMRIGHT" relativeTo="$parentBag2" x="50" y="0" />
				</Anchors>
			</Button>
			
		</Frames>
		
	</Frame>

	<Frame name="ARKINV_Frame8" inherits="ARKINV_TemplateFrameMain" id="8" /> <!-- tokens -->
	
	<Frame name="ARKINV_Frame9" inherits="ARKINV_TemplateFrameMain" id="9" /> <!-- mounts -->
	
	<Frame name="ARKINV_Frame10" inherits="ARKINV_TemplateFrameMain" id="10" /> <!-- auctions -->
	
	<Frame name="ARKINV_Frame11" inherits="ARKINV_TemplateFrameMain" id="11" /> <!-- spellbook -->
	
	<Frame name="ARKINV_Frame12" inherits="ARKINV_TemplateFrameMain" id="12" /> <!-- tradeskill -->
	
	<Frame name="ARKINV_Frame13" inherits="ARKINV_TemplateFrameMain" id="13" /> <!-- void storage -->
	
<!-- END OF ADD ON FRAME -->
	
	<GameTooltip name="ARKINV_ScanTooltip" inherits="ArkScanTooltipTemplate" />
	
	<Frame name="ARKINV_CombatYieldTimer" hidden="true">
		<Scripts>
			<Onload>
				self:RegisterEvent( "PLAYER_REGEN_DISABLED" )
				self:RegisterEvent( "PLAYER_REGEN_ENABLED" )
			</Onload>
			<OnUpdate>
				self.timer = ( self.timer or 0 ) + elapsed
				if self.timer > 0.02 then
					ArkInventory.Frame_Main_DrawThreadResume( )
					self.timer = nil
				end
			</OnUpdate>
			<OnEvent>
				if ( event == "PLAYER_REGEN_DISABLED" ) then
					self:Show( )
				elseif ( event == "PLAYER_REGEN_ENABLED" ) then
					self:Hide( )
					table.wipe( ArkInventory.Global.Thread.Window )
					table.wipe( ArkInventory.Global.Thread.WindowState )
				end
			</OnEvent>
		</Scripts>
	</Frame>

</Ui>
