<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">
<!-- Template: Queue item frame -->
<Button name="CauldronQueueItemFrameTemplate" virtual="true" enableMouse="true">
<Size x="300" y="39" />
<Layers>
<Layer level="OVERLAY">
<!-- item name -->
<FontString name="$parentItemName" inherits="GameFontNormal"
text="(name)" justifyH="LEFT" justifyV="CENTER">
<Size x="250" y="12"/>
<Anchors>
<Anchor point="TOPLEFT">
<Offset x="40" y="-4"/>
</Anchor>
</Anchors>
<Color r="0.8" g="0.8" b="0.8" />
</FontString>
<!-- quantity info -->
<FontString name="$parentInfo" inherits="GameFontNormal"
text="(info)" justifyH="LEFT" justifyV="CENTER">
<Size x="250" y="12"/>
<Anchors>
<Anchor point="TOPLEFT">
<Offset x="40" y="-18"/>
</Anchor>
</Anchors>
<!-- Color r="1.0" g="1.0" b="1.0" / -->
</FontString>
</Layer>
<Layer level="HIGHLIGHT" setAllPoints="true">
<Texture file="Interface\QuestFrame\UI-QuestLogTitleHighlight" alphaMode="ADD">
<Color r="0.8" g="0.8" b="0.8" a="0.5" />
</Texture>
</Layer>
</Layers>
<Frames>
<!-- icon -->
<Button name="$parentIcon">
<Size x="37" y="37"/>
<Anchors>
<Anchor point="TOPLEFT">
<Offset x="2" y="-3"/>
</Anchor>
</Anchors>
<Layers>
<Layer level="ARTWORK">
<FontString name="$parentCount" inherits="NumberFontNormal" justifyH="RIGHT" hidden="false">
<Anchors>
<Anchor point="BOTTOMRIGHT">
<Offset x="-2" y="2"/>
</Anchor>
</Anchors>
</FontString>
</Layer>
</Layers>
<Scripts>
<OnLoad>
-- self.hasItem = 1;
</OnLoad>
<OnClick>
HandleModifiedItemClick(self.link);
</OnClick>
<OnEnter>
GameTooltip:SetOwner(self, "ANCHOR_RIGHT");
GameTooltip:SetHyperlink(self.link);
CursorUpdate(self);
</OnEnter>
<OnLeave>
GameTooltip:Hide();
ResetCursor();
</OnLeave>
<OnUpdate>
if GameTooltip:IsOwned(self) then
GameTooltip:SetOwner(self, "ANCHOR_RIGHT");
GameTooltip:SetHyperlink(self.link);
CursorUpdate(self);
end
CursorOnUpdate(self);
</OnUpdate>
</Scripts>
</Button>
<Button name="$parentRemoveItem" inherits="UIPanelCloseButton">
<Anchors>
<Anchor point="TOPRIGHT">
<Offset x="0" y="0"/>
</Anchor>
</Anchors>
<Scripts>
<OnEnter>
self:GetParent().inHoverButtons = true;
GameTooltip:SetOwner(self, "ANCHOR_RIGHT");
GameTooltip:ClearLines();
GameTooltip:AddLine(Cauldron:LocaleString("Remove this item from the queue"));
GameTooltip:Show();
CursorUpdate(self);
</OnEnter>
<OnLeave>
self:GetParent().inHoverButtons = false;
GameTooltip:Hide();
ResetCursor();
</OnLeave>
<OnClick>
Cauldron:RemoveQueueItem(self:GetParent().itemName);
Cauldron:UpdateQueue();
Cauldron:UpdateButtons();
</OnClick>
</Scripts>
</Button>
<!--
<Button name="$parentAddToShoppingList" inherits="UIPanelCloseButton" hidden="true">
<Anchors>
<Anchor point="TOPRIGHT">
<Offset x="0" y="0"/>
</Anchor>
</Anchors>
<Scripts>
<OnEnter>
self:GetParent().inHoverButtons = true;
GameTooltip:SetOwner(self, "ANCHOR_RIGHT");
GameTooltip:ClearLines();
GameTooltip:AddLine(Cauldron:LocaleString("Add this item to the shopping list"));
GameTooltip:AddLine(Cauldron:LocaleString("Shift-click will replace the count in the shopping list with this amount"));
GameTooltip:Show();
CursorUpdate(self);
</OnEnter>
<OnLeave>
self:GetParent().inHoverButtons = false;
GameTooltip:Hide();
ResetCursor();
</OnLeave>
<OnClick>
Cauldron:AddItemToShoppingList(self:GetParent().itemName, self:GetParent().needAmount, IsShiftKeyDown());
Cauldron:UpdateShoppingList();
</OnClick>
</Scripts>
<NormalTexture file="Interface\Buttons\UI-PlusButton-Up" />
<PushedTexture file="Interface\Buttons\UI-PlusButton-Down" />
<DisabledTexture file="Interface\Buttons\UI-PlusButton-Disabled" />
<HighlightTexture file="Interface\Buttons\UI-PlusButton-Hilight" alphaMode="ADD" />
</Button>
<Button name="$parentIncrementCount" hidden="true" inherits="ClassTrainerSkillButtonTemplate">
<Size x="23" y="22" />
<Anchors>
<Anchor point="TOPRIGHT">
<Offset x="-48" y="-6"/>
</Anchor>
</Anchors>
<Scripts>
<OnLoad>
self:RegisterForClicks("AnyUp");
</OnLoad>
<OnEnter>
self:GetParent().inHoverButtons = true;
GameTooltip:SetOwner(self, "ANCHOR_RIGHT");
GameTooltip:ClearLines();
GameTooltip:AddLine(Cauldron:LocaleString("Increase the amount of this item"));
GameTooltip:Show();
CursorUpdate(self);
</OnEnter>
<OnLeave>
self:GetParent().inHoverButtons = false;
GameTooltip:Hide();
ResetCursor();
</OnLeave>
<OnClick>
Cauldron:IncreaseItemCount(self:GetParent().itemName);
Cauldron:UpdateQueue();
Cauldron:UpdateButtons();
</OnClick>
</Scripts>
<NormalTexture file="Interface\Buttons\UI-PlusButton-Up" />
<PushedTexture file="Interface\Buttons\UI-PlusButton-Down" />
<DisabledTexture file="Interface\Buttons\UI-PlusButton-Disabled" />
<HighlightTexture file="Interface\Buttons\UI-PlusButton-Hilight" alphaMode="ADD" />
</Button>
<Button name="$parentDecrementCount" hidden="true" inherits="ClassTrainerSkillButtonTemplate">
<Size x="23" y="22" />
<Anchors>
<Anchor point="TOPRIGHT">
<Offset x="-16" y="-2"/>
</Anchor>
</Anchors>
<Scripts>
<OnLoad>
self:RegisterForClicks("AnyUp");
</OnLoad>
<OnEnter>
self:GetParent().inHoverButtons = true;
GameTooltip:SetOwner(self, "ANCHOR_RIGHT");
GameTooltip:ClearLines();
GameTooltip:AddLine(Cauldron:LocaleString("Decrease the amount of this item"));
GameTooltip:Show();
CursorUpdate(self);
</OnEnter>
<OnLeave>
self:GetParent().inHoverButtons = false;
GameTooltip:Hide();
ResetCursor();
</OnLeave>
<OnClick>
Cauldron:DecreaseItemCount(self:GetParent().itemName);
Cauldron:UpdateQueue();
Cauldron:UpdateButtons();
</OnClick>
</Scripts>
<NormalTexture file="Interface\Buttons\UI-MinusButton-Up" />
<PushedTexture file="Interface\Buttons\UI-MinusButton-Down" />
<DisabledTexture file="Interface\Buttons\UI-MinusButton-Disabled" />
<HighlightTexture file="Interface\Buttons\UI-ScrollBar-ScrollUpButton-Highlight" alphaMode="ADD" />
</Button>
<Button name="$parentIncreasePriority" hidden="true">
<Size x="23" y="22" />
<Anchors>
<Anchor point="TOPRIGHT">
<Offset x="-16" y="-20"/>
</Anchor>
</Anchors>
<Scripts>
<OnLoad>
self:RegisterForClicks("AnyUp");
</OnLoad>
<OnEnter>
self:GetParent().inHoverButtons = true;
GameTooltip:SetOwner(self, "ANCHOR_RIGHT");
GameTooltip:ClearLines();
GameTooltip:AddLine(Cauldron:LocaleString("Increase the priority of this item"));
GameTooltip:AddLine(Cauldron:LocaleString("Shift-click to move to the top of the queue"));
GameTooltip:Show();
CursorUpdate(self);
</OnEnter>
<OnLeave>
self:GetParent().inHoverButtons = false;
GameTooltip:Hide();
ResetCursor();
</OnLeave>
<OnClick>
Cauldron:IncreaseItemPriority(self:GetParent().itemName, IsShiftKeyDown());
CauldronQueue:CalculateAllRequiredItems(Cauldron:GetQueue());
Cauldron:UpdateQueue();
</OnClick>
</Scripts>
<NormalTexture file="Interface\Buttons\UI-ScrollBar-ScrollUpButton-Up" />
<PushedTexture file="Interface\Buttons\UI-ScrollBar-ScrollUpButton-Down" />
<DisabledTexture file="Interface\Buttons\UI-ScrollBar-ScrollUpButton-Disabled" />
<HighlightTexture file="Interface\Buttons\UI-ScrollBar-ScrollUpButton-Highlight" alphaMode="ADD" />
</Button>
<Button name="$parentDecreasePriority" hidden="true">
<Size x="23" y="22" />
<Anchors>
<Anchor point="TOPRIGHT">
<Offset x="0" y="-20"/>
</Anchor>
</Anchors>
<Scripts>
<OnLoad>
self:RegisterForClicks("AnyUp");
</OnLoad>
<OnEnter>
self:GetParent().inHoverButtons = true;
GameTooltip:SetOwner(self, "ANCHOR_RIGHT");
GameTooltip:ClearLines();
GameTooltip:AddLine(Cauldron:LocaleString("Decrease the priority of this item"));
GameTooltip:AddLine(Cauldron:LocaleString("Shift-click to move to the bottom of the queue"));
GameTooltip:Show();
CursorUpdate(self);
</OnEnter>
<OnLeave>
self:GetParent().inHoverButtons = false;
GameTooltip:Hide();
ResetCursor();
</OnLeave>
<OnClick>
Cauldron:DecreaseItemPriority(self:GetParent().itemName, IsShiftKeyDown());
CauldronQueue:CalculateAllRequiredItems(Cauldron:GetQueue());
Cauldron:UpdateQueue();
</OnClick>
</Scripts>
<NormalTexture file="Interface\Buttons\UI-ScrollBar-ScrollDownButton-Up" />
<PushedTexture file="Interface\Buttons\UI-ScrollBar-ScrollDownButton-Down" />
<DisabledTexture file="Interface\Buttons\UI-ScrollBar-ScrollDownButton-Disabled" />
<HighlightTexture file="Interface\Buttons\UI-ScrollBar-ScrollDownButton-Highlight" alphaMode="ADD" />
</Button>
-->
</Frames>
<Scripts>
<OnEnter>
local itemId = self:GetID();
if itemId < 100 then
GameTooltip:SetOwner(self, "ANCHOR_RIGHT");
GameTooltip:ClearLines();
GameTooltip:AddLine(self.itemName);
GameTooltip:AddLine(Cauldron:LocaleString("Click to increase crafted amount"));
GameTooltip:AddLine(Cauldron:LocaleString("Shift-click to decrease crafted amount"));
GameTooltip:AddLine(Cauldron:LocaleString("Control-click to move to top of queue"));
GameTooltip:Show();
CursorUpdate(self);
elseif itemId >= 200 then
GameTooltip:SetOwner(self, "ANCHOR_RIGHT");
GameTooltip:ClearLines();
GameTooltip:AddLine(self.itemName);
GameTooltip:AddLine(Cauldron:LocaleString("Double-click to add needed amount to shopping list"));
GameTooltip:Show();
CursorUpdate(self);
end
</OnEnter>
<OnLeave>
GameTooltip:Hide();
ResetCursor();
</OnLeave>
<OnClick>
local itemId = self:GetID();
local button = GetMouseButtonClicked();
if (button == "LeftButton") and (itemId < 100) then
if IsControlKeyDown() then
Cauldron:IncreaseItemPriority(self.itemName, true);
elseif IsShiftKeyDown() then
Cauldron:DecreaseItemCount(self.itemName);
else
Cauldron:IncreaseItemCount(self.itemName);
end
Cauldron:UpdateQueue();
Cauldron:UpdateButtons();
end
</OnClick>
<OnDoubleClick>
local itemId = self:GetID();
local button = GetMouseButtonClicked();
if (button == "LeftButton") and (itemId >= 200) then
if self.needAmount < 1 then
Cauldron:AddItemToShoppingList(self.itemName, self.needAmount);
end
end
</OnDoubleClick>
</Scripts>
</Button>
<!-- Queue frame -->
<Frame name="CauldronQueueWindowFrame" inherits="ButtonFrameTemplate"
parent="UIParent" enableMouse="true"
toplevel="true" hidden="true" >
<!-- Window border and background -->
<Layers>
</Layers>
<Frames>
<!-- Queue frame -->
<Frame name="CauldronQueueFrame">
<Size x="300" y="332" />
<Anchors>
<Anchor point="TOPLEFT" relativeTo="CauldronQueueWindowFrame" relativePoint="TOPLEFT">
<Offset x="10" y="-64" />
</Anchor>
</Anchors>
<Frames>
<Frame name="CauldronQueueFrameQueueEmpty">
<Size x="302" y="360" />
<Anchors>
<Anchor point="TOPLEFT">
<Offset x="0" y="0" />
</Anchor>
</Anchors>
<Layers>
<Layer level="OVERLAY">
<FontString name="$parentText" inherits="QuestTitleFont"
text=""
justifyH="CENTER" justifyV="CENTER">
<Size x="302" y="360" />
<Anchors>
<Anchor point="TOPLEFT">
<Offset x="0" y="0" />
</Anchor>
</Anchors>
<Color r="0.2" g="0.2" b="0.2" />
</FontString>
</Layer>
</Layers>
</Frame>
<ScrollFrame name="CauldronQueueFrameScrollFrame" inherits="UIPanelScrollFrameTemplate" hidden="true">
<Size x="294" y="332" />
<Anchors>
<Anchor point="TOPLEFT">
<Offset x="0" y="0"/>
</Anchor>
</Anchors>
<Layers>
<Layer level="BACKGROUND">
<Texture name="CauldronQueueFrameScrollBackgroundTopLeft" file="Interface\PaperDollInfoFrame\UI-Character-ScrollBar">
<Size>
<AbsDimension x="31" y="256"/>
</Size>
<Anchors>
<Anchor point="TOPLEFT" relativePoint="TOPRIGHT">
<Offset>
<AbsDimension x="-2" y="5"/>
</Offset>
</Anchor>
</Anchors>
<TexCoords left="0" right="0.484375" top="0" bottom="1.0"/>
</Texture>
<Texture name="CauldronQueueFrameScrollBackgroundBottomRight" file="Interface\PaperDollInfoFrame\UI-Character-ScrollBar">
<Size>
<AbsDimension x="31" y="106"/>
</Size>
<Anchors>
<Anchor point="BOTTOMLEFT" relativePoint="BOTTOMRIGHT">
<Offset>
<AbsDimension x="-2" y="-2"/>
</Offset>
</Anchor>
</Anchors>
<TexCoords left="0.515625" right="1.0" top="0" bottom="0.4140625"/>
</Texture>
</Layer>
</Layers>
<ScrollChild>
<Frame name="CauldronQueueFrameScrollFrameQueueSections">
<Size x="300" y="332" />
<Anchors>
<Anchor point="TOPLEFT">
<Offset x="0" y="0"/>
</Anchor>
</Anchors>
<Frames>
<Frame name="CauldronQueueFrameScrollFrameQueueSectionsMainItemsHeader">
<Size x="300" y="16" />
<Anchors>
<Anchor point="TOPLEFT">
<Offset x="0" y="0" />
</Anchor>
</Anchors>
<Layers>
<Layer level="OVERLAY">
<Texture urgency="5" file="Interface\Buttons\UI-Listbox-Highlight2">
<Color r="0.6" g="0.75" b="1.0" a="0.5" />
</Texture>
<FontString name="$parentText" inherits="QuestFontHighlight" text=""
justifyV="CENTER" justifyH="CENTER">
<Size x="300" y="16" />
<Anchors>
<Anchor point="TOPLEFT">
<Offset x="0" y="0" />
</Anchor>
</Anchors>
<Color r="0.8" g="0.8" b="0.8" />
</FontString>
</Layer>
</Layers>
</Frame>
<Frame name="CauldronQueueFrameScrollFrameQueueSectionsMainItems">
<Size x="300" y="1" />
<Anchors>
<Anchor point="TOPLEFT" relativeTo="$parentMainItemsHeader" relativePoint="BOTTOMLEFT">
<Offset x="0" y="-2" />
</Anchor>
</Anchors>
</Frame>
<Frame name="CauldronQueueFrameScrollFrameQueueSectionsSecondaryItemsHeader">
<Size x="300" y="16" />
<Anchors>
<Anchor point="TOPLEFT" relativeTo="$parentMainItems" relativePoint="BOTTOMLEFT">
<Offset x="0" y="-2" />
</Anchor>
</Anchors>
<Layers>
<Layer level="OVERLAY">
<Texture urgency="5" file="Interface\Buttons\UI-Listbox-Highlight2">
<Color r="0.6" g="0.75" b="1.0" a="0.5" />
</Texture>
<FontString name="$parentText" inherits="QuestFontHighlight" text=""
justifyV="CENTER" justifyH="CENTER">
<Size x="300" y="16" />
<Anchors>
<Anchor point="TOPLEFT">
<Offset x="0" y="0" />
</Anchor>
</Anchors>
<Color r="0.8" g="0.8" b="0.8" />
</FontString>
</Layer>
</Layers>
</Frame>
<Frame name="CauldronQueueFrameScrollFrameQueueSectionsSecondaryItems">
<Size x="300" y="1" />
<Anchors>
<Anchor point="TOPLEFT" relativeTo="$parentSecondaryItemsHeader" relativePoint="BOTTOMLEFT">
<Offset x="0" y="-2" />
</Anchor>
</Anchors>
</Frame>
<Frame name="CauldronQueueFrameScrollFrameQueueSectionsReagentsHeader">
<Size x="300" y="16" />
<Anchors>
<Anchor point="TOPLEFT" relativeTo="$parentSecondaryItems" relativePoint="BOTTOMLEFT">
<Offset x="0" y="-2" />
</Anchor>
</Anchors>
<Layers>
<Layer level="OVERLAY">
<Texture urgency="5" file="Interface\Buttons\UI-Listbox-Highlight2">
<Color r="0.6" g="0.75" b="1.0" a="0.5" />
</Texture>
<FontString name="$parentText" inherits="QuestFontHighlight" text=""
justifyV="CENTER" justifyH="CENTER">
<Size x="300" y="16" />
<Anchors>
<Anchor point="TOPLEFT">
<Offset x="0" y="0" />
</Anchor>
</Anchors>
<Color r="0.8" g="0.8" b="0.8" />
</FontString>
</Layer>
</Layers>
</Frame>
<Frame name="CauldronQueueFrameScrollFrameQueueSectionsReagents">
<Size x="300" y="1" />
<Anchors>
<Anchor point="TOPLEFT" relativeTo="$parentReagentsHeader" relativePoint="BOTTOMLEFT">
<Offset x="0" y="-2" />
</Anchor>
</Anchors>
</Frame>
</Frames>
</Frame>
</ScrollChild>
</ScrollFrame>
</Frames>
</Frame>
<!-- Buttons frame -->
<Frame name="CauldronQueueButtonsFrame">
<Size x="330" y="25" />
<Anchors>
<Anchor point="BOTTOMLEFT" relativeTo="CauldronQueueWindowFrame" relativePoint="BOTTOMLEFT">
<Offset x="2" y="0" />
</Anchor>
</Anchors>
<Frames>
<!-- Process button (disabled) -->
<Button name="CauldronProcessButton" inherits="CauldronButtonTemplate" text="Process">
<Size x="150" y="20" />
<Anchors>
<Anchor point="TOPLEFT">
<Offset x="0" y="0" />
</Anchor>
</Anchors>
<Scripts>
<OnLoad>
getglobal(self:GetName()):Disable();
</OnLoad>
<OnClick>
Cauldron:ProcessQueue();
</OnClick>
</Scripts>
</Button>
<!-- Clear Queue button (disabled) -->
<Button name="CauldronClearQueueButton" inherits="CauldronButtonTemplate" text="Clear Queue">
<Size x="90" y="20" />
<Anchors>
<Anchor point="TOPRIGHT">
<Offset x="0" y="0" />
</Anchor>
</Anchors>
<Scripts>
<OnLoad>
getglobal(self:GetName()):Disable();
</OnLoad>
<OnClick>
CauldronQueue:ClearQueue(Cauldron:GetQueue());
Cauldron:UpdateQueue();
Cauldron:UpdateButtons();
</OnClick>
</Scripts>
</Button>
</Frames>
</Frame>
</Frames>
<Scripts>
<OnLoad>
return;
</OnLoad>
<OnShow>
PlaySound("igCharacterInfoOpen");
</OnShow>
<OnHide>
--HideUIPanel(CauldronFrame);
PlaySound("igCharacterInfoClose");
Cauldron:UpdateButtons();
</OnHide>
<OnMouseWheel>
return;
</OnMouseWheel>
</Scripts>
</Frame>
</Ui>