режим предателя + UI референсы и DragonUI

This commit is contained in:
2026-04-09 02:05:29 +04:00
parent 1109d19bb5
commit e8f1ae4ab9
397 changed files with 202750 additions and 37 deletions
@@ -0,0 +1,229 @@
UIPanelWindows["ItemSocketingFrame"] = { area = "left", pushable = 0 };
GEM_TYPE_INFO = {};
GEM_TYPE_INFO["Yellow"] = {w=43, h=43, left=0, right=0.16796875, top=0.640625, bottom=0.80859375, r=0.97, g=0.82, b=0.29, CBLeft=0.5546875, CBRight=0.7578125, CBTop=0, CBBottom=0.20703125, OBLeft=0.7578125, OBRight=0.9921875, OBTop=0, OBBottom=0.22265625};
GEM_TYPE_INFO["Red"] = {w=43, h=43, left=0.1796875, right=0.34375, top=0.640625, bottom=0.80859375, r=1, g=0.47, b=0.47, CBLeft=0.5546875, CBRight=0.7578125, CBTop=0.4765625, CBBottom=0.68359375, OBLeft=0.7578125, OBRight=0.9921875, OBTop=0.4765625, OBBottom=0.69921875};
GEM_TYPE_INFO["Blue"] = {w=43, h=43, left=0.3515625, right=0.51953125, top=0.640625, bottom=0.80859375, r=0.47, g=0.67, b=1, CBLeft=0.5546875, CBRight=0.7578125, CBTop=0.23828125, CBBottom=0.4453125, OBLeft=0.7578125, OBRight=0.9921875, OBTop=0.23828125, OBBottom=0.4609375};
GEM_TYPE_INFO["Meta"] = {w=57, h=52, left=0.171875, right=0.3984375, top=0.40234375, bottom=0.609375, r=1, g=1, b=1, CBLeft=0.5546875, CBRight=0.7578125, CBTop=0, CBBottom=0.20703125, OBLeft=0.7578125, OBRight=0.9921875, OBTop=0, OBBottom=0.22265625};
GEM_TYPE_INFO["Socket"] = {w=57, h=52, left=0.171875, right=0.3984375, top=0.40234375, bottom=0.609375, r=1, g=1, b=1, CBLeft=0.5546875, CBRight=0.7578125, CBTop=0, CBBottom=0.20703125, OBLeft=0.7578125, OBRight=0.9921875, OBTop=0, OBBottom=0.22265625};
ITEM_SOCKETING_DESCRIPTION_MIN_WIDTH = 240;
function ItemSocketingFrame_OnLoad(self)
self:RegisterEvent("SOCKET_INFO_UPDATE");
self:RegisterEvent("SOCKET_INFO_CLOSE");
ItemSocketingScrollFrameScrollBarScrollUpButton:SetPoint("BOTTOM", ItemSocketingScrollFrameScrollBar, "TOP", 0, 1);
ItemSocketingScrollFrameScrollBarScrollDownButton:SetPoint("TOP", ItemSocketingScrollFrameScrollBar, "BOTTOM", 0, -3);
ItemSocketingScrollFrameTop:SetPoint("TOP", ItemSocketingScrollFrameScrollBarScrollUpButton, "TOP", -2, 3);
ItemSocketingScrollFrameScrollBar:SetPoint("TOPLEFT", ItemSocketingScrollFrame, "TOPRIGHT", 7.9999995231628, -18);
ItemSocketingScrollFrameScrollBar:SetHeight(221);
ItemSocketingDescription:SetMinimumWidth(ITEM_SOCKETING_DESCRIPTION_MIN_WIDTH, 1);
end
function ItemSocketingFrame_OnEvent(self, event, ...)
if ( event == "SOCKET_INFO_UPDATE" ) then
ItemSocketingFrame_Update();
ItemSocketingFrame_LoadUI();
if ( not ItemSocketingFrame:IsShown() ) then
ShowUIPanel(ItemSocketingFrame);
end
elseif ( event == "SOCKET_INFO_CLOSE" ) then
HideUIPanel(ItemSocketingFrame);
end
end
function ItemSocketingFrame_Update()
ItemSocketingFrame.destroyingGem = nil;
ItemSocketingFrame.itemIsRefundable = nil;
ItemSocketingFrame.itemIsBoundTradeable = nil;
if(GetSocketItemRefundable()) then
ItemSocketingFrame.itemIsRefundable = true;
elseif(GetSocketItemBoundTradeable()) then
ItemSocketingFrame.itemIsBoundTradeable = true;
end
local numSockets = GetNumSockets();
local name, icon, quality, gemMatchesSocket;
local socket, socketName;
local numNewGems = numSockets;
local closedBracket, openBracket;
local bracketsOpen, gemColor, gemBorder, gemColorText, gemInfo;
local numMatches = 0;
for i=1, MAX_NUM_SOCKETS do
socket = _G["ItemSocketingSocket"..i];
socketName = "ItemSocketingSocket"..i;
closedBracket = _G[socketName.."BracketFrameClosedBracket"];
openBracket = _G[socketName.."BracketFrameOpenBracket"];
if ( i <= numSockets ) then
-- See if there's a replacement gem and if not see if there's an existing gem
name, icon, gemMatchesSocket = GetNewSocketInfo(i);
bracketsOpen = 1;
if ( not name ) then
name, icon, gemMatchesSocket = GetExistingSocketInfo(i);
if ( icon ) then
bracketsOpen = nil;
end
-- Count down new gems if there's no name
numNewGems = numNewGems - 1;
elseif ( GetExistingSocketInfo(i) ) then
ItemSocketingFrame.destroyingGem = 1;
end
--Handle one color only right now
gemColor = GetSocketTypes(i);
if ( gemMatchesSocket ) then
local color = GEM_TYPE_INFO[gemColor];
AnimatedShine_Start(socket, color.r, color.g, color.b);
numMatches = numMatches + 1;
else
AnimatedShine_Stop(socket);
end
if ( bracketsOpen ) then
-- Show open brackets
closedBracket:Hide();
openBracket:Show();
else
-- Show closed brackets
closedBracket:Show();
openBracket:Hide();
end
if ( gemColor ~= "" ) then
gemInfo = GEM_TYPE_INFO[gemColor];
gemBorder = _G[socketName.."Background"]
gemBorder:SetWidth(gemInfo.w);
gemBorder:SetHeight(gemInfo.h);
gemBorder:SetTexCoord(gemInfo.left, gemInfo.right, gemInfo.top, gemInfo.bottom);
gemBorder:Show();
if ( gemColor == "Meta" ) then
-- Special stuff for meta gem sockets
SetDesaturation(openBracket, 1);
SetDesaturation(closedBracket, 1);
openBracket:SetTexCoord(gemInfo.OBLeft, gemInfo.OBRight, gemInfo.OBTop, gemInfo.OBBottom);
closedBracket:SetTexCoord(gemInfo.CBLeft, gemInfo.CBRight, gemInfo.CBTop, gemInfo.CBBottom);
else
SetDesaturation(openBracket, nil);
SetDesaturation(closedBracket, nil);
openBracket:SetTexCoord(gemInfo.OBLeft, gemInfo.OBRight, gemInfo.OBTop, gemInfo.OBBottom);
closedBracket:SetTexCoord(gemInfo.CBLeft, gemInfo.CBRight, gemInfo.CBTop, gemInfo.CBBottom);
end
if ( ENABLE_COLORBLIND_MODE == "1" ) then
gemColorText = _G[socketName.."Color"];
gemColorText:SetText(_G[strupper(gemColor) .. "_GEM"]);
gemColorText:Show();
else
_G[socketName.."Color"]:Hide();
end
else
gemBorder:Hide();
end
SetItemButtonTexture(socket, icon);
socket:Show();
else
socket:Hide();
end
end
-- Playsound if all sockets are matched
if ( numMatches == numsockets ) then
-- Will probably need a new sound
PlaySound("MapPing");
end
-- Position the sockets and show/hide the border graphics
if ( numSockets == 3 ) then
ItemSocketingSocket1Right:Hide();
ItemSocketingSocket2Left:Show();
ItemSocketingSocket2Right:Hide();
ItemSocketingSocket3Left:Show();
ItemSocketingSocket3Right:Show();
ItemSocketingSocket1:SetPoint("BOTTOM", ItemSocketingFrame, "BOTTOM", -75, 62);
elseif ( numSockets == 2 ) then
ItemSocketingSocket1Right:Hide();
ItemSocketingSocket2Left:Show();
ItemSocketingSocket2Right:Show();
ItemSocketingSocket1:SetPoint("BOTTOM", ItemSocketingFrame, "BOTTOM", -35, 62);
else
ItemSocketingSocket1:SetPoint("BOTTOM", ItemSocketingFrame, "BOTTOM", 0, 62);
ItemSocketingSocket1Right:Show();
end
-- Set portrait
name, icon, quality = GetSocketItemInfo();
SetPortraitToTexture("ItemSocketingFramePortrait", icon);
-- see if has a scrollbar and resize accordingly
local scrollBarOffset = 28;
if ( ItemSocketingScrollFrame:GetVerticalScrollRange() ~= 0 ) then
scrollBarOffset = 0;
end
ItemSocketingScrollFrame:SetWidth(269+scrollBarOffset);
ItemSocketingDescription:SetMinimumWidth(ITEM_SOCKETING_DESCRIPTION_MIN_WIDTH+scrollBarOffset, 1);
-- Owner needs to be set everytime since it is cleared everytime the tooltip is hidden
ItemSocketingDescription:SetOwner(ItemSocketingScrollChild, "ANCHOR_PRESERVE");
ItemSocketingDescription:SetSocketedItem();
-- Update socket button
if ( numNewGems == 0 ) then
ItemSocketingSocketButton_Disable();
else
ItemSocketingSocketButton_Enable();
end
end
function ItemSocketingSocketButton_OnScrollRangeChanged()
-- see if has a scrollbar and resize accordingly
local scrollBarOffset = 28;
if ( ItemSocketingScrollFrame:GetVerticalScrollRange() ~= 0 ) then
scrollBarOffset = 0;
end
ItemSocketingScrollFrame:SetWidth(269+scrollBarOffset);
ItemSocketingDescription:SetMinimumWidth(ITEM_SOCKETING_DESCRIPTION_MIN_WIDTH+scrollBarOffset, 1);
ItemSocketingDescription:SetSocketedItem();
end
function ItemSocketingSocketButton_OnEnter(self)
local newSocket = GetNewSocketInfo(self:GetID());
local existingSocket = GetExistingSocketInfo(self:GetID());
GameTooltip:SetOwner(self, "ANCHOR_RIGHT");
if ( newSocket ) then
GameTooltip:SetSocketGem(self:GetID());
else
GameTooltip:SetExistingSocketGem(self:GetID());
end
if ( newSocket and existingSocket ) then
ShoppingTooltip1:SetOwner(GameTooltip, "ANCHOR_NONE");
ShoppingTooltip1:ClearAllPoints();
ShoppingTooltip1:SetPoint("TOPLEFT", "GameTooltip", "TOPRIGHT", 0, -10);
ShoppingTooltip1:SetExistingSocketGem(self:GetID(), 1);
ShoppingTooltip1:Show();
end
end
function ItemSocketingSocketButton_OnEvent(self, event, ...)
if ( event == "SOCKET_INFO_UPDATE" ) then
if ( GameTooltip:IsOwned(self) ) then
ItemSocketingSocketButton_OnEnter(self);
end
end
end
function ItemSocketingSocketButton_Disable()
ItemSocketingSocketButton.disabled = 1;
ItemSocketingSocketButton:Disable();
ItemSocketingSocketButtonLeft:SetTexture("Interface\\Buttons\\UI-Panel-Button-Disabled");
ItemSocketingSocketButtonMiddle:SetTexture("Interface\\Buttons\\UI-Panel-Button-Disabled");
ItemSocketingSocketButtonRight:SetTexture("Interface\\Buttons\\UI-Panel-Button-Disabled");
end
function ItemSocketingSocketButton_Enable()
ItemSocketingSocketButton.disabled = nil;
ItemSocketingSocketButton:Enable();
ItemSocketingSocketButtonLeft:SetTexture("Interface\\Buttons\\UI-Panel-Button-Up");
ItemSocketingSocketButtonMiddle:SetTexture("Interface\\Buttons\\UI-Panel-Button-Up");
ItemSocketingSocketButtonRight:SetTexture("Interface\\Buttons\\UI-Panel-Button-Up");
end
@@ -0,0 +1,6 @@
## Interface: 30300
## Title: Blizzard Item Socketing UI
## Secure: 1
## LoadOnDemand: 1
Blizzard_ItemSocketingUI.xml
Localization.lua
@@ -0,0 +1,461 @@
<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="Blizzard_ItemSocketingUI.lua"/>
<Button name="ItemSocketingSocketButtonTemplate" virtual="true">
<Size>
<AbsDimension x="40" y="40"/>
</Size>
<Layers>
<Layer level="BACKGROUND">
<Texture name="$parentRight" file="Interface\ItemSocketingFrame\UI-ItemSockets">
<Size>
<AbsDimension x="73" y="55"/>
</Size>
<Anchors>
<Anchor point="LEFT" relativePoint="CENTER">
<Offset>
<AbsDimension x="5" y="5"/>
</Offset>
</Anchor>
</Anchors>
<TexCoords left="0.28515625" right="0.5703125" top="0" bottom="0.21484375"/>
</Texture>
</Layer>
<Layer level="BORDER">
<Texture file="Interface\ItemSocketingFrame\UI-ItemSockets">
<Size>
<AbsDimension x="72" y="74"/>
</Size>
<Anchors>
<Anchor point="CENTER">
<Offset>
<AbsDimension x="0" y="0"/>
</Offset>
</Anchor>
</Anchors>
<TexCoords left="0.71875" right="1" top="0.7109375" bottom="1"/>
</Texture>
<Texture name="$parentBackground" file="Interface\ItemSocketingFrame\UI-ItemSockets">
<Size>
<AbsDimension x="43" y="44"/>
</Size>
<Anchors>
<Anchor point="CENTER">
<Offset>
<AbsDimension x="0" y="0"/>
</Offset>
</Anchor>
</Anchors>
</Texture>
</Layer>
<Layer level="ARTWORK">
<Texture name="$parentIconTexture">
<Size x="38" y="38"/>
<Anchors>
<Anchor point="CENTER">
<Offset>
<AbsDimension x="0" y="0"/>
</Offset>
</Anchor>
</Anchors>
</Texture>
<!--<Texture name="$parentBorder" file="Interface\ItemSocketingFrame\UI-ItemSockets">
<Size>
<AbsDimension x="53" y="53"/>
</Size>
<Anchors>
<Anchor point="CENTER">
<Offset>
<AbsDimension x="0" y="0"/>
</Offset>
</Anchor>
</Anchors>
</Texture>-->
</Layer>
<Layer level="OVERLAY">
<FontString name="$parentColor" inherits="TextStatusBarText" text="Color" hidden="true">
<Anchors>
<Anchor point="CENTER"/>
</Anchors>
</FontString>
</Layer>
</Layers>
<Frames>
<Frame name="$parentShine" inherits="AnimatedShineTemplate">
<Anchors>
<Anchor point="CENTER">
<Offset>
<AbsDimension x="-1" y="0"/>
</Offset>
</Anchor>
</Anchors>
</Frame>
<Frame name="$parentBracketFrame" setAllPoints="true">
<Layers>
<Layer level="ARTWORK">
<Texture name="$parentClosedBracket" file="Interface\ItemSocketingFrame\UI-ItemSockets">
<Size>
<AbsDimension x="53" y="53"/>
</Size>
<Anchors>
<Anchor point="CENTER">
<Offset>
<AbsDimension x="0" y="0"/>
</Offset>
</Anchor>
</Anchors>
<TexCoords left="0.5546875" right="0.7578125" top="0" bottom="0.20703125"/>
</Texture>
<Texture name="$parentOpenBracket" file="Interface\ItemSocketingFrame\UI-ItemSockets">
<Size>
<AbsDimension x="61" y="57"/>
</Size>
<Anchors>
<Anchor point="CENTER">
<Offset>
<AbsDimension x="0" y="-1"/>
</Offset>
</Anchor>
</Anchors>
<TexCoords left="0.7578125" right="0.9921875" top="0" bottom="0.22265625"/>
</Texture>
</Layer>
</Layers>
</Frame>
</Frames>
<Scripts>
<OnLoad>
self:RegisterForDrag("LeftButton");
self:RegisterEvent("SOCKET_INFO_UPDATE");
</OnLoad>
<OnEvent>
ItemSocketingSocketButton_OnEvent(self, event, ...);
</OnEvent>
<OnClick>
if ( IsModifiedClick() ) then
local link = GetNewSocketLink(self:GetID()) or
GetExistingSocketLink(self:GetID());
HandleModifiedItemClick(link);
else
StaticPopup_Hide("DELETE_ITEM");
StaticPopup_Hide("DELETE_GOOD_ITEM");
ClickSocketButton(self:GetID());
end
</OnClick>
<OnReceiveDrag>
StaticPopup_Hide("DELETE_ITEM");
StaticPopup_Hide("DELETE_GOOD_ITEM");
ClickSocketButton(self:GetID());
</OnReceiveDrag>
<OnDragStart>
StaticPopup_Hide("DELETE_ITEM");
StaticPopup_Hide("DELETE_GOOD_ITEM");
ClickSocketButton(self:GetID());
</OnDragStart>
<OnEnter>
ItemSocketingSocketButton_OnEnter(self, motion);
</OnEnter>
<OnLeave>
GameTooltip:Hide();
ShoppingTooltip1:Hide();
</OnLeave>
</Scripts>
<NormalTexture file=""/>
<PushedTexture file="Interface\Buttons\UI-Quickslot-Depress"/>
<HighlightTexture file="Interface\Buttons\ButtonHilight-Square" alphaMode="ADD"/>
</Button>
<Frame name="ItemSocketingFrame" toplevel="true" parent="UIParent" enableMouse="true" hidden="true">
<Size>
<AbsDimension x="354" y="467"/>
</Size>
<Anchors>
<Anchor point="TOPLEFT">
<Offset>
<AbsDimension x="0" y="-104"/>
</Offset>
</Anchor>
</Anchors>
<Layers>
<Layer level="BACKGROUND">
<Texture name="ItemSocketingFramePortrait">
<Size>
<AbsDimension x="60" y="60"/>
</Size>
<Anchors>
<Anchor point="TOPLEFT">
<Offset>
<AbsDimension x="7" y="-6"/>
</Offset>
</Anchor>
</Anchors>
</Texture>
</Layer>
<Layer level="BORDER">
<Texture file="Interface\ItemSocketingFrame\UI-ItemSocketingFrame">
<Size>
<AbsDimension x="512" y="512"/>
</Size>
<Anchors>
<Anchor point="TOPLEFT">
<Offset>
<AbsDimension x="0" y="0"/>
</Offset>
</Anchor>
</Anchors>
</Texture>
<FontString inherits="GameFontNormal" text="ITEM_SOCKETING">
<Anchors>
<Anchor point="TOP">
<Offset>
<AbsDimension x="15" y="-18"/>
</Offset>
</Anchor>
</Anchors>
</FontString>
</Layer>
</Layers>
<Frames>
<ScrollFrame name="ItemSocketingScrollFrame" inherits="UIPanelScrollFrameTemplate">
<Size>
<AbsDimension x="269" y="255"/>
</Size>
<Anchors>
<Anchor point="TOPLEFT">
<Offset x="32" y="-89"/>
</Anchor>
</Anchors>
<Layers>
<Layer level="ARTWORK">
<Texture name="$parentTop" file="Interface\ItemSocketingFrame\UI-ItemSocketingFrame-ScrollBar">
<Size>
<AbsDimension x="29" y="256"/>
</Size>
<Anchors>
<Anchor point="TOP"/>
</Anchors>
<TexCoords left="0" right="0.46875" top="0" bottom="1"/>
</Texture>
<Texture name="$parentBottom" file="Interface\ItemSocketingFrame\UI-ItemSocketingFrame-ScrollBar">
<Size>
<AbsDimension x="29" y="5"/>
</Size>
<Anchors>
<Anchor point="TOPLEFT" relativeTo="$parentTop" relativePoint="BOTTOMLEFT">
<Offset>
<AbsDimension x="0" y="0"/>
</Offset>
</Anchor>
</Anchors>
<TexCoords left="0.53125" right="1" top="0" bottom="0.01953125"/>
</Texture>
</Layer>
</Layers>
<Scripts>
<OnLoad>
self.scrollBarHideable = 1;
ScrollFrame_OnLoad(self);
ScrollFrame_OnScrollRangeChanged(self, 0, 0);
</OnLoad>
<OnScrollRangeChanged>
ScrollFrame_OnScrollRangeChanged(self, 0, yrange);
ItemSocketingSocketButton_OnScrollRangeChanged(self);
</OnScrollRangeChanged>
</Scripts>
<ScrollChild>
<Frame name="ItemSocketingScrollChild">
<Size>
<AbsDimension x="259" y="250"/>
</Size>
<Frames>
<GameTooltip name="ItemSocketingDescription" inherits="GameTooltipTemplate" setAllPoints="true" hidden="false">
<Scripts>
<OnLoad>
self:SetBackdrop(nil);
</OnLoad>
</Scripts>
</GameTooltip>
</Frames>
</Frame>
</ScrollChild>
</ScrollFrame>
<Button name="ItemSocketingSocket1" inherits="ItemSocketingSocketButtonTemplate" id="1">
<Anchors>
<Anchor point="BOTTOM">
<Offset>
<AbsDimension x="0" y="37"/>
</Offset>
</Anchor>
</Anchors>
<Layers>
<Layer level="BACKGROUND">
<Texture name="ItemSocketingSocket1Left" file="Interface\ItemSocketingFrame\UI-ItemSockets">
<Size>
<AbsDimension x="73" y="55"/>
</Size>
<Anchors>
<Anchor point="RIGHT" relativePoint="CENTER">
<Offset>
<AbsDimension x="-5" y="5"/>
</Offset>
</Anchor>
</Anchors>
<TexCoords left="0" right="0.28515625" top="0" bottom="0.21484375"/>
</Texture>
</Layer>
</Layers>
</Button>
<Button name="ItemSocketingSocket2" inherits="ItemSocketingSocketButtonTemplate" id="2">
<Anchors>
<Anchor point="LEFT" relativeTo="ItemSocketingSocket1" relativePoint="RIGHT">
<Offset>
<AbsDimension x="40" y="0"/>
</Offset>
</Anchor>
</Anchors>
<Layers>
<Layer level="BACKGROUND">
<Texture name="ItemSocketingSocket2Left" file="Interface\ItemSocketingFrame\UI-ItemSockets">
<Size>
<AbsDimension x="73" y="46"/>
</Size>
<Anchors>
<Anchor point="RIGHT" relativePoint="CENTER">
<Offset>
<AbsDimension x="-5" y="0"/>
</Offset>
</Anchor>
</Anchors>
<TexCoords left="0" right="0.28515625" top="0.21484375" bottom="0.39453125"/>
</Texture>
</Layer>
</Layers>
</Button>
<Button name="ItemSocketingSocket3" inherits="ItemSocketingSocketButtonTemplate" id="3">
<Anchors>
<Anchor point="LEFT" relativeTo="ItemSocketingSocket2" relativePoint="RIGHT">
<Offset>
<AbsDimension x="40" y="0"/>
</Offset>
</Anchor>
</Anchors>
<Layers>
<Layer level="BACKGROUND">
<Texture name="ItemSocketingSocket3Left" file="Interface\ItemSocketingFrame\UI-ItemSockets">
<Size>
<AbsDimension x="73" y="46"/>
</Size>
<Anchors>
<Anchor point="RIGHT" relativePoint="CENTER">
<Offset>
<AbsDimension x="-5" y="0"/>
</Offset>
</Anchor>
</Anchors>
<TexCoords left="0" right="0.28515625" top="0.21484375" bottom="0.39453125"/>
</Texture>
</Layer>
</Layers>
</Button>
<Button name="ItemSocketingSocketButton" text="SOCKET_GEMS">
<Size>
<AbsDimension x="162" y="22"/>
</Size>
<Anchors>
<Anchor point="BOTTOMRIGHT">
<Offset>
<AbsDimension x="-10" y="33"/>
</Offset>
</Anchor>
</Anchors>
<Layers>
<Layer level="BACKGROUND">
<Texture name="$parentLeft" file="Interface\Buttons\UI-Panel-Button-Up">
<Size>
<AbsDimension x="12" y="22"/>
</Size>
<Anchors>
<Anchor point="LEFT"/>
</Anchors>
<TexCoords left="0" right="0.09375" top="0" bottom="0.6875"/>
</Texture>
<Texture name="$parentRight" file="Interface\Buttons\UI-Panel-Button-Up">
<Size>
<AbsDimension x="12" y="22"/>
</Size>
<Anchors>
<Anchor point="RIGHT"/>
</Anchors>
<TexCoords left="0.53125" right="0.625" top="0" bottom="0.6875"/>
</Texture>
<Texture name="$parentMiddle" file="Interface\Buttons\UI-Panel-Button-Up">
<Size>
<AbsDimension x="12" y="22"/>
</Size>
<Anchors>
<Anchor point="LEFT" relativeTo="$parentLeft" relativePoint="RIGHT"/>
<Anchor point="RIGHT" relativeTo="$parentRight" relativePoint="LEFT"/>
</Anchors>
<TexCoords left="0.09375" right="0.53125" top="0" bottom="0.6875"/>
</Texture>
</Layer>
</Layers>
<Scripts>
<OnClick>
if( ItemSocketingFrame.itemIsRefundable) then
local dialog = StaticPopup_Show("END_REFUND");
if(dialog) then
dialog.data = 2;
end
elseif ( ItemSocketingFrame.itemIsBoundTradeable ) then
local dialog = StaticPopup_Show("END_BOUND_TRADEABLE", nil, nil, "gem");
elseif ( ItemSocketingFrame.destroyingGem ) then
StaticPopup_Show("CONFIRM_ACCEPT_SOCKETS");
else
AcceptSockets();
PlaySound("JewelcraftingFinalize");
end
</OnClick>
<OnMouseDown>
if ( not self.disabled ) then
_G[self:GetName().."Left"]:SetTexture("Interface\\Buttons\\UI-Panel-Button-Down");
_G[self:GetName().."Middle"]:SetTexture("Interface\\Buttons\\UI-Panel-Button-Down");
_G[self:GetName().."Right"]:SetTexture("Interface\\Buttons\\UI-Panel-Button-Down");
end
</OnMouseDown>
<OnMouseUp>
if ( not self.disabled ) then
_G[self:GetName().."Left"]:SetTexture("Interface\\Buttons\\UI-Panel-Button-Up");
_G[self:GetName().."Middle"]:SetTexture("Interface\\Buttons\\UI-Panel-Button-Up");
_G[self:GetName().."Right"]:SetTexture("Interface\\Buttons\\UI-Panel-Button-Up");
end
</OnMouseUp>
</Scripts>
<NormalFont style="GameFontNormal"/>
<DisabledFont style="GameFontDisable"/>
<HighlightFont style="GameFontHighlight"/>
<HighlightTexture inherits="UIPanelButtonHighlightTexture"/>
</Button>
<Button name="ItemSocketingCloseButton" inherits="UIPanelCloseButton">
<Anchors>
<Anchor point="TOPRIGHT" relativePoint="TOPRIGHT">
<Offset>
<AbsDimension x="-1" y="-9"/>
</Offset>
</Anchor>
</Anchors>
</Button>
</Frames>
<Scripts>
<OnLoad function="ItemSocketingFrame_OnLoad"/>
<OnShow>
PlaySound("igCharacterInfoOpen");
</OnShow>
<OnEvent function="ItemSocketingFrame_OnEvent"/>
<OnHide>
PlaySound("igCharacterInfoClose");
StaticPopup_Hide("CONFIRM_ACCEPT_SOCKETS");
CloseSocketInfo();
</OnHide>
</Scripts>
</Frame>
</Ui>
@@ -0,0 +1 @@
-- This file is executed at the end of addon load