<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">
	<Frame name="AtlasButtonFrame" parent="Minimap" enableMouse="true" hidden="false" frameStrata="LOW">
		<Size>
			<AbsDimension x="32" y="32"/>
		</Size>
		<Anchors>
			<Anchor point="TOPLEFT" relativeTo="Minimap" relativePoint="RIGHT">
				<Offset>
					<AbsDimension x="2" y="0"/>
				</Offset>
			</Anchor>
		</Anchors>
		<Frames>
			<Button name="AtlasButton">
				<Size>
					<AbsDimension x="32" y="32"/>
				</Size>
				<Anchors>
					<Anchor point="TOPLEFT">
						<Offset>
							<AbsDimension x="0" y="0"/>
						</Offset>
					</Anchor>
				</Anchors>
				<NormalTexture file="Interface\AddOns\Atlas\Images\AtlasButton-Up"/>
				<PushedTexture file="Interface\AddOns\Atlas\Images\AtlasButton-Down"/>
				<HighlightTexture alphaMode="ADD" file="Interface\Minimap\UI-Minimap-ZoomButton-Highlight"/>
				<Scripts>
					<OnLoad>
						this:RegisterForDrag("RightButton");
						this.dragme = false;
					</OnLoad>
					<OnDragStart> 
						this.dragme = true;
					</OnDragStart> 
					<OnDragStop>
						this.dragme = false;
					</OnDragStop>
					<OnUpdate>
						if(this.dragme == true) then
							AtlasButton_BeingDragged();
						end
					</OnUpdate>
					<OnClick>
						AtlasButton_OnClick();
					</OnClick>
					<OnEnter>
						AtlasButton_OnEnter();
					</OnEnter>
					<OnLeave>
						GameTooltip:Hide();
					</OnLeave>
				</Scripts>
			</Button>
		</Frames>
		<Scripts>
			<OnLoad>
				this:RegisterEvent("VARIABLES_LOADED");
			</OnLoad>
			<OnEvent>
				AtlasButton_Init();
				AtlasButton_UpdatePosition();
			</OnEvent>
		</Scripts>
	</Frame>
</Ui>
