<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/
C:\Projects\WoW\Bin\Interface\FrameXML\UI.xsd">
	<Script file="Postal.lua"/>
	<frame>
		<Scripts>
			<OnLoad>
				Postal_MiniMapMailFrame_Show_Orig = MiniMapMailFrame.Show
			</OnLoad>
		</Scripts>
	</frame>

	<EditBox name="PostalSubjectEditBox" parent="SendMailFrame" letters="64" historyLines="0" autoFocus="false">
		<Size>
			<AbsDimension x="237" y="20"/>
		</Size>
		<Anchors>
			<Anchor point="TOPLEFT" relativeTo="SendMailNameEditBox" relativePoint="BOTTOMLEFT">
				<Offset>
					<AbsDimension x="0" y="-3"/>
				</Offset>
			</Anchor>
		</Anchors>
		<Layers>
			<Layer level="BACKGROUND">
				<FontString inherits="GameFontNormal" text="MAIL_SUBJECT_LABEL" justifyH="RIGHT">
					<Anchors>
						<Anchor point="RIGHT" relativePoint="LEFT">
							<Offset>
								<AbsDimension x="-12" y="0"/>
							</Offset>
						</Anchor>
					</Anchors>
				</FontString>
				<Texture name="$parentLeft" file="Interface\Common\Common-Input-Border">
					<Size>
						<AbsDimension x="8" y="20"/>
					</Size>
					<Anchors>
						<Anchor point="TOPLEFT">
							<Offset>
								<AbsDimension x="-8" y="0"/>
							</Offset>
						</Anchor>
					</Anchors>
					<TexCoords left="0" right="0.0625" top="0" bottom="0.625"/>
				</Texture>
				<Texture name="$parentMiddle" file="Interface\Common\Common-Input-Border">
					<Size>
						<AbsDimension x="221" y="20"/>
					</Size>
					<Anchors>
						<Anchor point="LEFT" relativeTo="$parentLeft" relativePoint="RIGHT"/>
					</Anchors>
					<TexCoords left="0.0625" right="0.9375" top="0" bottom="0.625"/>
				</Texture>
				<Texture name="$parentRight" file="Interface\Common\Common-Input-Border">
					<Size>
						<AbsDimension x="8" y="20"/>
					</Size>
					<Anchors>
						<Anchor point="LEFT" relativeTo="$parentMiddle" relativePoint="RIGHT"/>
					</Anchors>
					<TexCoords left="0.9375" right="1.0" top="0" bottom="0.625"/>
				</Texture>
			</Layer>
		</Layers>
		<Scripts>
			<OnTabPressed>
				if IsShiftKeyDown() then
					SendMailNameEditBox:SetFocus()
				else
					SendMailBodyEditBox:SetFocus()
				end
			</OnTabPressed>
			<OnEnterPressed>
				SendMailBodyEditBox:SetFocus()
			</OnEnterPressed>
			<OnEscapePressed>
				this:ClearFocus()
			</OnEscapePressed>
			<OnTextChanged>
				SendMailFrame_CanSend()
			</OnTextChanged>
		</Scripts>
		<FontString inherits="ChatFontNormal"/>
	</EditBox>

	<Button name="PostalMailButton" parent="SendMailFrame" inherits="UIPanelButtonTemplate" text="SEND_LABEL">
		<Size>
			<AbsDimension x="80" y="22"/>
		</Size>
		<Anchors>
			<Anchor point="RIGHT" relativeTo="SendMailCancelButton" relativePoint="LEFT">
				<Offset>
					<AbsDimension x="0" y="0"/>
				</Offset>
			</Anchor>
		</Anchors>
	</Button>

	<Button name="PostalAttachment" virtual="true">
		<Size>
			<AbsDimension x="37" y="37"/>
		</Size>
		<Layers>
			<Layer level="BACKGROUND">
				<Texture file="Interface\Buttons\UI-Slot-Background">
					<Size>
						<AbsDimension x="39" y="39"/>
					</Size>
					<Anchors>
						<Anchor point="TOPLEFT">
							<Offset>
								<AbsDimension x="-1" y="1"/>
							</Offset>
						</Anchor>
					</Anchors>
					<TexCoords left="0" right="0.640625" top="0" bottom="0.640625"/>
				</Texture>
			</Layer>
			<Layer level="ARTWORK">
				<FontString name="$parentCount" inherits="NumberFontNormal" justifyH="RIGHT">
					<Anchors>
						<Anchor point="BOTTOMRIGHT">
							<Offset>
								<AbsDimension x="-5" y="2"/>
							</Offset>
						</Anchor>
					</Anchors>
				</FontString>
			</Layer>
			<Layer level="OVERLAY">
				<Texture parentKey="IconBorder" file="Interface\Common\WhiteIconFrame" hidden="true">
					<Size>
						<AbsDimension x="37" y="37"/>
					</Size>
					<Anchors>
						<Anchor point="CENTER"/>
					</Anchors>
				</Texture>
			</Layer>
		</Layers>
		<Scripts>
			<OnLoad>
				this:RegisterForClicks('LeftButtonUp', 'RightButtonUp')
				this:RegisterForDrag('LeftButton')
			</OnLoad>
			<OnReceiveDrag>
				Postal:AttachmentButton_OnClick()
			</OnReceiveDrag>
			<OnDragStart>
				Postal:AttachmentButton_OnClick()
			</OnDragStart>
			<OnClick>
				Postal:AttachmentButton_OnClick()
			</OnClick>
			<OnEnter>
				GameTooltip:SetOwner(this, 'ANCHOR_RIGHT')
				if this.bag and this.slot then
					GameTooltip:SetBagItem(this.bag, this.slot)
				else
					GameTooltip:SetText(ATTACHMENT_TEXT, 1.0, 1.0, 1.0)
				end
			</OnEnter>
			<OnLeave>
				GameTooltip:Hide()
			</OnLeave>
