mirror of
https://github.com/Bluewhale1337/ElvUIModernized.git
synced 2026-07-27 16:34:45 +00:00
1
This commit is contained in:
@@ -97,7 +97,7 @@ local function LoadSkin()
|
||||
button = _G["BankFrameItem"..i]
|
||||
buttonIcon = _G["BankFrameItem"..i.."IconTexture"]
|
||||
|
||||
button:SetNormalTexture(nil)
|
||||
button:SetNormalTexture("")
|
||||
|
||||
E:SetTemplate(button, "Default", true)
|
||||
E:StyleButton(button)
|
||||
@@ -116,7 +116,7 @@ local function LoadSkin()
|
||||
button = _G["BankFrameBag"..i]
|
||||
buttonIcon = _G["BankFrameBag"..i.."IconTexture"]
|
||||
|
||||
button:SetNormalTexture(nil)
|
||||
button:SetNormalTexture("")
|
||||
|
||||
E:SetTemplate(button, "Default", true)
|
||||
E:StyleButton(button)
|
||||
|
||||
@@ -18,10 +18,10 @@ local function LoadSkin()
|
||||
SpellBookFrame.backdrop:SetPoint("BOTTOMRIGHT", -31, 75)
|
||||
|
||||
for i = 1, 3 do
|
||||
local tab = _G["SpellBookFrameTabButton" .. i]
|
||||
local tab = _G["SpellBookFrameTabButton"..i]
|
||||
|
||||
tab:GetNormalTexture():SetTexture(nil)
|
||||
tab:GetDisabledTexture():SetTexture(nil)
|
||||
tab:GetNormalTexture():SetTexture("")
|
||||
tab:GetDisabledTexture():SetTexture("")
|
||||
|
||||
S:HandleTab(tab)
|
||||
|
||||
@@ -35,13 +35,14 @@ local function LoadSkin()
|
||||
S:HandleCloseButton(SpellBookCloseButton)
|
||||
|
||||
for i = 1, SPELLS_PER_PAGE do
|
||||
local button = _G["SpellButton" .. i]
|
||||
local iconTexture = _G["SpellButton" .. i .. "IconTexture"]
|
||||
local button = _G["SpellButton"..i]
|
||||
local iconTexture = _G["SpellButton"..i.."IconTexture"]
|
||||
local cooldown = _G["SpellButton"..i.."Cooldown"]
|
||||
|
||||
button:DisableDrawLayer("BACKGROUND")
|
||||
button:GetNormalTexture():SetTexture(nil)
|
||||
button:GetPushedTexture():SetTexture(nil)
|
||||
button:GetNormalTexture():SetTexture("")
|
||||
button:GetPushedTexture():SetTexture("")
|
||||
--E:StyleButton(button, true)
|
||||
|
||||
if iconTexture then
|
||||
iconTexture:SetTexCoord(unpack(E.TexCoords))
|
||||
|
||||
@@ -7,6 +7,7 @@ local _G = _G
|
||||
local unpack = unpack
|
||||
local select = select
|
||||
local find = string.find
|
||||
local match = string.match
|
||||
local split = string.split
|
||||
--WoW API / Variables
|
||||
local GetItemInfo = GetItemInfo
|
||||
@@ -49,7 +50,7 @@ local function LoadSkin()
|
||||
TradeSkillCollapseAllButton.Text:SetText("+")
|
||||
|
||||
hooksecurefunc(TradeSkillCollapseAllButton, "SetNormalTexture", function(self, texture)
|
||||
if(find(texture, "MinusButton")) then
|
||||
if find(texture, "MinusButton") then
|
||||
self.Text:SetText("-")
|
||||
else
|
||||
self.Text:SetText("+")
|
||||
@@ -68,12 +69,12 @@ local function LoadSkin()
|
||||
TradeSkillFrameTitleText:SetPoint("TOP", TradeSkillFrame, "TOP", 0, -18)
|
||||
|
||||
for i = 1, TRADE_SKILLS_DISPLAYED do
|
||||
local skillButton = _G["TradeSkillSkill" .. i]
|
||||
local skillButton = _G["TradeSkillSkill"..i]
|
||||
skillButton:SetNormalTexture("")
|
||||
skillButton.SetNormalTexture = E.noop
|
||||
|
||||
_G["TradeSkillSkill" .. i .. "Highlight"]:SetTexture("")
|
||||
_G["TradeSkillSkill" .. i .. "Highlight"].SetTexture = E.noop
|
||||
_G["TradeSkillSkill"..i.."Highlight"]:SetTexture("")
|
||||
_G["TradeSkillSkill"..i.."Highlight"].SetTexture = E.noop
|
||||
|
||||
skillButton.Text = skillButton:CreateFontString(nil, "OVERLAY")
|
||||
E:FontTemplate(skillButton.Text, nil, 22)
|
||||
@@ -102,10 +103,10 @@ local function LoadSkin()
|
||||
E:SetTemplate(TradeSkillSkillIcon, "Default")
|
||||
|
||||
for i = 1, MAX_TRADE_SKILL_REAGENTS do
|
||||
local reagent = _G["TradeSkillReagent" .. i]
|
||||
local icon = _G["TradeSkillReagent" .. i .. "IconTexture"]
|
||||
local count = _G["TradeSkillReagent" .. i .. "Count"]
|
||||
local nameFrame = _G["TradeSkillReagent" .. i .. "NameFrame"]
|
||||
local reagent = _G["TradeSkillReagent"..i]
|
||||
local icon = _G["TradeSkillReagent"..i.."IconTexture"]
|
||||
local count = _G["TradeSkillReagent"..i.."Count"]
|
||||
local nameFrame = _G["TradeSkillReagent"..i.."NameFrame"]
|
||||
|
||||
icon:SetTexCoord(unpack(E.TexCoords))
|
||||
icon:SetDrawLayer("OVERLAY")
|
||||
@@ -136,8 +137,10 @@ local function LoadSkin()
|
||||
hooksecurefunc("TradeSkillFrame_SetSelection", function(id)
|
||||
E:SetTemplate(TradeSkillSkillIcon, "Default", true)
|
||||
E:StyleButton(TradeSkillSkillIcon, nil, true)
|
||||
TradeSkillSkillIcon:GetNormalTexture():SetTexCoord(unpack(E.TexCoords))
|
||||
E:SetInside(TradeSkillSkillIcon:GetNormalTexture())
|
||||
if TradeSkillSkillIcon:GetNormalTexture() then
|
||||
TradeSkillSkillIcon:GetNormalTexture():SetTexCoord(unpack(E.TexCoords))
|
||||
E:SetInside(TradeSkillSkillIcon:GetNormalTexture())
|
||||
end
|
||||
|
||||
TradeSkillSkillIcon:SetWidth(40)
|
||||
TradeSkillSkillIcon:SetHeight(40)
|
||||
@@ -145,11 +148,8 @@ local function LoadSkin()
|
||||
|
||||
local skillLink = GetTradeSkillItemLink(id)
|
||||
if skillLink then
|
||||
TradeSkillRequirementLabel:SetTextColor(1, 0.80, 0.10)
|
||||
local skillString = select(3, find(skillLink, "|H(.+)|h"))
|
||||
local skillID = select(2, split(":", skillString))
|
||||
local quality = select(3, GetItemInfo(skillID))
|
||||
if quality and quality > 1 then
|
||||
local _, _, quality = GetItemInfo(match(skillLink, "item:(%d+)"))
|
||||
if quality then
|
||||
TradeSkillSkillIcon:SetBackdropBorderColor(GetItemQualityColor(quality))
|
||||
TradeSkillSkillName:SetTextColor(GetItemQualityColor(quality))
|
||||
else
|
||||
@@ -162,14 +162,12 @@ local function LoadSkin()
|
||||
for i = 1, numReagents, 1 do
|
||||
local _, _, reagentCount, playerReagentCount = GetTradeSkillReagentInfo(id, i)
|
||||
local reagentLink = GetTradeSkillReagentItemLink(id, i)
|
||||
local icon = _G["TradeSkillReagent" .. i .. "IconTexture"]
|
||||
local name = _G["TradeSkillReagent" .. i .. "Name"]
|
||||
local icon = _G["TradeSkillReagent"..i.."IconTexture"]
|
||||
local name = _G["TradeSkillReagent"..i.."Name"]
|
||||
|
||||
if reagentLink then
|
||||
local reagentString = select(3, find(reagentLink, "|H(.+)|h"))
|
||||
local reagentID = select(2, split(":", reagentString))
|
||||
local quality = select(3, GetItemInfo(reagentID))
|
||||
if quality and quality > 1 then
|
||||
local _, _, quality = GetItemInfo(match(reagentLink, "item:(%d+)"))
|
||||
if quality then
|
||||
icon.backdrop:SetBackdropBorderColor(GetItemQualityColor(quality))
|
||||
if playerReagentCount < reagentCount then
|
||||
name:SetTextColor(0.5, 0.5, 0.5)
|
||||
|
||||
@@ -156,21 +156,7 @@ function S:HandleTab(tab)
|
||||
end
|
||||
|
||||
function S:HandleNextPrevButton(btn, buttonOverride)
|
||||
local inverseDirection
|
||||
if btn:GetName() then
|
||||
for k in string.gfind(lower(btn:GetName()), "left") do
|
||||
inverseDirection = k
|
||||
end
|
||||
for k in string.gfind(lower(btn:GetName()), "prev") do
|
||||
inverseDirection = k
|
||||
end
|
||||
for k in string.gfind(lower(btn:GetName()), "decrement") do
|
||||
inverseDirection = k
|
||||
end
|
||||
for k in string.gfind(lower(btn:GetName()), "promote") do
|
||||
inverseDirection = k
|
||||
end
|
||||
end
|
||||
local inverseDirection = btn:GetName() and (find(lower(btn:GetName()), "left") or find(lower(btn:GetName()), "prev") or find(lower(btn:GetName()), "decrement") or find(lower(btn:GetName()), "promote"))
|
||||
|
||||
E:StripTextures(btn)
|
||||
btn:SetNormalTexture(nil)
|
||||
|
||||
Reference in New Issue
Block a user