<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="Toolbar.lua"/>

	<Button name="CPToolbarMicroButton" mixin="CPMicroButton" motionScriptsWhileDisabled="true" virtual="true">
		<Size x="32" y="40"/>
		<NormalTexture parentKey="NormalTexture">
			<Anchors>
				<Anchor point="CENTER"/>
			</Anchors>
		</NormalTexture>
		<PushedTexture parentKey="PushedTexture">
			<Anchors>
				<Anchor point="CENTER"/>
			</Anchors>
		</PushedTexture>
		<HighlightTexture parentKey="HighlightTexture">
			<Anchors>
				<Anchor point="CENTER"/>
			</Anchors>
		</HighlightTexture>
		<Layers>
			<Layer level="BACKGROUND">
				<Texture parentKey="Background">
					<Size x="32" y="41"/>
					<Anchors>
						<Anchor point="CENTER"/>
					</Anchors>
				</Texture>
				<Texture parentKey="PushedBackground" hidden="true">
					<Size x="32" y="41"/>
					<Anchors>
						<Anchor point="CENTER"/>
					</Anchors>
				</Texture>
			</Layer>
			<Layer level="OVERLAY">
				<Texture parentKey="FlashBorder" setAllPoints="true" alphaMode="BLEND" hidden="true"/>
			</Layer>
		</Layers>
		<Scripts>
			<OnLoad method="OnLoad"/>
			<OnEnter method="OnEnter" inherit="append"/>
			<OnLeave method="OnLeave" inherit="append"/>
			<OnShow method="OnShow"/>
			<OnHide method="OnHide"/>
			<OnMouseDown method="OnMouseDown"/>
			<OnMouseUp method="OnMouseUp"/>
			<OnEnable>
				self:SetAlpha(1);
			</OnEnable>
			<OnDisable>
				self:SetAlpha(0.5);
			</OnDisable>
			<OnLeave inherit="append">
				GameTooltip:Hide();
			</OnLeave>
		</Scripts>
	</Button>

	<Frame name="CPToolbarDivider" virtual="true">
		<Size x="16" y="40"/>
		<Layers>
			<Layer level="BACKGROUND">
				<Texture parentKey="Background" atlas="BattleBar-ButtonBG-Divider">
					<Size x="12" y="40"/>
					<Anchors>
						<Anchor point="CENTER"/>
					</Anchors>
				</Texture>
			</Layer>
		</Layers>
	</Frame>

	<Frame name="CPToolbar" virtual="true" clampedToScreen="true" movable="true" mixin="CPToolbar" enableMouseClicks="false">
		<Size x="900" y="64"/>
		<Scripts>
			<OnDragStart method="StartMoving"/>
			<OnDragStop method="StopMovingOrSizing"/>
            <OnLoad method="OnLoad"/>
			<OnEnter method="OnEnter"/>
			<OnEvent method="OnEvent"/>
			<OnSizeChanged method="OnSizeChanged"/>
		</Scripts>
		<Frames>
			<Frame parentKey="PopoutContainer" clipChildren="true">
				<Size x="300" y="300"/>
				<Anchors>
					<Anchor point="BOTTOM" y="17"/>
				</Anchors>
				<Frames>
					<Frame parentKey="PopoutFrame" inherits="GridLayoutFrame, CPToolbarNineSliceFrame" alpha="0">
						<Size x="300" y="40"/>
						<KeyValues>
							<KeyValue key="childXPadding" value="1" type="number"/>
							<KeyValue key="childYPadding" value="2" type="number"/>
							<KeyValue key="stride" value="1" type="number"/>
							<KeyValue key="isHorizontal" value="true" type="boolean"/>
							<KeyValue key="layoutFramesGoingRight" value="true" type="boolean"/>
							<KeyValue key="alwaysUpdateLayout" value="true" type="boolean"/>
						</KeyValues>
						<Anchors>
							<Anchor point="BOTTOM" y="0"/>
						</Anchors>
						<Layers>
							<Layer level="BORDER">
								<Texture parentKey="Gradient" inherits="CPDividerGradient">
									<Anchors>
										<Anchor point="TOPLEFT" x="0" y="0"/>
										<Anchor point="BOTTOMRIGHT" x="0" y="0"/>
									</Anchors>
								</Texture>
							</Layer>
						</Layers>
						<Frames>
							<Button parentKey="ExitVehicle" inherits="CPToolbarMicroButton">
								<KeyValues>
									<KeyValue key="layoutIndex" value="-5" type="number"/>
									<KeyValue key="normalAtlas" value="poi-traveldirections-arrow2" type="string"/>
									<KeyValue key="highlightAtlas" value="poi-traveldirections-arrow2" type="string"/>
								</KeyValues>
							</Button>
							<Button parentKey="Eye" inherits="CPToolbarMicroButton">
								<NormalTexture parentKey="NormalTexture" alphaMode="BLEND" alpha="1" rotation="90">
									<Size x="32" y="16"/>
									<Anchors>
										<Anchor point="CENTER"/>
									</Anchors>
								</NormalTexture>
								<PushedTexture parentKey="PushedTexture" alphaMode="BLEND" alpha="1" rotation="90">
									<Size x="32" y="16"/>
									<Anchors>
										<Anchor point="CENTER" x="1" y="-1"/>
									</Anchors>
								</PushedTexture>
								<KeyValues>
									<KeyValue key="layoutIndex" value="-4" type="number"/>
								</KeyValues>
							</Button>
							<Button parentKey="Config" inherits="CPToolbarMicroButton">
								<KeyValues>
									<KeyValue key="layoutIndex" value="-3" type="number"/>
									<KeyValue key="normalAtlas" value="Barbershop-32x32" type="string"/>
									<KeyValue key="highlightAtlas" value="Barbershop-32x32" type="string"/>
								</KeyValues>
							</Button>
							<Frame parentKey="Divider1" inherits="CPToolbarDivider">
								<KeyValues>
									<KeyValue key="layoutIndex" value="-1" type="number"/>
								</KeyValues>
							</Frame>
						</Frames>
					</Frame>
				</Frames>
				<Animations>
					<AnimationGroup parentKey="SlideIn" setToFinalAlpha="true">
						<Alpha childKey="PopoutFrame" fromAlpha="0" toAlpha="1" duration="0.25"/>
						<Translation parentKey="Translate" childKey="PopoutFrame" offsetX="0" offsetY="40" duration="0.25"/>
						<Scripts>
							<OnPlay>
								self:GetParent().SlideOut:Finish();
								self:GetParent().PopoutFrame:SetActive(false);
							</OnPlay>
							<OnFinished>
								self:GetParent().PopoutFrame:SetActive(true);
							</OnFinished>
						</Scripts>
					</AnimationGroup>
					<AnimationGroup parentKey="SlideOut" setToFinalAlpha="true">
						<Alpha childKey="PopoutFrame" fromAlpha="1" toAlpha="0" duration="0.25"/>
						<Translation parentKey="Translate" childKey="PopoutFrame" offsetX="0" offsetY="-40" duration="0.25"/>
						<Scripts>
							<OnPlay>
								self:GetParent().SlideIn:Finish();
								self:GetParent().PopoutFrame:SetActive(true);
							</OnPlay>
							<OnFinished>
								self:GetParent().PopoutFrame:SetActive(false);
							</OnFinished>
						</Scripts>
					</AnimationGroup>
				</Animations>
			</Frame>
		</Frames>
		<Layers>
			<Layer level="BACKGROUND">
				<Texture parentKey="BG" inherits="CPDividerGradient">
					<Anchors>
						<Anchor point="TOPLEFT" x="16" y="60"/>
						<Anchor point="BOTTOMRIGHT" x="-16" y="16"/>
					</Anchors>
				</Texture>
			</Layer>
			<Layer level="BORDER">
				<Texture parentKey="DividerLine" inherits="CPDividerLine">
					<Anchors>
						<Anchor point="BOTTOMLEFT" x="0" y="16"/>
						<Anchor point="BOTTOMRIGHT" x="0" y="16"/>
					</Anchors>
				</Texture>
			</Layer>
		</Layers>
	</Frame>

</Ui>