<!--
			<OnEnter>
				SendMailAttachment_OnEnter(self, motion);
			</OnEnter>
			<OnUpdate>
				if ( GameTooltip:IsOwned(self) ) then
					SendMailAttachment_OnEnter(self);
				end
			</OnUpdate>-->
		</Scripts>
		<HighlightTexture alphaMode="ADD" file="Interface\Buttons\ButtonHilight-Square"/>
	</Button>

	<Button name="PostalAttachment1" parent="SendMailFrame" inherits="PostalAttachment"/>
	<Button name="PostalAttachment2" parent="SendMailFrame" inherits="PostalAttachment"/>
	<Button name="PostalAttachment3" parent="SendMailFrame" inherits="PostalAttachment"/>
	<Button name="PostalAttachment4" parent="SendMailFrame" inherits="PostalAttachment"/>
	<Button name="PostalAttachment5" parent="SendMailFrame" inherits="PostalAttachment"/>
	<Button name="PostalAttachment6" parent="SendMailFrame" inherits="PostalAttachment"/>
	<Button name="PostalAttachment7" parent="SendMailFrame" inherits="PostalAttachment"/>
	<Button name="PostalAttachment8" parent="SendMailFrame" inherits="PostalAttachment"/>
	<Button name="PostalAttachment9" parent="SendMailFrame" inherits="PostalAttachment"/>
	<Button name="PostalAttachment10" parent="SendMailFrame" inherits="PostalAttachment"/>
	<Button name="PostalAttachment11" parent="SendMailFrame" inherits="PostalAttachment"/>
	<Button name="PostalAttachment12" parent="SendMailFrame" inherits="PostalAttachment"/>
	<Button name="PostalAttachment13" parent="SendMailFrame" inherits="PostalAttachment"/>
	<Button name="PostalAttachment14" parent="SendMailFrame" inherits="PostalAttachment"/>
	<Button name="PostalAttachment15" parent="SendMailFrame" inherits="PostalAttachment"/>
	<Button name="PostalAttachment16" parent="SendMailFrame" inherits="PostalAttachment"/>
	<Button name="PostalAttachment17" parent="SendMailFrame" inherits="PostalAttachment"/>
	<Button name="PostalAttachment18" parent="SendMailFrame" inherits="PostalAttachment"/>
	<Button name="PostalAttachment19" parent="SendMailFrame" inherits="PostalAttachment"/>
	<Button name="PostalAttachment20" parent="SendMailFrame" inherits="PostalAttachment"/>
	<Button name="PostalAttachment21" parent="SendMailFrame" inherits="PostalAttachment"/>

	<Frame name="PostalFrame" parent="MailFrame" hidden="true">
		<Size>
			<AbsDimension x="384" y="512"/>
		</Size>
	</Frame>

	<Frame name="PostalInboxFrame" parent="UIParent">
	</Frame>
	<CheckButton name="PostalBoxItemCBTemplate" hidden="true" virtual="true" inherits="OptionsCheckButtonTemplate">
		<HitRectInsets>
			<AbsInset left="0" right="0" top="0" bottom="0"/>
		</HitRectInsets>
		<Size>
			<AbsDimension x="24" y="24"/>
		</Size>
		<Anchors>
			<Anchor point="RIGHT" relativePoint="LEFT">
				<Offset>
					<AbsDimension x="1" y="0"/>
				</Offset>
			</Anchor>
		</Anchors>
		<Scripts>
			<OnClick>
				Postal_Inbox_SetSelected()
			</OnClick>
		</Scripts>
	</CheckButton>
	<CheckButton name="PostalBoxItem1CB" id="1" hidden="true" parent="MailItem1" inherits="PostalBoxItemCBTemplate"/>
	<CheckButton name="PostalBoxItem2CB" id="2" hidden="true" parent="MailItem2" inherits="PostalBoxItemCBTemplate"/>
	<CheckButton name="PostalBoxItem3CB" id="3" hidden="true" parent="MailItem3" inherits="PostalBoxItemCBTemplate"/>
	<CheckButton name="PostalBoxItem4CB" id="4" hidden="true" parent="MailItem4" inherits="PostalBoxItemCBTemplate"/>
	<CheckButton name="PostalBoxItem5CB" id="5" hidden="true" parent="MailItem5" inherits="PostalBoxItemCBTemplate"/>
	<CheckButton name="PostalBoxItem6CB" id="6" hidden="true" parent="MailItem6" inherits="PostalBoxItemCBTemplate"/>
	<CheckButton name="PostalBoxItem7CB" id="7" hidden="true" parent="MailItem7" inherits="PostalBoxItemCBTemplate"/>
	<Button name="PostalInboxOpenSelected" parent="InboxFrame" inherits="UIPanelButtonTemplate" text="Open Selected">
		<Size>
			<AbsDimension x="120" y="25"/>
		</Size>
		<Anchors>
			<Anchor relativePoint="TOP" point="RIGHT">
				<Offset>
					<AbsDimension x="5" y="-53"/>
				</Offset>
			</Anchor>
		</Anchors>
		<Scripts>
			<OnClick>
				Postal_Inbox_OpenSelected()
			</OnClick>
		</Scripts>
	</Button>
	<Button name="PostalInboxOpenAllButton" parent="InboxFrame" inherits="UIPanelButtonTemplate" text="Open All">
		<Size>
			<AbsDimension x="120" y="25"/>
		</Size>
		<Anchors>
			<Anchor relativePoint="TOP" point="LEFT">
				<Offset>
					<AbsDimension x="10" y="-53"/>
				</Offset>
			</Anchor>
		</Anchors>
		<Scripts>
			<OnClick>
				Postal_Inbox_OpenSelected(true)
			</OnClick>
		</Scripts>
	</Button>
	
	<Frame name="PostalGlobalFrame" parent="UIParent" hidden="true">
		<Scripts>
			<OnUpdate>
				Postal:ProcessQueue(arg1)
			</OnUpdate>
		</Scripts>
	</Frame>
	<GameTooltip name="PostalTooltip" inherits="GameTooltipTemplate"></GameTooltip>
</Ui>
