mirror of
https://github.com/Bluewhale1337/ElvUIModernized.git
synced 2026-07-27 08:24:44 +00:00
remove temp folder structure
This commit is contained in:
@@ -0,0 +1,340 @@
|
||||
local E, L, V, P, G = unpack(ElvUI); --Import: Engine, Locales, PrivateDB, ProfileDB, GlobalDB
|
||||
local S = E:GetModule("Skins");
|
||||
|
||||
--Cache global variables
|
||||
--Lua functions
|
||||
local _G = _G
|
||||
local unpack = unpack
|
||||
local pairs = pairs
|
||||
--WoW API / Variables
|
||||
local hooksecurefunc = hooksecurefunc
|
||||
|
||||
local function LoadSkin()
|
||||
if E.private.skins.blizzard.enable ~= true or E.private.skins.blizzard.auctionhouse ~= true then return end
|
||||
|
||||
E:StripTextures(AuctionFrame, true)
|
||||
E:CreateBackdrop(AuctionFrame, "Transparent")
|
||||
AuctionFrame.backdrop:SetPoint("TOPLEFT", 10, -11)
|
||||
AuctionFrame.backdrop:SetPoint("BOTTOMRIGHT", 0, 4)
|
||||
|
||||
E:StripTextures(BrowseFilterScrollFrame)
|
||||
E:StripTextures(BrowseScrollFrame)
|
||||
E:StripTextures(AuctionsScrollFrame)
|
||||
E:StripTextures(BidScrollFrame)
|
||||
|
||||
S:HandleDropDownBox(BrowseDropDown)
|
||||
|
||||
S:HandleScrollBar(BrowseFilterScrollFrameScrollBar)
|
||||
S:HandleScrollBar(BrowseScrollFrameScrollBar)
|
||||
S:HandleScrollBar(AuctionsScrollFrameScrollBar)
|
||||
|
||||
S:HandleCloseButton(AuctionFrameCloseButton)
|
||||
|
||||
-- DressUpFrame
|
||||
E:StripTextures(AuctionDressUpFrame)
|
||||
E:CreateBackdrop(AuctionDressUpFrame, "Default")
|
||||
|
||||
SetAuctionDressUpBackground()
|
||||
AuctionDressUpBackgroundTop:SetDesaturated(true)
|
||||
AuctionDressUpBackgroundBot:SetDesaturated(true)
|
||||
|
||||
E:SetOutside(AuctionDressUpFrame.backdrop, AuctionDressUpBackgroundTop, nil, nil, AuctionDressUpBackgroundBot)
|
||||
|
||||
S:HandleRotateButton(AuctionDressUpModelRotateLeftButton)
|
||||
AuctionDressUpModelRotateLeftButton:SetPoint("TOPLEFT", AuctionDressUpFrame, 8, -17)
|
||||
S:HandleRotateButton(AuctionDressUpModelRotateRightButton)
|
||||
AuctionDressUpModelRotateRightButton:SetPoint("TOPLEFT", AuctionDressUpModelRotateLeftButton, "TOPRIGHT", 3, 0)
|
||||
|
||||
S:HandleButton(AuctionDressUpFrameResetButton)
|
||||
S:HandleCloseButton(AuctionDressUpFrameCloseButton, AuctionDressUpFrame.backdrop)
|
||||
|
||||
local buttons = {
|
||||
"BrowseBidButton",
|
||||
"BidBidButton",
|
||||
"BrowseBuyoutButton",
|
||||
"BidBuyoutButton",
|
||||
"BrowseCloseButton",
|
||||
"BidCloseButton",
|
||||
"BrowseSearchButton",
|
||||
"AuctionsCloseButton",
|
||||
"AuctionsCancelAuctionButton",
|
||||
"AuctionsCreateAuctionButton",
|
||||
}
|
||||
|
||||
for _, button in pairs(buttons) do
|
||||
S:HandleButton(_G[button])
|
||||
end
|
||||
|
||||
--Fix Button Positions
|
||||
AuctionsCloseButton:SetPoint("BOTTOMRIGHT", AuctionFrameAuctions, "BOTTOMRIGHT", 66, 14)
|
||||
AuctionsCancelAuctionButton:SetPoint("RIGHT", AuctionsCloseButton, "LEFT", -4, 0)
|
||||
BidBuyoutButton:SetPoint("RIGHT", BidCloseButton, "LEFT", -4, 0)
|
||||
BidBidButton:SetPoint("RIGHT", BidBuyoutButton, "LEFT", -4, 0)
|
||||
BrowseBuyoutButton:SetPoint("RIGHT", BrowseCloseButton, "LEFT", -4, 0)
|
||||
BrowseBidButton:SetPoint("RIGHT", BrowseBuyoutButton, "LEFT", -4, 0)
|
||||
AuctionsCreateAuctionButton:SetPoint("BOTTOMLEFT", 18, 44)
|
||||
|
||||
BrowseSearchButton:ClearAllPoints()
|
||||
BrowseSearchButton:SetPoint("TOPRIGHT", AuctionFrameBrowse, "TOPRIGHT", 25, -30)
|
||||
|
||||
S:HandleNextPrevButton(BrowseNextPageButton)
|
||||
BrowseNextPageButton:ClearAllPoints()
|
||||
BrowseNextPageButton:SetPoint("BOTTOMLEFT", BrowseSearchButton, "BOTTOMRIGHT", 10, -27)
|
||||
|
||||
S:HandleNextPrevButton(BrowsePrevPageButton)
|
||||
BrowsePrevPageButton:ClearAllPoints()
|
||||
BrowsePrevPageButton:SetPoint("BOTTOMRIGHT", BrowseSearchButton, "BOTTOMLEFT", -10, -27)
|
||||
|
||||
E:StripTextures(AuctionsItemButton)
|
||||
E:SetTemplate(AuctionsItemButton, "Default", true)
|
||||
E:StyleButton(AuctionsItemButton, false, true)
|
||||
|
||||
HookScript(AuctionsItemButton, "OnEvent", function()
|
||||
this:SetBackdropBorderColor(unpack(E["media"].bordercolor))
|
||||
if event == "NEW_AUCTION_UPDATE" and this:GetNormalTexture() then
|
||||
this:GetNormalTexture():SetTexCoord(unpack(E.TexCoords))
|
||||
E:SetInside(this:GetNormalTexture())
|
||||
end
|
||||
|
||||
local itemName = GetAuctionSellItemInfo()
|
||||
if itemName then
|
||||
local _, itemString = GetItemInfoByName(itemName)
|
||||
local _, _, quality = GetItemInfo(itemString, "item:(%d+)")
|
||||
if quality then
|
||||
AuctionsItemButton:SetBackdropBorderColor(GetItemQualityColor(quality))
|
||||
AuctionsItemButtonName:SetTextColor(GetItemQualityColor(quality))
|
||||
else
|
||||
AuctionsItemButton:SetBackdropBorderColor(unpack(E["media"].bordercolor))
|
||||
end
|
||||
end
|
||||
end)
|
||||
|
||||
local sorttabs = {
|
||||
"BrowseQualitySort",
|
||||
"BrowseLevelSort",
|
||||
"BrowseDurationSort",
|
||||
"BrowseHighBidderSort",
|
||||
"BrowseCurrentBidSort",
|
||||
"BidQualitySort",
|
||||
"BidLevelSort",
|
||||
"BidDurationSort",
|
||||
"BidBuyoutSort",
|
||||
"BidStatusSort",
|
||||
"BidBidSort",
|
||||
"AuctionsQualitySort",
|
||||
"AuctionsDurationSort",
|
||||
"AuctionsHighBidderSort",
|
||||
"AuctionsBidSort",
|
||||
}
|
||||
|
||||
for _, sorttab in pairs(sorttabs) do
|
||||
E:Kill(_G[sorttab.."Left"])
|
||||
E:Kill(_G[sorttab.."Middle"])
|
||||
E:Kill(_G[sorttab.."Right"])
|
||||
E:StyleButton(_G[sorttab])
|
||||
end
|
||||
|
||||
for i = 1, 3 do
|
||||
S:HandleTab(_G["AuctionFrameTab"..i])
|
||||
end
|
||||
|
||||
AuctionFrameTab1:ClearAllPoints()
|
||||
AuctionFrameTab1:SetPoint("BOTTOMLEFT", AuctionFrame, "BOTTOMLEFT", 25, -26)
|
||||
AuctionFrameTab1.SetPoint = E.noop
|
||||
|
||||
for i = 1, NUM_FILTERS_TO_DISPLAY do
|
||||
local tab = _G["AuctionFilterButton"..i]
|
||||
|
||||
E:StripTextures(tab)
|
||||
E:StyleButton(tab)
|
||||
end
|
||||
|
||||
local editboxs = {
|
||||
"BrowseName",
|
||||
"BrowseMinLevel",
|
||||
"BrowseMaxLevel",
|
||||
"BrowseBidPriceGold",
|
||||
"BrowseBidPriceSilver",
|
||||
"BrowseBidPriceCopper",
|
||||
"BidBidPriceGold",
|
||||
"BidBidPriceSilver",
|
||||
"BidBidPriceCopper",
|
||||
"StartPriceGold",
|
||||
"StartPriceSilver",
|
||||
"StartPriceCopper",
|
||||
"BuyoutPriceGold",
|
||||
"BuyoutPriceSilver",
|
||||
"BuyoutPriceCopper"
|
||||
}
|
||||
|
||||
for _, editbox in pairs(editboxs) do
|
||||
S:HandleEditBox(_G[editbox])
|
||||
_G[editbox]:SetTextInsets(1, 1, -1, 1)
|
||||
end
|
||||
|
||||
BrowseBidPrice:SetPoint("BOTTOM", -15, 18)
|
||||
BrowseBidText:SetPoint("BOTTOMRIGHT", AuctionFrameBrowse, "BOTTOM", -116, 21)
|
||||
|
||||
BrowseMinLevel:SetWidth(32)
|
||||
|
||||
BrowseLevelHyphen:SetPoint("LEFT", BrowseMinLevel, "RIGHT", -7, 1)
|
||||
|
||||
BrowseMaxLevel:SetPoint("LEFT", BrowseMinLevel, "RIGHT", 8, 0)
|
||||
BrowseMaxLevel:SetWidth(32)
|
||||
BrowseLevelText:SetPoint("BOTTOMLEFT", AuctionFrameBrowse, "TOPLEFT", 195, -48)
|
||||
|
||||
BrowseName:SetWidth(164)
|
||||
BrowseName:SetPoint("TOPLEFT", AuctionFrameBrowse, "TOPLEFT", 20, -54)
|
||||
BrowseNameText:SetPoint("TOPLEFT", BrowseName, "TOPLEFT", 0, 16)
|
||||
|
||||
S:HandleCheckBox(IsUsableCheckButton)
|
||||
IsUsableCheckButton:ClearAllPoints()
|
||||
IsUsableCheckButton:SetPoint("RIGHT", BrowseIsUsableText, "LEFT", 2, 0)
|
||||
BrowseIsUsableText:SetPoint("TOPLEFT", 440, -40)
|
||||
|
||||
S:HandleCheckBox(ShowOnPlayerCheckButton)
|
||||
ShowOnPlayerCheckButton:ClearAllPoints()
|
||||
ShowOnPlayerCheckButton:SetPoint("RIGHT", BrowseShowOnCharacterText, "LEFT", 2, 0)
|
||||
|
||||
BrowseShowOnCharacterText:SetPoint("TOPLEFT", 440, -60)
|
||||
|
||||
for i = 1, NUM_BROWSE_TO_DISPLAY do
|
||||
local button = _G["BrowseButton"..i]
|
||||
local icon = _G["BrowseButton"..i.."Item"]
|
||||
local name = _G["BrowseButton"..i.."Name"]
|
||||
local texture = _G["BrowseButton"..i.."ItemIconTexture"]
|
||||
|
||||
if texture then
|
||||
texture:SetTexCoord(unpack(E.TexCoords))
|
||||
E:SetInside(texture)
|
||||
end
|
||||
|
||||
if icon then
|
||||
E:StyleButton(icon)
|
||||
icon:GetNormalTexture():SetTexture("")
|
||||
E:SetTemplate(icon, "Default")
|
||||
|
||||
hooksecurefunc(name, "SetVertexColor", function(_, r, g, b)
|
||||
if r and g and b then
|
||||
icon:SetBackdropBorderColor(r, g, b)
|
||||
end
|
||||
end)
|
||||
hooksecurefunc(name, "Hide", function(_, r, g, b)
|
||||
icon:SetBackdropBorderColor(unpack(E["media"].bordercolor))
|
||||
end)
|
||||
end
|
||||
|
||||
E:StripTextures(button)
|
||||
E:StyleButton(button, false, true)
|
||||
_G["BrowseButton"..i.."Highlight"] = button:GetHighlightTexture()
|
||||
button:GetHighlightTexture():ClearAllPoints()
|
||||
button:GetHighlightTexture():SetPoint("TOPLEFT", icon, "TOPRIGHT", 2, 0)
|
||||
button:GetHighlightTexture():SetPoint("BOTTOMRIGHT", button, "BOTTOMRIGHT", -2, 5)
|
||||
-- button:GetPushedTexture():SetAllPoints(button:GetHighlightTexture())
|
||||
end
|
||||
|
||||
for i = 1, NUM_AUCTIONS_TO_DISPLAY do
|
||||
local button = _G["AuctionsButton"..i]
|
||||
local icon = _G["AuctionsButton"..i.."Item"]
|
||||
local name = _G["AuctionsButton"..i.."Name"]
|
||||
local texture = _G["AuctionsButton"..i.."ItemIconTexture"]
|
||||
|
||||
if texture then
|
||||
texture:SetTexCoord(unpack(E.TexCoords))
|
||||
E:SetInside(texture)
|
||||
end
|
||||
|
||||
if icon then
|
||||
E:StyleButton(icon)
|
||||
icon:GetNormalTexture():SetTexture("")
|
||||
E:SetTemplate(icon, "Default")
|
||||
|
||||
hooksecurefunc(name, "SetVertexColor", function(_, r, g, b)
|
||||
if r and g and b then
|
||||
icon:SetBackdropBorderColor(r, g, b)
|
||||
end
|
||||
end)
|
||||
hooksecurefunc(name, "Hide", function(_, r, g, b)
|
||||
icon:SetBackdropBorderColor(unpack(E["media"].bordercolor))
|
||||
end)
|
||||
end
|
||||
|
||||
E:StripTextures(button)
|
||||
E:StyleButton(button, false, true)
|
||||
_G["AuctionsButton"..i.."Highlight"] = button:GetHighlightTexture()
|
||||
button:GetHighlightTexture():ClearAllPoints()
|
||||
button:GetHighlightTexture():SetPoint("TOPLEFT", icon, "TOPRIGHT", 2, 0)
|
||||
button:GetHighlightTexture():SetPoint("BOTTOMRIGHT", button, "BOTTOMRIGHT", -2, 5)
|
||||
-- button:GetPushedTexture():SetAllPoints(button:GetHighlightTexture())
|
||||
end
|
||||
|
||||
for i = 1, NUM_BIDS_TO_DISPLAY do
|
||||
local button = _G["BidButton"..i]
|
||||
local icon = _G["BidButton"..i.."Item"]
|
||||
local name = _G["BidButton"..i.."Name"]
|
||||
local texture = _G["BidButton"..i.."ItemIconTexture"]
|
||||
|
||||
if texture then
|
||||
texture:SetTexCoord(unpack(E.TexCoords))
|
||||
E:SetInside(texture)
|
||||
end
|
||||
|
||||
if icon then
|
||||
E:StyleButton(icon)
|
||||
icon:GetNormalTexture():SetTexture("")
|
||||
E:SetTemplate(icon, "Default")
|
||||
|
||||
hooksecurefunc(name, "SetVertexColor", function(_, r, g, b)
|
||||
if r and g and b then
|
||||
icon:SetBackdropBorderColor(r, g, b)
|
||||
end
|
||||
end)
|
||||
hooksecurefunc(name, "Hide", function(_, r, g, b)
|
||||
icon:SetBackdropBorderColor(unpack(E["media"].bordercolor))
|
||||
end)
|
||||
end
|
||||
|
||||
E:StripTextures(button)
|
||||
E:StyleButton(button, false, true)
|
||||
_G["BidButton"..i.."Highlight"] = button:GetHighlightTexture()
|
||||
button:GetHighlightTexture():ClearAllPoints()
|
||||
button:GetHighlightTexture():SetPoint("TOPLEFT", icon, "TOPRIGHT", 2, 0)
|
||||
button:GetHighlightTexture():SetPoint("BOTTOMRIGHT", button, "BOTTOMRIGHT", -2, 5)
|
||||
-- button:GetPushedTexture():SetAllPoints(button:GetHighlightTexture())
|
||||
end
|
||||
|
||||
--Custom Backdrops
|
||||
AuctionFrameBrowse.bg1 = CreateFrame("Frame", nil, AuctionFrameBrowse)
|
||||
E:SetTemplate(AuctionFrameBrowse.bg1, "Default")
|
||||
AuctionFrameBrowse.bg1:SetPoint("TOPLEFT", 20, -103)
|
||||
AuctionFrameBrowse.bg1:SetPoint("BOTTOMRIGHT", -575, 40)
|
||||
BrowseNoResultsText:SetParent(AuctionFrameBrowse.bg1)
|
||||
BrowseSearchCountText:SetParent(AuctionFrameBrowse.bg1)
|
||||
AuctionFrameBrowse.bg1:SetFrameLevel(AuctionFrameBrowse.bg1:GetFrameLevel() - 1)
|
||||
|
||||
AuctionFrameBrowse.bg2 = CreateFrame("Frame", nil, AuctionFrameBrowse)
|
||||
E:SetTemplate(AuctionFrameBrowse.bg2, "Default")
|
||||
AuctionFrameBrowse.bg2:SetPoint("TOPLEFT", AuctionFrameBrowse.bg1, "TOPRIGHT", 4, 0)
|
||||
AuctionFrameBrowse.bg2:SetPoint("BOTTOMRIGHT", AuctionFrame, "BOTTOMRIGHT", -8, 40)
|
||||
AuctionFrameBrowse.bg2:SetFrameLevel(AuctionFrameBrowse.bg2:GetFrameLevel() - 1)
|
||||
|
||||
AuctionFrameBid.bg = CreateFrame("Frame", nil, AuctionFrameBid)
|
||||
E:SetTemplate(AuctionFrameBid.bg, "Default")
|
||||
AuctionFrameBid.bg:SetPoint("TOPLEFT", 20, -72)
|
||||
AuctionFrameBid.bg:SetPoint("BOTTOMRIGHT", 66, 40)
|
||||
AuctionFrameBid.bg:SetFrameLevel(AuctionFrameBid.bg:GetFrameLevel() - 1)
|
||||
|
||||
AuctionFrameAuctions.bg1 = CreateFrame("Frame", nil, AuctionFrameAuctions)
|
||||
E:SetTemplate(AuctionFrameAuctions.bg1, "Default")
|
||||
AuctionFrameAuctions.bg1:SetPoint("TOPLEFT", 15, -72)
|
||||
AuctionFrameAuctions.bg1:SetPoint("BOTTOMRIGHT", -545, 40)
|
||||
AuctionFrameAuctions.bg1:SetFrameLevel(AuctionFrameAuctions.bg1:GetFrameLevel() - 1)
|
||||
|
||||
AuctionFrameAuctions.bg2 = CreateFrame("Frame", nil, AuctionFrameAuctions)
|
||||
E:SetTemplate(AuctionFrameAuctions.bg2, "Default")
|
||||
AuctionFrameAuctions.bg2:SetPoint("TOPLEFT", AuctionFrameAuctions.bg1, "TOPRIGHT", 3, 0)
|
||||
AuctionFrameAuctions.bg2:SetPoint("BOTTOMRIGHT", AuctionFrame, -8, 40)
|
||||
AuctionFrameAuctions.bg2:SetFrameLevel(AuctionFrameAuctions.bg2:GetFrameLevel() - 1)
|
||||
end
|
||||
|
||||
S:AddCallbackForAddon("Blizzard_AuctionUI", "AuctionHouse", LoadSkin)
|
||||
@@ -0,0 +1,80 @@
|
||||
local E, L, V, P, G = unpack(ElvUI); --Import: Engine, Locales, PrivateDB, ProfileDB, GlobalDB
|
||||
local S = E:GetModule("Skins");
|
||||
|
||||
--Cache global variables
|
||||
--Lua functions
|
||||
local _G = _G
|
||||
local split = string.split
|
||||
--WoW API / Variables
|
||||
local hooksecurefunc = hooksecurefunc
|
||||
|
||||
local function LoadSkin()
|
||||
if E.private.skins.blizzard.enable ~= true or E.private.skins.blizzard.bgscore ~= true then return end
|
||||
|
||||
E:CreateBackdrop(WorldStateScoreFrame, "Transparent")
|
||||
WorldStateScoreFrame.backdrop:SetPoint("TOPLEFT", 10, -15)
|
||||
WorldStateScoreFrame.backdrop:SetPoint("BOTTOMRIGHT", -113, 67)
|
||||
|
||||
E:StripTextures(WorldStateScoreFrame)
|
||||
|
||||
E:StripTextures(WorldStateScoreScrollFrame)
|
||||
S:HandleScrollBar(WorldStateScoreScrollFrameScrollBar)
|
||||
|
||||
local tab
|
||||
for i = 1, 3 do
|
||||
tab = _G["WorldStateScoreFrameTab"..i]
|
||||
|
||||
S:HandleTab(tab)
|
||||
|
||||
_G["WorldStateScoreFrameTab"..i.."Text"]:SetPoint("CENTER", 0, 2)
|
||||
end
|
||||
|
||||
S:HandleButton(WorldStateScoreFrameLeaveButton)
|
||||
S:HandleCloseButton(WorldStateScoreFrameCloseButton)
|
||||
|
||||
E:StyleButton(WorldStateScoreFrameKB)
|
||||
E:StyleButton(WorldStateScoreFrameDeaths)
|
||||
E:StyleButton(WorldStateScoreFrameHK)
|
||||
E:StyleButton(WorldStateScoreFrameHonorGained)
|
||||
E:StyleButton(WorldStateScoreFrameName)
|
||||
|
||||
for i = 1, 5 do
|
||||
E:StyleButton(_G["WorldStateScoreColumn"..i])
|
||||
end
|
||||
|
||||
hooksecurefunc("WorldStateScoreFrame_Update", function()
|
||||
local offset = FauxScrollFrame_GetOffset(WorldStateScoreScrollFrame)
|
||||
|
||||
for i = 1, MAX_WORLDSTATE_SCORE_BUTTONS do
|
||||
local index = offset + i
|
||||
local name, _, _, _, _, faction = GetBattlefieldScore(index)
|
||||
if name then
|
||||
local n, r = split("-", name, 2)
|
||||
local myName = UnitName("player")
|
||||
|
||||
if name == myName then
|
||||
n = "> "..n.." <"
|
||||
end
|
||||
|
||||
if r then
|
||||
local color
|
||||
|
||||
if faction == 1 then
|
||||
color = "|cff00adf0"
|
||||
else
|
||||
color = "|cffff1919"
|
||||
end
|
||||
r = color..r.."|r"
|
||||
n = n.."|cffffffff - |r"..r
|
||||
end
|
||||
|
||||
local classTextColor = CUSTOM_CLASS_COLORS and CUSTOM_CLASS_COLORS[classToken] or RAID_CLASS_COLORS[classToken]
|
||||
|
||||
_G["WorldStateScoreButton"..i.."NameText"]:SetText(n)
|
||||
_G["WorldStateScoreButton"..i.."NameText"]:SetTextColor(classTextColor.r, classTextColor.g, classTextColor.b)
|
||||
end
|
||||
end
|
||||
end)
|
||||
end
|
||||
|
||||
S:AddCallback("WorldStateScore", LoadSkin)
|
||||
@@ -0,0 +1,149 @@
|
||||
local E, L, V, P, G = unpack(ElvUI); --Import: Engine, Locales, PrivateDB, ProfileDB, GlobalDB
|
||||
local S = E:GetModule("Skins");
|
||||
|
||||
--Cache global variables
|
||||
--Lua functions
|
||||
local _G = _G
|
||||
local unpack = unpack
|
||||
local match = string.match
|
||||
--WoW API / Variables
|
||||
local GetItemQualityColor = GetItemQualityColor
|
||||
local GetContainerItemLink = GetContainerItemLink
|
||||
local BANK_CONTAINER = BANK_CONTAINER
|
||||
local NUM_CONTAINER_FRAMES = NUM_CONTAINER_FRAMES
|
||||
|
||||
function S:ContainerFrame_Update()
|
||||
local id = this:GetID()
|
||||
local name = this:GetName()
|
||||
local _, itemButton, itemLink, quality
|
||||
|
||||
for i = 1, this.size, 1 do
|
||||
itemButton = _G[name.."Item"..i]
|
||||
|
||||
itemLink = GetContainerItemLink(id, itemButton:GetID())
|
||||
if itemLink then
|
||||
_, _, quality = GetItemInfo(match(itemLink, "item:(%d+)"))
|
||||
if quality then
|
||||
itemButton:SetBackdropBorderColor(GetItemQualityColor(quality))
|
||||
else
|
||||
itemButton:SetBackdropBorderColor(unpack(E["media"].bordercolor))
|
||||
end
|
||||
else
|
||||
itemButton:SetBackdropBorderColor(unpack(E["media"].bordercolor))
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
function S:BankFrameItemButton_OnUpdate()
|
||||
if not this.isBag then
|
||||
local itemLink = GetContainerItemLink(BANK_CONTAINER, this:GetID())
|
||||
if itemLink then
|
||||
local _, _, quality = GetItemInfo(match(itemLink, "item:(%d+)"))
|
||||
if quality then
|
||||
this:SetBackdropBorderColor(GetItemQualityColor(quality))
|
||||
else
|
||||
this:SetBackdropBorderColor(unpack(E["media"].bordercolor))
|
||||
end
|
||||
else
|
||||
this:SetBackdropBorderColor(unpack(E["media"].bordercolor))
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
local function LoadSkin()
|
||||
if not E.private.skins.blizzard.enable and E.private.skins.blizzard.bags and not E.private.bags.enable then return end
|
||||
|
||||
-- ContainerFrame
|
||||
local containerFrame, containerFrameClose
|
||||
for i = 1, NUM_CONTAINER_FRAMES, 1 do
|
||||
containerFrame = _G["ContainerFrame"..i]
|
||||
containerFrameClose = _G["ContainerFrame"..i.."CloseButton"]
|
||||
|
||||
E:StripTextures(containerFrame, true)
|
||||
E:CreateBackdrop(containerFrame, "Transparent")
|
||||
containerFrame.backdrop:SetPoint("TOPLEFT", 9, -4)
|
||||
containerFrame.backdrop:SetPoint("BOTTOMRIGHT", -4, 2)
|
||||
|
||||
S:HandleCloseButton(containerFrameClose)
|
||||
|
||||
S:SecureHookScript(containerFrame, "OnShow", "ContainerFrame_Update")
|
||||
|
||||
local itemButton, itemButtonIcon
|
||||
for k = 1, MAX_CONTAINER_ITEMS, 1 do
|
||||
itemButton = _G["ContainerFrame"..i.."Item"..k]
|
||||
itemButtonIcon = _G["ContainerFrame"..i.."Item"..k.."IconTexture"]
|
||||
itemButtonCooldown = _G["ContainerFrame"..i.."Item"..k.."Cooldown"]
|
||||
|
||||
itemButton:SetNormalTexture("")
|
||||
|
||||
E:SetTemplate(itemButton, "Default", true)
|
||||
E:StyleButton(itemButton)
|
||||
|
||||
E:SetInside(itemButtonIcon)
|
||||
itemButtonIcon:SetTexCoord(unpack(E.TexCoords))
|
||||
|
||||
if itemButtonCooldown then
|
||||
E:RegisterCooldown(itemButtonCooldown)
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
S:SecureHook("ContainerFrame_Update")
|
||||
|
||||
-- BankFrame
|
||||
E:CreateBackdrop(BankFrame, "Transparent")
|
||||
BankFrame.backdrop:SetPoint("TOPLEFT", 10, -11)
|
||||
BankFrame.backdrop:SetPoint("BOTTOMRIGHT", -26, 93)
|
||||
|
||||
E:StripTextures(BankFrame, true)
|
||||
|
||||
S:HandleCloseButton(BankCloseButton)
|
||||
|
||||
local button, buttonIcon
|
||||
for i = 1, NUM_BANKGENERIC_SLOTS, 1 do
|
||||
button = _G["BankFrameItem"..i]
|
||||
buttonIcon = _G["BankFrameItem"..i.."IconTexture"]
|
||||
|
||||
button:SetNormalTexture("")
|
||||
|
||||
E:SetTemplate(button, "Default", true)
|
||||
E:StyleButton(button)
|
||||
|
||||
E:SetInside(buttonIcon)
|
||||
buttonIcon:SetTexCoord(unpack(E.TexCoords))
|
||||
end
|
||||
|
||||
BankFrame.itemBackdrop = CreateFrame("Frame", "BankFrameItemBackdrop", BankFrame)
|
||||
E:SetTemplate(BankFrame.itemBackdrop, "Default")
|
||||
BankFrame.itemBackdrop:SetPoint("TOPLEFT", BankFrameItem1, "TOPLEFT", -6, 6)
|
||||
BankFrame.itemBackdrop:SetPoint("BOTTOMRIGHT", BankFrameItem24, "BOTTOMRIGHT", 6, -6)
|
||||
BankFrame.itemBackdrop:SetFrameLevel(BankFrame:GetFrameLevel())
|
||||
|
||||
for i = 1, NUM_BANKBAGSLOTS, 1 do
|
||||
button = _G["BankFrameBag"..i]
|
||||
buttonIcon = _G["BankFrameBag"..i.."IconTexture"]
|
||||
|
||||
button:SetNormalTexture("")
|
||||
|
||||
E:SetTemplate(button, "Default", true)
|
||||
E:StyleButton(button)
|
||||
|
||||
E:SetInside(buttonIcon)
|
||||
buttonIcon:SetTexCoord(unpack(E.TexCoords))
|
||||
|
||||
E:SetInside(_G["BankFrameBag"..i.."HighlightFrameTexture"])
|
||||
_G["BankFrameBag"..i.."HighlightFrameTexture"]:SetTexture(unpack(E["media"].rgbvaluecolor), 0.3)
|
||||
end
|
||||
|
||||
BankFrame.bagBackdrop = CreateFrame("Frame", "BankFrameBagBackdrop", BankFrame)
|
||||
E:SetTemplate(BankFrame.bagBackdrop, "Default")
|
||||
BankFrame.bagBackdrop:SetPoint("TOPLEFT", BankFrameBag1, "TOPLEFT", -6, 6)
|
||||
BankFrame.bagBackdrop:SetPoint("BOTTOMRIGHT", BankFrameBag6, "BOTTOMRIGHT", 6, -6)
|
||||
BankFrame.bagBackdrop:SetFrameLevel(BankFrame:GetFrameLevel())
|
||||
|
||||
S:HandleButton(BankFramePurchaseButton)
|
||||
|
||||
S:SecureHook("BankFrameItemButton_OnUpdate")
|
||||
end
|
||||
|
||||
S:AddCallback("SkinBags", LoadSkin)
|
||||
@@ -0,0 +1,30 @@
|
||||
local E, L, V, P, G = unpack(ElvUI); --Import: Engine, Locales, PrivateDB, ProfileDB, GlobalDB
|
||||
local S = E:GetModule("Skins");
|
||||
|
||||
--Cache global variables
|
||||
--Lua functions
|
||||
|
||||
--WoW API / Variables
|
||||
|
||||
local function LoadSkin()
|
||||
if E.private.skins.blizzard.enable ~= true or E.private.skins.blizzard.battlefield ~= true then return end
|
||||
|
||||
E:StripTextures(BattlefieldFrame)
|
||||
|
||||
E:CreateBackdrop(BattlefieldFrame, "Transparent")
|
||||
BattlefieldFrame.backdrop:SetPoint("TOPLEFT", 11, -12)
|
||||
BattlefieldFrame.backdrop:SetPoint("BOTTOMRIGHT", -34, 74)
|
||||
|
||||
E:StripTextures(BattlefieldListScrollFrame)
|
||||
S:HandleScrollBar(BattlefieldListScrollFrameScrollBar)
|
||||
|
||||
BattlefieldFrameZoneDescription:SetTextColor(1, 1, 1)
|
||||
|
||||
S:HandleButton(BattlefieldFrameCancelButton)
|
||||
S:HandleButton(BattlefieldFrameJoinButton)
|
||||
S:HandleButton(BattlefieldFrameGroupJoinButton)
|
||||
|
||||
S:HandleCloseButton(BattlefieldFrameCloseButton)
|
||||
end
|
||||
|
||||
S:AddCallback("Battlefield", LoadSkin)
|
||||
@@ -0,0 +1,39 @@
|
||||
local E, L, V, P, G = unpack(ElvUI); --Import: Engine, Locales, PrivateDB, ProfileDB, GlobalDB
|
||||
local S = E:GetModule("Skins");
|
||||
|
||||
--Cache global variables
|
||||
--Lua functions
|
||||
local _G = _G
|
||||
--WoW API / Variables
|
||||
|
||||
local function LoadSkin()
|
||||
if E.private.skins.blizzard.enable ~= true or E.private.skins.blizzard.binding ~= true then return end
|
||||
|
||||
E:StripTextures(KeyBindingFrame)
|
||||
E:CreateBackdrop(KeyBindingFrame, "Transparent")
|
||||
KeyBindingFrame.backdrop:SetPoint("TOPLEFT", 2, 0)
|
||||
KeyBindingFrame.backdrop:SetPoint("BOTTOMRIGHT", -42, 12)
|
||||
|
||||
local bindingKey1, bindingKey2
|
||||
for i = 1, KEY_BINDINGS_DISPLAYED do
|
||||
bindingKey1 = _G["KeyBindingFrameBinding"..i.."Key1Button"]
|
||||
bindingKey2 = _G["KeyBindingFrameBinding"..i.."Key2Button"]
|
||||
|
||||
S:HandleButton(bindingKey1)
|
||||
S:HandleButton(bindingKey2)
|
||||
bindingKey2:SetPoint("LEFT", bindingKey1, "RIGHT", 1, 0)
|
||||
end
|
||||
|
||||
S:HandleScrollBar(KeyBindingFrameScrollFrameScrollBar)
|
||||
|
||||
S:HandleCheckBox(KeyBindingFrameCharacterButton)
|
||||
|
||||
S:HandleButton(KeyBindingFrameDefaultButton)
|
||||
S:HandleButton(KeyBindingFrameCancelButton)
|
||||
S:HandleButton(KeyBindingFrameOkayButton)
|
||||
KeyBindingFrameOkayButton:SetPoint("RIGHT", KeyBindingFrameCancelButton, "LEFT", -3, 0)
|
||||
S:HandleButton(KeyBindingFrameUnbindButton)
|
||||
KeyBindingFrameUnbindButton:SetPoint("RIGHT", KeyBindingFrameOkayButton, "LEFT", -3, 0)
|
||||
end
|
||||
|
||||
S:AddCallbackForAddon("Blizzard_BindingUI", "Binding", LoadSkin)
|
||||
@@ -0,0 +1,333 @@
|
||||
local E, L, V, P, G = unpack(ElvUI); --Import: Engine, Locales, PrivateDB, ProfileDB, GlobalDB
|
||||
local S = E:GetModule("Skins");
|
||||
|
||||
--Cache global variables
|
||||
--Lua functions
|
||||
local _G = _G
|
||||
local unpack = unpack
|
||||
local pairs = pairs
|
||||
local find, getn = string.find, table.getn
|
||||
--WoW API / Variables
|
||||
local GetInventoryItemTexture = GetInventoryItemTexture
|
||||
local GetInventoryItemQuality = GetInventoryItemQuality
|
||||
local GetNumFactions = GetNumFactions
|
||||
local FauxScrollFrame_GetOffset = FauxScrollFrame_GetOffset
|
||||
local NUM_FACTIONS_DISPLAYED = NUM_FACTIONS_DISPLAYED
|
||||
local CHARACTERFRAME_SUBFRAMES = CHARACTERFRAME_SUBFRAMES
|
||||
|
||||
local function LoadSkin()
|
||||
if E.private.skins.blizzard.enable ~= true or E.private.skins.blizzard.character ~= true then return end
|
||||
|
||||
-- Character Frame
|
||||
E:StripTextures(CharacterFrame, true)
|
||||
|
||||
E:CreateBackdrop(CharacterFrame, "Transparent")
|
||||
CharacterFrame.backdrop:SetPoint("TOPLEFT", 11, -12)
|
||||
CharacterFrame.backdrop:SetPoint("BOTTOMRIGHT", -32, 76)
|
||||
|
||||
S:HandleCloseButton(CharacterFrameCloseButton)
|
||||
|
||||
for i = 1, getn(CHARACTERFRAME_SUBFRAMES) do
|
||||
local tab = _G["CharacterFrameTab"..i]
|
||||
S:HandleTab(tab)
|
||||
end
|
||||
|
||||
E:StripTextures(PaperDollFrame)
|
||||
|
||||
S:HandleRotateButton(CharacterModelFrameRotateLeftButton)
|
||||
CharacterModelFrameRotateLeftButton:SetPoint("TOPLEFT", 3, -3)
|
||||
S:HandleRotateButton(CharacterModelFrameRotateRightButton)
|
||||
CharacterModelFrameRotateRightButton:SetPoint("TOPLEFT", CharacterModelFrameRotateLeftButton, "TOPRIGHT", 3, 0)
|
||||
|
||||
E:StripTextures(CharacterAttributesFrame)
|
||||
|
||||
local function HandleResistanceFrame(frameName)
|
||||
for i = 1, 5 do
|
||||
local frame = _G[frameName..i]
|
||||
frame:SetWidth(24)
|
||||
frame:SetHeight(24)
|
||||
|
||||
local icon, text = _G[frameName..i]:GetRegions()
|
||||
E:SetInside(icon)
|
||||
icon:SetDrawLayer("ARTWORK")
|
||||
text:SetDrawLayer("OVERLAY")
|
||||
|
||||
E:SetTemplate(frame, "Default")
|
||||
|
||||
if i ~= 1 then
|
||||
frame:ClearAllPoints()
|
||||
frame:SetPoint("TOP", _G[frameName..i-1], "BOTTOM", 0, -(E.Border + E.Spacing))
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
HandleResistanceFrame("MagicResFrame")
|
||||
|
||||
MagicResFrame1:GetRegions():SetTexCoord(0.21875, 0.8125, 0.25, 0.32421875) --Arcane
|
||||
MagicResFrame2:GetRegions():SetTexCoord(0.21875, 0.8125, 0.0234375, 0.09765625) --Fire
|
||||
MagicResFrame3:GetRegions():SetTexCoord(0.21875, 0.8125, 0.13671875, 0.2109375) --Nature
|
||||
MagicResFrame4:GetRegions():SetTexCoord(0.21875, 0.8125, 0.36328125, 0.4375) --Frost
|
||||
MagicResFrame5:GetRegions():SetTexCoord(0.21875, 0.8125, 0.4765625, 0.55078125) --Shadow
|
||||
|
||||
local slots = {"HeadSlot", "NeckSlot", "ShoulderSlot", "BackSlot", "ChestSlot", "ShirtSlot", "TabardSlot", "WristSlot",
|
||||
"HandsSlot", "WaistSlot", "LegsSlot", "FeetSlot", "Finger0Slot", "Finger1Slot", "Trinket0Slot", "Trinket1Slot",
|
||||
"MainHandSlot", "SecondaryHandSlot", "RangedSlot", "AmmoSlot"
|
||||
}
|
||||
|
||||
for _, slot in pairs(slots) do
|
||||
local icon = _G["Character"..slot.."IconTexture"]
|
||||
local cooldown = _G["Character"..slot.."Cooldown"]
|
||||
|
||||
slot = _G["Character"..slot]
|
||||
E:StripTextures(slot)
|
||||
E:StyleButton(slot, false)
|
||||
E:SetTemplate(slot, "Default", true, true)
|
||||
|
||||
icon:SetTexCoord(unpack(E.TexCoords))
|
||||
E:SetInside(icon)
|
||||
|
||||
slot:SetFrameLevel(PaperDollFrame:GetFrameLevel() + 2)
|
||||
|
||||
if cooldown then
|
||||
E:RegisterCooldown(cooldown)
|
||||
end
|
||||
end
|
||||
|
||||
hooksecurefunc("PaperDollItemSlotButton_Update", function(cooldownOnly)
|
||||
if cooldownOnly then return end
|
||||
|
||||
local textureName = GetInventoryItemTexture("player", this:GetID())
|
||||
if textureName then
|
||||
local rarity = GetInventoryItemQuality("player", this:GetID())
|
||||
this:SetBackdropBorderColor(GetItemQualityColor(rarity))
|
||||
else
|
||||
this:SetBackdropBorderColor(unpack(E["media"].bordercolor))
|
||||
end
|
||||
end)
|
||||
|
||||
E:StripTextures(ReputationFrame)
|
||||
|
||||
for i = 1, NUM_FACTIONS_DISPLAYED do
|
||||
local factionBar = _G["ReputationBar"..i]
|
||||
local factionHeader = _G["ReputationHeader"..i]
|
||||
local factionName = _G["ReputationBar"..i.."FactionName"]
|
||||
local factionAtWarCheck = _G["ReputationBar"..i.."AtWarCheck"]
|
||||
|
||||
E:StripTextures(factionBar)
|
||||
E:CreateBackdrop(factionBar, "Default")
|
||||
factionBar:SetStatusBarTexture(E.media.normTex)
|
||||
factionBar:SetWidth(108)
|
||||
factionBar:SetHeight(13)
|
||||
E:RegisterStatusBar(factionBar)
|
||||
|
||||
if i == 1 then
|
||||
factionBar:SetPoint("TOPLEFT", 190, -86)
|
||||
end
|
||||
|
||||
factionName:SetPoint("LEFT", factionBar, "LEFT", -150, 0)
|
||||
factionName:SetWidth(140)
|
||||
factionName.SetWidth = E.noop
|
||||
|
||||
E:StripTextures(factionAtWarCheck)
|
||||
factionAtWarCheck:SetPoint("LEFT", factionBar, "RIGHT", 0, 0)
|
||||
|
||||
factionAtWarCheck.Icon = factionAtWarCheck:CreateTexture(nil, "OVERLAY")
|
||||
factionAtWarCheck.Icon:SetPoint("LEFT", 6, -8)
|
||||
factionAtWarCheck.Icon:SetWidth(32)
|
||||
factionAtWarCheck.Icon:SetHeight(32)
|
||||
factionAtWarCheck.Icon:SetTexture("Interface\\Buttons\\UI-CheckBox-SwordCheck")
|
||||
|
||||
E:StripTextures(factionHeader)
|
||||
factionHeader:SetNormalTexture(nil)
|
||||
factionHeader.SetNormalTexture = E.noop
|
||||
factionHeader:SetPoint("TOPLEFT", factionBar, "TOPLEFT", -175, 0)
|
||||
|
||||
factionHeader.Text = factionHeader:CreateFontString(nil, "OVERLAY")
|
||||
E:FontTemplate(factionHeader.Text, nil, 22)
|
||||
factionHeader.Text:SetPoint("LEFT", 3, 0)
|
||||
factionHeader.Text:SetText("+")
|
||||
end
|
||||
|
||||
|
||||
-- PetPaperDollFrame
|
||||
E:StripTextures(PetPaperDollFrame)
|
||||
|
||||
S:HandleButton(PetPaperDollCloseButton)
|
||||
|
||||
S:HandleRotateButton(PetModelFrameRotateLeftButton)
|
||||
PetModelFrameRotateLeftButton:ClearAllPoints()
|
||||
PetModelFrameRotateLeftButton:SetPoint("TOPLEFT", 3, -3)
|
||||
S:HandleRotateButton(PetModelFrameRotateRightButton)
|
||||
PetModelFrameRotateRightButton:ClearAllPoints()
|
||||
PetModelFrameRotateRightButton:SetPoint("TOPLEFT", PetModelFrameRotateLeftButton, "TOPRIGHT", 3, 0)
|
||||
|
||||
E:StripTextures(PetAttributesFrame)
|
||||
|
||||
E:CreateBackdrop(PetResistanceFrame, "Default")
|
||||
E:SetOutside(PetResistanceFrame.backdrop, PetMagicResFrame1, nil, nil, PetMagicResFrame5)
|
||||
|
||||
for i = 1, 5 do
|
||||
local frame = _G["PetMagicResFrame"..i]
|
||||
frame:SetWidth(24)
|
||||
frame:SetHeight(24)
|
||||
end
|
||||
|
||||
PetMagicResFrame1:GetRegions():SetTexCoord(0.21875, 0.78125, 0.25, 0.3203125)
|
||||
PetMagicResFrame2:GetRegions():SetTexCoord(0.21875, 0.78125, 0.0234375, 0.09375)
|
||||
PetMagicResFrame3:GetRegions():SetTexCoord(0.21875, 0.78125, 0.13671875, 0.20703125)
|
||||
PetMagicResFrame4:GetRegions():SetTexCoord(0.21875, 0.78125, 0.36328125, 0.43359375)
|
||||
PetMagicResFrame5:GetRegions():SetTexCoord(0.21875, 0.78125, 0.4765625, 0.546875)
|
||||
|
||||
E:StripTextures(PetPaperDollFrameExpBar)
|
||||
PetPaperDollFrameExpBar:SetStatusBarTexture(E["media"].normTex)
|
||||
E:RegisterStatusBar(PetPaperDollFrameExpBar)
|
||||
E:CreateBackdrop(PetPaperDollFrameExpBar, "Default")
|
||||
|
||||
local function updHappiness()
|
||||
local happiness = GetPetHappiness()
|
||||
local _, isHunterPet = HasPetUI()
|
||||
if not happiness or not isHunterPet then
|
||||
return
|
||||
end
|
||||
local texture = this:GetRegions()
|
||||
if happiness == 1 then
|
||||
texture:SetTexCoord(0.41, 0.53, 0.06, 0.30)
|
||||
elseif happiness == 2 then
|
||||
texture:SetTexCoord(0.22, 0.345, 0.06, 0.30)
|
||||
elseif happiness == 3 then
|
||||
texture:SetTexCoord(0.04, 0.15, 0.06, 0.30)
|
||||
end
|
||||
end
|
||||
|
||||
PetPaperDollPetInfo:SetPoint("TOPLEFT", PetModelFrameRotateLeftButton, "BOTTOMLEFT", 9, -3)
|
||||
PetPaperDollPetInfo:GetRegions():SetTexCoord(0.04, 0.15, 0.06, 0.30)
|
||||
PetPaperDollPetInfo:SetFrameLevel(PetModelFrame:GetFrameLevel() + 2)
|
||||
E:CreateBackdrop(PetPaperDollPetInfo, "Default")
|
||||
PetPaperDollPetInfo:SetWidth(24)
|
||||
PetPaperDollPetInfo:SetHeight(24)
|
||||
|
||||
PetPaperDollPetInfo:RegisterEvent("UNIT_HAPPINESS")
|
||||
PetPaperDollPetInfo:SetScript("OnEvent", updHappiness)
|
||||
PetPaperDollPetInfo:SetScript("OnShow", updHappiness)
|
||||
|
||||
|
||||
-- Reputation Frame
|
||||
hooksecurefunc("ReputationFrame_Update", function()
|
||||
local numFactions = GetNumFactions()
|
||||
local factionIndex, factionHeader
|
||||
local factionOffset = FauxScrollFrame_GetOffset(ReputationListScrollFrame)
|
||||
for i = 1, NUM_FACTIONS_DISPLAYED, 1 do
|
||||
factionHeader = _G["ReputationHeader"..i]
|
||||
factionIndex = factionOffset + i
|
||||
if factionIndex <= numFactions then
|
||||
if factionHeader.isCollapsed then
|
||||
factionHeader.Text:SetText("+")
|
||||
else
|
||||
factionHeader.Text:SetText("-")
|
||||
end
|
||||
end
|
||||
end
|
||||
end)
|
||||
|
||||
E:StripTextures(ReputationListScrollFrame)
|
||||
S:HandleScrollBar(ReputationListScrollFrameScrollBar)
|
||||
|
||||
E:StripTextures(ReputationDetailFrame)
|
||||
E:SetTemplate(ReputationDetailFrame, "Transparent")
|
||||
ReputationDetailFrame:SetPoint("TOPLEFT", ReputationFrame, "TOPRIGHT", -31, -12)
|
||||
|
||||
S:HandleCloseButton(ReputationDetailCloseButton)
|
||||
ReputationDetailCloseButton:SetPoint("TOPRIGHT", 2, 2)
|
||||
|
||||
S:HandleCheckBox(ReputationDetailAtWarCheckBox)
|
||||
S:HandleCheckBox(ReputationDetailInactiveCheckBox)
|
||||
S:HandleCheckBox(ReputationDetailMainScreenCheckBox)
|
||||
|
||||
|
||||
-- Skill Frame
|
||||
E:StripTextures(SkillFrame)
|
||||
|
||||
SkillFrameExpandButtonFrame:DisableDrawLayer("BACKGROUND")
|
||||
|
||||
SkillFrameCollapseAllButton:SetPoint("LEFT", SkillFrameExpandTabLeft, "RIGHT", -40, -3)
|
||||
SkillFrameCollapseAllButton:SetNormalTexture("")
|
||||
SkillFrameCollapseAllButton.SetNormalTexture = E.noop
|
||||
SkillFrameCollapseAllButton:SetHighlightTexture(nil)
|
||||
|
||||
SkillFrameCollapseAllButton.Text = SkillFrameCollapseAllButton:CreateFontString(nil, "OVERLAY")
|
||||
E:FontTemplate(SkillFrameCollapseAllButton.Text, nil, 22)
|
||||
SkillFrameCollapseAllButton.Text:SetPoint("CENTER", -10, 0)
|
||||
SkillFrameCollapseAllButton.Text:SetText("+")
|
||||
|
||||
hooksecurefunc(SkillFrameCollapseAllButton, "SetNormalTexture", function(self, texture)
|
||||
if find(texture, "MinusButton") then
|
||||
self.Text:SetText("-")
|
||||
else
|
||||
self.Text:SetText("+")
|
||||
end
|
||||
end)
|
||||
|
||||
S:HandleButton(SkillFrameCancelButton)
|
||||
|
||||
for i = 1, SKILLS_TO_DISPLAY do
|
||||
local bar = _G["SkillRankFrame"..i]
|
||||
bar:SetStatusBarTexture(E.media.normTex)
|
||||
E:RegisterStatusBar(bar)
|
||||
E:CreateBackdrop(bar, "Default")
|
||||
|
||||
E:StripTextures(_G["SkillRankFrame"..i.."Border"])
|
||||
_G["SkillRankFrame"..i.."Background"]:SetTexture(nil)
|
||||
|
||||
local label = _G["SkillTypeLabel"..i]
|
||||
label:SetNormalTexture("")
|
||||
label.SetNormalTexture = E.noop
|
||||
label:SetHighlightTexture(nil)
|
||||
|
||||
label.Text = label:CreateFontString(nil, "OVERLAY")
|
||||
E:FontTemplate(label.Text, nil, 22)
|
||||
label.Text:SetPoint("LEFT", 3, 0)
|
||||
label.Text:SetText("+")
|
||||
|
||||
hooksecurefunc(label, "SetNormalTexture", function(self, texture)
|
||||
if find(texture, "MinusButton") then
|
||||
self.Text:SetText("-")
|
||||
else
|
||||
self.Text:SetText("+")
|
||||
end
|
||||
end)
|
||||
end
|
||||
|
||||
E:StripTextures(SkillListScrollFrame)
|
||||
S:HandleScrollBar(SkillListScrollFrameScrollBar)
|
||||
|
||||
E:StripTextures(SkillDetailScrollFrame)
|
||||
S:HandleScrollBar(SkillDetailScrollFrameScrollBar)
|
||||
|
||||
E:StripTextures(SkillDetailStatusBar)
|
||||
SkillDetailStatusBar:SetParent(SkillDetailScrollFrame)
|
||||
E:CreateBackdrop(SkillDetailStatusBar, "Default")
|
||||
SkillDetailStatusBar:SetStatusBarTexture(E.media.normTex)
|
||||
E:RegisterStatusBar(SkillDetailStatusBar)
|
||||
|
||||
E:StripTextures(SkillDetailStatusBarUnlearnButton)
|
||||
SkillDetailStatusBarUnlearnButton:SetPoint("LEFT", SkillDetailStatusBarBorder, "RIGHT", -2, -5)
|
||||
SkillDetailStatusBarUnlearnButton:SetWidth(36)
|
||||
SkillDetailStatusBarUnlearnButton:SetHeight(36)
|
||||
|
||||
SkillDetailStatusBarUnlearnButton.Icon = SkillDetailStatusBarUnlearnButton:CreateTexture(nil, "OVERLAY")
|
||||
SkillDetailStatusBarUnlearnButton.Icon:SetPoint("LEFT", 7, 5)
|
||||
SkillDetailStatusBarUnlearnButton.Icon:SetWidth(18)
|
||||
SkillDetailStatusBarUnlearnButton.Icon:SetHeight(18)
|
||||
SkillDetailStatusBarUnlearnButton.Icon:SetTexture("Interface\\Buttons\\UI-GroupLoot-Pass-Up")
|
||||
|
||||
|
||||
-- Honor Frame
|
||||
hooksecurefunc("HonorFrame_Update", function()
|
||||
E:StripTextures(HonorFrame)
|
||||
|
||||
HonorFrameProgressBar:SetStatusBarTexture(E.media.normTex)
|
||||
E:RegisterStatusBar(HonorFrameProgressBar)
|
||||
end)
|
||||
end
|
||||
|
||||
S:AddCallback("Character", LoadSkin)
|
||||
@@ -0,0 +1,165 @@
|
||||
local E, L, V, P, G = unpack(ElvUI); --Import: Engine, Locales, PrivateDB, ProfileDB, GlobalDB
|
||||
local S = E:GetModule("Skins");
|
||||
|
||||
--Cache global variables
|
||||
--Lua functions
|
||||
local _G = _G
|
||||
local unpack = unpack
|
||||
local find, match, split = string.find, string.match, string.split
|
||||
--WoW API / Variables
|
||||
local GetItemInfo = GetItemInfo
|
||||
local GetItemQualityColor = GetItemQualityColor
|
||||
local GetCraftReagentInfo = GetCraftReagentInfo
|
||||
local GetCraftItemLink = GetCraftItemLink
|
||||
local hooksecurefunc = hooksecurefunc
|
||||
|
||||
local function LoadSkin()
|
||||
if E.private.skins.blizzard.enable ~= true or not E.private.skins.blizzard.craft ~= true then return end
|
||||
|
||||
E:StripTextures(CraftFrame, true)
|
||||
E:CreateBackdrop(CraftFrame, "Transparent")
|
||||
CraftFrame.backdrop:SetPoint("TOPLEFT", 10, -11)
|
||||
CraftFrame.backdrop:SetPoint("BOTTOMRIGHT", -32, 74)
|
||||
|
||||
E:StripTextures(CraftRankFrameBorder)
|
||||
CraftRankFrame:SetWidth(322)
|
||||
CraftRankFrame:SetHeight(16)
|
||||
CraftRankFrame:ClearAllPoints()
|
||||
CraftRankFrame:SetPoint("TOP", -10, -45)
|
||||
E:CreateBackdrop(CraftRankFrame)
|
||||
CraftRankFrame:SetStatusBarTexture(E["media"].normTex)
|
||||
CraftRankFrame:SetStatusBarColor(0.13, 0.35, 0.80)
|
||||
E:RegisterStatusBar(CraftRankFrame)
|
||||
|
||||
E:StripTextures(CraftExpandButtonFrame)
|
||||
E:StripTextures(CraftDetailScrollChildFrame)
|
||||
|
||||
E:StripTextures(CraftListScrollFrame)
|
||||
S:HandleScrollBar(CraftListScrollFrameScrollBar)
|
||||
|
||||
E:StripTextures(CraftDetailScrollFrame)
|
||||
S:HandleScrollBar(CraftDetailScrollFrameScrollBar)
|
||||
|
||||
E:StripTextures(CraftIcon)
|
||||
|
||||
S:HandleButton(CraftCreateButton)
|
||||
S:HandleButton(CraftCancelButton)
|
||||
|
||||
S:HandleCloseButton(CraftFrameCloseButton)
|
||||
|
||||
for i = 1, MAX_CRAFT_REAGENTS do
|
||||
local reagent = _G["CraftReagent"..i]
|
||||
local icon = _G["CraftReagent"..i.."IconTexture"]
|
||||
local count = _G["CraftReagent"..i.."Count"]
|
||||
local nameFrame = _G["CraftReagent"..i.."NameFrame"]
|
||||
|
||||
icon:SetTexCoord(unpack(E.TexCoords))
|
||||
icon:SetDrawLayer("OVERLAY")
|
||||
|
||||
icon.backdrop = CreateFrame("Frame", nil, reagent)
|
||||
icon.backdrop:SetFrameLevel(reagent:GetFrameLevel() - 1)
|
||||
E:SetTemplate(icon.backdrop, "Default")
|
||||
E:SetOutside(icon.backdrop, icon)
|
||||
|
||||
icon:SetParent(icon.backdrop)
|
||||
count:SetParent(icon.backdrop)
|
||||
count:SetDrawLayer("OVERLAY")
|
||||
|
||||
E:Kill(nameFrame)
|
||||
end
|
||||
|
||||
hooksecurefunc("CraftFrame_SetSelection", function(id)
|
||||
E:SetTemplate(CraftIcon, "Default", true)
|
||||
E:StyleButton(CraftIcon, nil, true)
|
||||
if CraftIcon:GetNormalTexture() then
|
||||
CraftIcon:GetNormalTexture():SetTexCoord(unpack(E.TexCoords))
|
||||
E:SetInside(CraftIcon:GetNormalTexture())
|
||||
end
|
||||
|
||||
CraftIcon:SetWidth(40)
|
||||
CraftIcon:SetHeight(40)
|
||||
CraftIcon:SetPoint("TOPLEFT", 4, -3)
|
||||
|
||||
CraftRequirements:SetTextColor(1, 0.80, 0.10)
|
||||
|
||||
local skillLink = GetCraftItemLink(id)
|
||||
if skillLink then
|
||||
local _, _, quality = GetItemInfo(match(skillLink, "enchant:(%d+)"))
|
||||
if quality then
|
||||
CraftIcon:SetBackdropBorderColor(GetItemQualityColor(quality))
|
||||
CraftName:SetTextColor(GetItemQualityColor(quality))
|
||||
else
|
||||
CraftIcon:SetBackdropBorderColor(unpack(E["media"].bordercolor))
|
||||
CraftName:SetTextColor(1, 1, 1)
|
||||
end
|
||||
end
|
||||
|
||||
local numReagents = GetCraftNumReagents(id)
|
||||
for i = 1, numReagents, 1 do
|
||||
local icon = _G["CraftReagent"..i.."IconTexture"]
|
||||
local name = _G["CraftReagent"..i.."Name"]
|
||||
|
||||
local _, _, reagentCount, playerReagentCount = GetCraftReagentInfo(id, i)
|
||||
local reagentLink = GetCraftReagentItemLink(id, i)
|
||||
if reagentLink 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)
|
||||
else
|
||||
name:SetTextColor(GetItemQualityColor(quality))
|
||||
end
|
||||
else
|
||||
icon.backdrop:SetBackdropBorderColor(unpack(E["media"].bordercolor))
|
||||
end
|
||||
end
|
||||
end
|
||||
end)
|
||||
|
||||
for i = 1, CRAFTS_DISPLAYED do
|
||||
local craftButton = _G["Craft"..i]
|
||||
craftButton:SetNormalTexture("")
|
||||
craftButton.SetNormalTexture = E.noop
|
||||
|
||||
_G["Craft"..i.."Highlight"]:SetTexture("")
|
||||
_G["Craft"..i.."Highlight"].SetTexture = E.noop
|
||||
|
||||
craftButton.Text = craftButton:CreateFontString(nil, "OVERLAY")
|
||||
E:FontTemplate(craftButton.Text, nil, 22)
|
||||
craftButton.Text:SetPoint("LEFT", 3, 0)
|
||||
craftButton.Text:SetText("+")
|
||||
|
||||
hooksecurefunc(craftButton, "SetNormalTexture", function(self, texture)
|
||||
if find(texture, "MinusButton") then
|
||||
self.Text:SetText("-")
|
||||
elseif find(texture, "PlusButton") then
|
||||
self.Text:SetText("+")
|
||||
else
|
||||
self.Text:SetText("")
|
||||
end
|
||||
end)
|
||||
end
|
||||
|
||||
CraftCollapseAllButton:SetNormalTexture("")
|
||||
CraftCollapseAllButton.SetNormalTexture = E.noop
|
||||
CraftCollapseAllButton:SetHighlightTexture("")
|
||||
CraftCollapseAllButton.SetHighlightTexture = E.noop
|
||||
CraftCollapseAllButton:SetDisabledTexture("")
|
||||
CraftCollapseAllButton.SetDisabledTexture = E.noop
|
||||
|
||||
CraftCollapseAllButton.Text = CraftCollapseAllButton:CreateFontString(nil, "OVERLAY")
|
||||
E:FontTemplate(CraftCollapseAllButton.Text, nil, 22)
|
||||
CraftCollapseAllButton.Text:SetPoint("LEFT", 3, 0)
|
||||
CraftCollapseAllButton.Text:SetText("+")
|
||||
|
||||
hooksecurefunc(CraftCollapseAllButton, "SetNormalTexture", function(self, texture)
|
||||
if find(texture, "MinusButton") then
|
||||
self.Text:SetText("-")
|
||||
else
|
||||
self.Text:SetText("+")
|
||||
end
|
||||
end)
|
||||
end
|
||||
|
||||
S:AddCallbackForAddon("Blizzard_CraftUI", "Craft", LoadSkin)
|
||||
@@ -0,0 +1,71 @@
|
||||
local E, L, V, P, G = unpack(ElvUI); --Import: Engine, Locales, PrivateDB, ProfileDB, GlobalDB
|
||||
local S = E:GetModule("Skins");
|
||||
|
||||
--Cache global variables
|
||||
--Lua functions
|
||||
local _G = _G
|
||||
local unpack = unpack
|
||||
local getn = table.getn
|
||||
--WoW API / Variables
|
||||
local hooksecurefunc = hooksecurefunc
|
||||
|
||||
local function LoadSkin()
|
||||
if E.private.skins.blizzard.enable ~= true or E.private.skins.blizzard.debug ~= true then return end
|
||||
|
||||
-- ScriptErrorsFrame:SetParent(E.UIParent)
|
||||
ScriptErrorsFrame:SetScale(UIParent:GetScale())
|
||||
E:SetTemplate(ScriptErrorsFrame, "Transparent")
|
||||
S:HandleScrollBar(ScriptErrorsFrameScrollFrameScrollBar)
|
||||
S:HandleCloseButton(ScriptErrorsFrameClose)
|
||||
E:FontTemplate(ScriptErrorsFrameScrollFrameText, nil, 13)
|
||||
E:CreateBackdrop(ScriptErrorsFrameScrollFrame, "Default")
|
||||
ScriptErrorsFrameScrollFrame:SetFrameLevel(ScriptErrorsFrameScrollFrame:GetFrameLevel() + 2)
|
||||
|
||||
E:SetTemplate(EventTraceFrame, "Transparent")
|
||||
S:HandleSliderFrame(EventTraceFrameScroll)
|
||||
|
||||
local texs = {
|
||||
"TopLeft",
|
||||
"TopRight",
|
||||
"Top",
|
||||
"BottomLeft",
|
||||
"BottomRight",
|
||||
"Bottom",
|
||||
"Left",
|
||||
"Right",
|
||||
"TitleBG",
|
||||
"DialogBG",
|
||||
}
|
||||
|
||||
for i = 1, getn(texs) do
|
||||
_G["ScriptErrorsFrame"..texs[i]]:SetTexture(nil)
|
||||
_G["EventTraceFrame"..texs[i]]:SetTexture(nil)
|
||||
end
|
||||
|
||||
S:HandleButton(ScriptErrorsFrame.reload)
|
||||
S:HandleNextPrevButton(ScriptErrorsFrame.previous)
|
||||
S:HandleNextPrevButton(ScriptErrorsFrame.next)
|
||||
S:HandleButton(ScriptErrorsFrame.close)
|
||||
|
||||
S:HandleButton(ScriptErrorsFrame.close)
|
||||
|
||||
ScriptErrorsFrame.reload:SetPoint("BOTTOMLEFT", 12, 8)
|
||||
ScriptErrorsFrame.previous:SetPoint("BOTTOM", ScriptErrorsFrame, "BOTTOM", -50, 7)
|
||||
ScriptErrorsFrame.next:SetPoint("BOTTOM", ScriptErrorsFrame, "BOTTOM", 50, 7)
|
||||
ScriptErrorsFrame.close:SetPoint("BOTTOMRIGHT", -12, 8)
|
||||
|
||||
local noscalemult = E.mult * GetCVar("uiScale")
|
||||
HookScript(FrameStackTooltip, "OnShow", function()
|
||||
E:SetTemplate(this, "Transparent")
|
||||
this:SetBackdropColor(unpack(E["media"].backdropfadecolor))
|
||||
this:SetBackdropBorderColor(unpack(E["media"].bordercolor))
|
||||
end)
|
||||
|
||||
HookScript(EventTraceTooltip, "OnShow", function()
|
||||
E:SetTemplate(this, "Transparent")
|
||||
end)
|
||||
|
||||
S:HandleCloseButton(EventTraceFrameCloseButton)
|
||||
end
|
||||
|
||||
S:AddCallbackForAddon("!DebugTools", "SkinDebugTools", LoadSkin)
|
||||
@@ -0,0 +1,43 @@
|
||||
local E, L, V, P, G = unpack(ElvUI); --Import: Engine, Locales, PrivateDB, ProfileDB, GlobalDB
|
||||
local S = E:GetModule("Skins");
|
||||
|
||||
--Cache global variables
|
||||
--Lua functions
|
||||
--WoW API / Variables
|
||||
local SetDressUpBackground = SetDressUpBackground
|
||||
|
||||
local function LoadSkin()
|
||||
if E.private.skins.blizzard.enable ~= true or E.private.skins.blizzard.dressingroom ~= true then return end
|
||||
|
||||
E:StripTextures(DressUpFrame)
|
||||
E:CreateBackdrop(DressUpFrame, "Transparent")
|
||||
DressUpFrame.backdrop:SetPoint("TOPLEFT", 10, -12)
|
||||
DressUpFrame.backdrop:SetPoint("BOTTOMRIGHT", -33, 73)
|
||||
|
||||
E:Kill(DressUpFramePortrait)
|
||||
|
||||
SetDressUpBackground()
|
||||
DressUpBackgroundTopLeft:SetDesaturated(true)
|
||||
DressUpBackgroundTopRight:SetDesaturated(true)
|
||||
DressUpBackgroundBotLeft:SetDesaturated(true)
|
||||
DressUpBackgroundBotRight:SetDesaturated(true)
|
||||
|
||||
DressUpFrameDescriptionText:SetPoint("CENTER", DressUpFrameTitleText, "BOTTOM", -5, -22)
|
||||
|
||||
S:HandleCloseButton(DressUpFrameCloseButton)
|
||||
|
||||
S:HandleRotateButton(DressUpModelRotateLeftButton)
|
||||
DressUpModelRotateLeftButton:SetPoint("TOPLEFT", DressUpFrame, 25, -79)
|
||||
S:HandleRotateButton(DressUpModelRotateRightButton)
|
||||
DressUpModelRotateRightButton:SetPoint("TOPLEFT", DressUpModelRotateLeftButton, "TOPRIGHT", 3, 0)
|
||||
|
||||
S:HandleButton(DressUpFrameCancelButton)
|
||||
DressUpFrameCancelButton:SetPoint("CENTER", DressUpFrame, "TOPLEFT", 306, -423)
|
||||
S:HandleButton(DressUpFrameResetButton)
|
||||
DressUpFrameResetButton:SetPoint("RIGHT", DressUpFrameCancelButton, "LEFT", -3, 0)
|
||||
|
||||
E:CreateBackdrop(DressUpModel, "Default")
|
||||
E:SetOutside(DressUpModel.backdrop, DressUpBackgroundTopLeft, nil, nil, DressUpModel)
|
||||
end
|
||||
|
||||
S:AddCallback("DressingRoom", LoadSkin)
|
||||
@@ -0,0 +1,434 @@
|
||||
local E, L, V, P, G = unpack(ElvUI); --Import: Engine, Locales, PrivateDB, ProfileDB, GlobalDB
|
||||
local S = E:GetModule("Skins");
|
||||
|
||||
--Cache global variables
|
||||
--Lua functions
|
||||
local _G = _G
|
||||
local unpack = unpack
|
||||
local upper = string.upper
|
||||
--WoW API / Variables
|
||||
local GetWhoInfo = GetWhoInfo
|
||||
local GetGuildRosterInfo = GetGuildRosterInfo
|
||||
local GUILDMEMBERS_TO_DISPLAY = GUILDMEMBERS_TO_DISPLAY
|
||||
local RAID_CLASS_COLORS = RAID_CLASS_COLORS
|
||||
local CUSTOM_CLASS_COLORS = CUSTOM_CLASS_COLORS
|
||||
local hooksecurefunc = hooksecurefunc
|
||||
|
||||
function LoadSkin()
|
||||
if E.private.skins.blizzard.enable ~= true or E.private.skins.blizzard.friends ~= true then return end
|
||||
|
||||
-- Friends Frame
|
||||
E:StripTextures(FriendsFrame, true)
|
||||
E:CreateBackdrop(FriendsFrame, "Transparent")
|
||||
FriendsFrame.backdrop:SetPoint("TOPLEFT", 10, -12)
|
||||
FriendsFrame.backdrop:SetPoint("BOTTOMRIGHT", -33, 76)
|
||||
|
||||
S:HandleCloseButton(FriendsFrameCloseButton)
|
||||
|
||||
for i = 1, 4 do
|
||||
S:HandleTab(_G["FriendsFrameTab"..i])
|
||||
end
|
||||
|
||||
-- Friends List Frame
|
||||
for i = 1, 2 do
|
||||
local tab = _G["FriendsFrameToggleTab"..i]
|
||||
E:StripTextures(tab)
|
||||
E:CreateBackdrop(tab, "Default", true)
|
||||
tab.backdrop:SetPoint("TOPLEFT", 3, -7)
|
||||
tab.backdrop:SetPoint("BOTTOMRIGHT", -2, -1)
|
||||
|
||||
tab:SetScript("OnEnter", S.SetModifiedBackdrop)
|
||||
tab:SetScript("OnLeave", S.SetOriginalBackdrop)
|
||||
end
|
||||
|
||||
|
||||
local r, g, b = 0.8, 0.8, 0.8
|
||||
local function StyleButton(f, scale)
|
||||
f:SetHighlightTexture(nil)
|
||||
local width, height = (f:GetWidth() * (scale or 0.5)), f:GetHeight()
|
||||
|
||||
local leftGrad = f:CreateTexture(nil, "HIGHLIGHT")
|
||||
leftGrad:SetWidth(width)
|
||||
leftGrad:SetHeight(height)
|
||||
leftGrad:SetPoint("LEFT", f, "CENTER")
|
||||
leftGrad:SetTexture(E.media.blankTex)
|
||||
leftGrad:SetGradientAlpha("Horizontal", r, g, b, 0.35, r, g, b, 0)
|
||||
|
||||
local rightGrad = f:CreateTexture(nil, "HIGHLIGHT")
|
||||
rightGrad:SetWidth(width)
|
||||
rightGrad:SetHeight(height)
|
||||
rightGrad:SetPoint("RIGHT", f, "CENTER")
|
||||
rightGrad:SetTexture(E.media.blankTex)
|
||||
rightGrad:SetGradientAlpha("Horizontal", r, g, b, 0, r, g, b, 0.35)
|
||||
end
|
||||
|
||||
for i = 1, 10 do
|
||||
StyleButton(_G["FriendsFrameFriendButton"..i], 0.6)
|
||||
end
|
||||
|
||||
E:StripTextures(FriendsFrameFriendsScrollFrame)
|
||||
|
||||
S:HandleScrollBar(FriendsFrameFriendsScrollFrameScrollBar)
|
||||
|
||||
S:HandleButton(FriendsFrameAddFriendButton)
|
||||
FriendsFrameAddFriendButton:SetPoint("BOTTOMLEFT", 17, 102)
|
||||
|
||||
S:HandleButton(FriendsFrameSendMessageButton)
|
||||
|
||||
S:HandleButton(FriendsFrameRemoveFriendButton)
|
||||
FriendsFrameRemoveFriendButton:SetPoint("TOP", FriendsFrameAddFriendButton, "BOTTOM", 0, -2)
|
||||
|
||||
S:HandleButton(FriendsFrameGroupInviteButton)
|
||||
FriendsFrameGroupInviteButton:SetPoint("TOP", FriendsFrameSendMessageButton, "BOTTOM", 0, -2)
|
||||
|
||||
-- Ignore List Frame
|
||||
for i = 1, 2 do
|
||||
local tab = _G["IgnoreFrameToggleTab"..i]
|
||||
E:StripTextures(tab)
|
||||
E:CreateBackdrop(tab, "Default", true)
|
||||
tab.backdrop:SetPoint("TOPLEFT", 3, -7)
|
||||
tab.backdrop:SetPoint("BOTTOMRIGHT", -2, -1)
|
||||
|
||||
tab:SetScript("OnEnter", function() S:SetModifiedBackdrop(this) end)
|
||||
tab:SetScript("OnLeave", function() S:SetOriginalBackdrop(this) end)
|
||||
end
|
||||
|
||||
S:HandleButton(FriendsFrameIgnorePlayerButton)
|
||||
S:HandleButton(FriendsFrameStopIgnoreButton)
|
||||
|
||||
for i = 1, 20 do
|
||||
StyleButton(_G["FriendsFrameIgnoreButton"..i])
|
||||
end
|
||||
|
||||
-- Who Frame
|
||||
WhoFrameColumnHeader3:ClearAllPoints()
|
||||
WhoFrameColumnHeader3:SetPoint("TOPLEFT", 20, -70)
|
||||
|
||||
WhoFrameColumnHeader4:ClearAllPoints()
|
||||
WhoFrameColumnHeader4:SetPoint("LEFT", WhoFrameColumnHeader3, "RIGHT", -2, -0)
|
||||
WhoFrameColumnHeader4:SetWidth(48)
|
||||
|
||||
WhoFrameColumnHeader1:ClearAllPoints()
|
||||
WhoFrameColumnHeader1:SetPoint("LEFT", WhoFrameColumnHeader4, "RIGHT", -2, -0)
|
||||
WhoFrameColumnHeader1:SetWidth(105)
|
||||
|
||||
WhoFrameColumnHeader2:ClearAllPoints()
|
||||
WhoFrameColumnHeader2:SetPoint("LEFT", WhoFrameColumnHeader1, "RIGHT", -2, -0)
|
||||
|
||||
for i = 1, 4 do
|
||||
E:StripTextures(_G["WhoFrameColumnHeader"..i])
|
||||
E:StyleButton(_G["WhoFrameColumnHeader"..i], nil, true)
|
||||
end
|
||||
|
||||
S:HandleDropDownBox(WhoFrameDropDown)
|
||||
|
||||
for i = 1, 17 do
|
||||
local button = _G["WhoFrameButton"..i]
|
||||
local level = _G["WhoFrameButton"..i.."Level"]
|
||||
local name = _G["WhoFrameButton"..i.."Name"]
|
||||
|
||||
button.icon = button:CreateTexture("$parentIcon", "ARTWORK")
|
||||
button.icon:SetPoint("LEFT", 45, 0)
|
||||
button.icon:SetWidth(15)
|
||||
button.icon:SetHeight(15)
|
||||
button.icon:SetTexture("Interface\\AddOns\\ElvUI\\Media\\Textures\\Icons-Classes")
|
||||
|
||||
E:CreateBackdrop(button, "Default", true)
|
||||
button.backdrop:SetAllPoints(button.icon)
|
||||
StyleButton(button)
|
||||
|
||||
level:ClearAllPoints()
|
||||
level:SetPoint("TOPLEFT", 12, -2)
|
||||
|
||||
name:SetWidth(100)
|
||||
name:SetHeight(14)
|
||||
name:ClearAllPoints()
|
||||
name:SetPoint("LEFT", 85, 0)
|
||||
|
||||
_G["WhoFrameButton"..i.."Class"]:Hide()
|
||||
end
|
||||
|
||||
E:StripTextures(WhoListScrollFrame)
|
||||
S:HandleScrollBar(WhoListScrollFrameScrollBar)
|
||||
|
||||
S:HandleEditBox(WhoFrameEditBox)
|
||||
WhoFrameEditBox:SetPoint("BOTTOMLEFT", 17, 108)
|
||||
WhoFrameEditBox:SetWidth(338)
|
||||
WhoFrameEditBox:SetHeight(18)
|
||||
|
||||
S:HandleButton(WhoFrameWhoButton)
|
||||
WhoFrameWhoButton:ClearAllPoints()
|
||||
WhoFrameWhoButton:SetPoint("BOTTOMLEFT", 16, 82)
|
||||
|
||||
S:HandleButton(WhoFrameAddFriendButton)
|
||||
WhoFrameAddFriendButton:SetPoint("LEFT", WhoFrameWhoButton, "RIGHT", 3, 0)
|
||||
WhoFrameAddFriendButton:SetPoint("RIGHT", WhoFrameGroupInviteButton, "LEFT", -3, 0)
|
||||
|
||||
S:HandleButton(WhoFrameGroupInviteButton)
|
||||
|
||||
hooksecurefunc("WhoList_Update", function()
|
||||
local whoOffset = FauxScrollFrame_GetOffset(WhoListScrollFrame)
|
||||
local playerZone = GetRealZoneText()
|
||||
local playerGuild = GetGuildInfo("player")
|
||||
local playerRace = UnitRace("player")
|
||||
|
||||
for i = 1, WHOS_TO_DISPLAY, 1 do
|
||||
local index = whoOffset + i
|
||||
local button = _G["WhoFrameButton"..i]
|
||||
local nameText = _G["WhoFrameButton"..i.."Name"]
|
||||
local levelText = _G["WhoFrameButton"..i.."Level"]
|
||||
local classText = _G["WhoFrameButton"..i.."Class"]
|
||||
local variableText = _G["WhoFrameButton"..i.."Variable"]
|
||||
|
||||
local _, guild, level, race, class, zone = GetWhoInfo(index)
|
||||
if class == UNKNOWN then return end
|
||||
|
||||
if class then
|
||||
class = strupper(class)
|
||||
end
|
||||
|
||||
local classTextColor = CUSTOM_CLASS_COLORS and CUSTOM_CLASS_COLORS[class] or RAID_CLASS_COLORS[class]
|
||||
local levelTextColor = GetQuestDifficultyColor(level)
|
||||
|
||||
if class then
|
||||
button.icon:Show()
|
||||
button.icon:SetTexCoord(unpack(CLASS_ICON_TCOORDS[class]))
|
||||
|
||||
nameText:SetTextColor(classTextColor.r, classTextColor.g, classTextColor.b)
|
||||
levelText:SetTextColor(levelTextColor.r, levelTextColor.g, levelTextColor.b)
|
||||
|
||||
if zone == playerZone then
|
||||
zone = "|cff00ff00"..zone
|
||||
end
|
||||
if guild == playerGuild then
|
||||
guild = "|cff00ff00"..guild
|
||||
end
|
||||
if race == playerRace then
|
||||
race = "|cff00ff00"..race
|
||||
end
|
||||
|
||||
local columnTable = {zone, guild, race}
|
||||
|
||||
variableText:SetText(columnTable[UIDropDownMenu_GetSelectedID(WhoFrameDropDown)])
|
||||
else
|
||||
button.icon:Hide()
|
||||
end
|
||||
end
|
||||
end)
|
||||
|
||||
-- Guild Frame
|
||||
GuildFrameColumnHeader3:ClearAllPoints()
|
||||
GuildFrameColumnHeader3:SetPoint("TOPLEFT", 20, -70)
|
||||
|
||||
GuildFrameColumnHeader4:ClearAllPoints()
|
||||
GuildFrameColumnHeader4:SetPoint("LEFT", GuildFrameColumnHeader3, "RIGHT", -2, -0)
|
||||
GuildFrameColumnHeader4:SetWidth(48)
|
||||
|
||||
GuildFrameColumnHeader1:ClearAllPoints()
|
||||
GuildFrameColumnHeader1:SetPoint("LEFT", GuildFrameColumnHeader4, "RIGHT", -2, -0)
|
||||
GuildFrameColumnHeader1:SetWidth(105)
|
||||
|
||||
GuildFrameColumnHeader2:ClearAllPoints()
|
||||
GuildFrameColumnHeader2:SetPoint("LEFT", GuildFrameColumnHeader1, "RIGHT", -2, -0)
|
||||
GuildFrameColumnHeader2:SetWidth(127)
|
||||
|
||||
for i = 1, GUILDMEMBERS_TO_DISPLAY do
|
||||
local button = _G["GuildFrameButton"..i]
|
||||
|
||||
StyleButton(button)
|
||||
StyleButton(_G["GuildFrameGuildStatusButton"..i])
|
||||
|
||||
button.icon = button:CreateTexture("$parentIcon", "ARTWORK")
|
||||
button.icon:SetPoint("LEFT", 48, -3)
|
||||
button.icon:SetWidth(15)
|
||||
button.icon:SetHeight(15)
|
||||
button.icon:SetTexture("Interface\\AddOns\\ElvUI\\Media\\Textures\\Icons-Classes")
|
||||
|
||||
E:CreateBackdrop(button, "Default", true)
|
||||
button.backdrop:SetAllPoints(button.icon)
|
||||
|
||||
_G["GuildFrameButton"..i.."Level"]:ClearAllPoints()
|
||||
_G["GuildFrameButton"..i.."Level"]:SetPoint("TOPLEFT", 10, -3)
|
||||
|
||||
_G["GuildFrameButton"..i.."Name"]:SetWidth(100)
|
||||
_G["GuildFrameButton"..i.."Name"]:SetHeight(14)
|
||||
_G["GuildFrameButton"..i.."Name"]:ClearAllPoints()
|
||||
_G["GuildFrameButton"..i.."Name"]:SetPoint("LEFT", 85, -3)
|
||||
|
||||
_G["GuildFrameButton"..i.."Class"]:Hide()
|
||||
end
|
||||
|
||||
hooksecurefunc("GuildStatus_Update", function()
|
||||
if FriendsFrame.playerStatusFrame then
|
||||
for i = 1, GUILDMEMBERS_TO_DISPLAY, 1 do
|
||||
local button = _G["GuildFrameButton"..i]
|
||||
local _, _, _, level, class, _, _, _, online = GetGuildRosterInfo(button.guildIndex)
|
||||
if class == UNKNOWN then return end
|
||||
|
||||
if class then
|
||||
class = upper(class)
|
||||
end
|
||||
|
||||
if class then
|
||||
if online then
|
||||
classTextColor = CUSTOM_CLASS_COLORS and CUSTOM_CLASS_COLORS[class] or RAID_CLASS_COLORS[class]
|
||||
levelTextColor = GetQuestDifficultyColor(level)
|
||||
buttonText = _G["GuildFrameButton"..i.."Name"]
|
||||
buttonText:SetTextColor(classTextColor.r, classTextColor.g, classTextColor.b)
|
||||
buttonText = _G["GuildFrameButton"..i.."Level"]
|
||||
buttonText:SetTextColor(levelTextColor.r, levelTextColor.g, levelTextColor.b)
|
||||
end
|
||||
button.icon:SetTexCoord(unpack(CLASS_ICON_TCOORDS[class]))
|
||||
end
|
||||
end
|
||||
else
|
||||
local classFileName
|
||||
for i = 1, GUILDMEMBERS_TO_DISPLAY, 1 do
|
||||
button = _G["GuildFrameGuildStatusButton"..i]
|
||||
_, _, _, _, class, _, _, _, online = GetGuildRosterInfo(button.guildIndex)
|
||||
if class == UNKNOWN then return end
|
||||
|
||||
if class then
|
||||
class = upper(class)
|
||||
end
|
||||
|
||||
if class then
|
||||
if online then
|
||||
classTextColor = CUSTOM_CLASS_COLORS and CUSTOM_CLASS_COLORS[class] or RAID_CLASS_COLORS[class]
|
||||
_G["GuildFrameGuildStatusButton"..i.."Name"]:SetTextColor(classTextColor.r, classTextColor.g, classTextColor.b)
|
||||
_G["GuildFrameGuildStatusButton"..i.."Online"]:SetTextColor(1.0, 1.0, 1.0)
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
end)
|
||||
|
||||
E:StripTextures(GuildFrameLFGFrame)
|
||||
E:SetTemplate(GuildFrameLFGFrame, "Transparent")
|
||||
|
||||
S:HandleCheckBox(GuildFrameLFGButton)
|
||||
|
||||
for i = 1, 4 do
|
||||
E:StripTextures(_G["GuildFrameColumnHeader"..i])
|
||||
E:StyleButton(_G["GuildFrameColumnHeader"..i], nil, true)
|
||||
E:StripTextures(_G["GuildFrameGuildStatusColumnHeader"..i])
|
||||
E:StyleButton(_G["GuildFrameGuildStatusColumnHeader"..i], nil, true)
|
||||
end
|
||||
|
||||
E:StripTextures(GuildListScrollFrame)
|
||||
S:HandleScrollBar(GuildListScrollFrameScrollBar)
|
||||
|
||||
S:HandleNextPrevButton(GuildFrameGuildListToggleButton)
|
||||
|
||||
S:HandleButton(GuildFrameGuildInformationButton)
|
||||
S:HandleButton(GuildFrameAddMemberButton)
|
||||
S:HandleButton(GuildFrameControlButton)
|
||||
|
||||
-- Member Detail Frame
|
||||
E:StripTextures(GuildMemberDetailFrame)
|
||||
E:CreateBackdrop(GuildMemberDetailFrame, "Transparent")
|
||||
GuildMemberDetailFrame:SetPoint("TOPLEFT", GuildFrame, "TOPRIGHT", -31, -13)
|
||||
|
||||
S:HandleCloseButton(GuildMemberDetailCloseButton)
|
||||
GuildMemberDetailCloseButton:SetPoint("TOPRIGHT", 2, 2)
|
||||
|
||||
S:HandleButton(GuildFrameControlButton)
|
||||
S:HandleButton(GuildMemberRemoveButton)
|
||||
GuildMemberRemoveButton:SetPoint("BOTTOMLEFT", 8, 7)
|
||||
S:HandleButton(GuildMemberGroupInviteButton)
|
||||
GuildMemberGroupInviteButton:SetPoint("LEFT", GuildMemberRemoveButton, "RIGHT", 3, 0)
|
||||
|
||||
S:HandleNextPrevButton(GuildFramePromoteButton, true)
|
||||
S:HandleNextPrevButton(GuildFrameDemoteButton, true)
|
||||
GuildFrameDemoteButton:SetPoint("LEFT", GuildFramePromoteButton, "RIGHT", 2, 0)
|
||||
|
||||
E:SetTemplate(GuildMemberNoteBackground, "Default")
|
||||
E:SetTemplate(GuildMemberOfficerNoteBackground, "Default")
|
||||
|
||||
-- Info Frame
|
||||
E:StripTextures(GuildInfoFrame)
|
||||
E:CreateBackdrop(GuildInfoFrame, "Transparent")
|
||||
GuildInfoFrame.backdrop:SetPoint("TOPLEFT", 3, -6)
|
||||
GuildInfoFrame.backdrop:SetPoint("BOTTOMRIGHT", -2, 3)
|
||||
|
||||
E:SetTemplate(GuildInfoTextBackground, "Default")
|
||||
S:HandleScrollBar(GuildInfoFrameScrollFrameScrollBar)
|
||||
|
||||
S:HandleCloseButton(GuildInfoCloseButton)
|
||||
|
||||
S:HandleButton(GuildInfoSaveButton)
|
||||
GuildInfoSaveButton:SetPoint("BOTTOMLEFT", 8, 11)
|
||||
S:HandleButton(GuildInfoCancelButton)
|
||||
GuildInfoCancelButton:SetPoint("LEFT", GuildInfoSaveButton, "RIGHT", 3, 0)
|
||||
|
||||
-- Control Frame
|
||||
E:StripTextures(GuildControlPopupFrame)
|
||||
E:CreateBackdrop(GuildControlPopupFrame, "Transparent")
|
||||
GuildControlPopupFrame.backdrop:SetPoint("TOPLEFT", 3, -6)
|
||||
GuildControlPopupFrame.backdrop:SetPoint("BOTTOMRIGHT", -27, 27)
|
||||
|
||||
S:HandleDropDownBox(GuildControlPopupFrameDropDown, 185)
|
||||
GuildControlPopupFrameDropDownButton:SetWidth(16)
|
||||
GuildControlPopupFrameDropDownButton:SetHeight(16)
|
||||
|
||||
local function SkinPlusMinus(f, minus)
|
||||
f:SetNormalTexture("")
|
||||
f.SetNormalTexture = E.noop
|
||||
f:SetPushedTexture("")
|
||||
f.SetPushedTexture = E.noop
|
||||
f:SetHighlightTexture("")
|
||||
f.SetHighlightTexture = E.noop
|
||||
f:SetDisabledTexture("")
|
||||
f.SetDisabledTexture = E.noop
|
||||
|
||||
f.Text = f:CreateFontString(nil, "OVERLAY")
|
||||
E:FontTemplate(f.Text, nil, 22)
|
||||
f.Text:SetPoint("LEFT", 5, 0)
|
||||
if minus then
|
||||
f.Text:SetText("-")
|
||||
else
|
||||
f.Text:SetText("+")
|
||||
end
|
||||
end
|
||||
|
||||
GuildControlPopupFrameAddRankButton:SetPoint("LEFT", GuildControlPopupFrameDropDown, "RIGHT", -8, 3)
|
||||
SkinPlusMinus(GuildControlPopupFrameAddRankButton)
|
||||
SkinPlusMinus(GuildControlPopupFrameRemoveRankButton, true)
|
||||
|
||||
S:HandleEditBox(GuildControlPopupFrameEditBox)
|
||||
GuildControlPopupFrameEditBox.backdrop:SetPoint("TOPLEFT", 0, -5)
|
||||
GuildControlPopupFrameEditBox.backdrop:SetPoint("BOTTOMRIGHT", 0, 5)
|
||||
|
||||
for i = 1, 17 do
|
||||
local Checkbox = _G["GuildControlPopupFrameCheckbox"..i]
|
||||
if Checkbox then
|
||||
S:HandleCheckBox(Checkbox)
|
||||
end
|
||||
end
|
||||
|
||||
S:HandleButton(GuildControlPopupAcceptButton)
|
||||
S:HandleButton(GuildControlPopupFrameCancelButton)
|
||||
|
||||
-- Raid Frame
|
||||
S:HandleButton(RaidFrameConvertToRaidButton)
|
||||
S:HandleButton(RaidFrameRaidInfoButton)
|
||||
|
||||
-- Raid Info Frame
|
||||
E:StripTextures(RaidInfoFrame, true)
|
||||
E:SetTemplate(RaidInfoFrame, "Transparent")
|
||||
|
||||
HookScript(RaidInfoFrame, "OnShow", function()
|
||||
if GetNumRaidMembers() > 0 then
|
||||
RaidInfoFrame:SetPoint("TOPLEFT", RaidFrame, "TOPRIGHT", -14, -12)
|
||||
else
|
||||
RaidInfoFrame:SetPoint("TOPLEFT", RaidFrame, "TOPRIGHT", -34, -12)
|
||||
end
|
||||
end)
|
||||
|
||||
S:HandleCloseButton(RaidInfoCloseButton, RaidInfoFrame)
|
||||
|
||||
E:StripTextures(RaidInfoScrollFrame)
|
||||
S:HandleScrollBar(RaidInfoScrollFrameScrollBar)
|
||||
end
|
||||
|
||||
S:AddCallback("Friends", LoadSkin)
|
||||
@@ -0,0 +1,58 @@
|
||||
local E, L, V, P, G = unpack(ElvUI); --Import: Engine, Locales, PrivateDB, ProfileDB, GlobalDB
|
||||
local S = E:GetModule("Skins");
|
||||
|
||||
--Cache global variables
|
||||
--Lua functions
|
||||
local _G = _G
|
||||
--WoW API / Variables
|
||||
|
||||
local function LoadSkin()
|
||||
if E.private.skins.blizzard.enable ~= true or E.private.skins.blizzard.gossip ~= true then return end
|
||||
|
||||
-- ItemTextFrame
|
||||
E:StripTextures(ItemTextFrame, true)
|
||||
E:StripTextures(ItemTextScrollFrame)
|
||||
|
||||
S:HandleScrollBar(ItemTextScrollFrameScrollBar)
|
||||
|
||||
E:CreateBackdrop(ItemTextFrame, "Transparent")
|
||||
ItemTextFrame.backdrop:SetPoint("TOPLEFT", 13, -13)
|
||||
ItemTextFrame.backdrop:SetPoint("BOTTOMRIGHT", -32, 74)
|
||||
|
||||
S:HandleNextPrevButton(ItemTextPrevPageButton)
|
||||
S:HandleNextPrevButton(ItemTextNextPageButton)
|
||||
ItemTextPrevPageButton:ClearAllPoints()
|
||||
ItemTextNextPageButton:ClearAllPoints()
|
||||
ItemTextPrevPageButton:SetPoint("TOPLEFT", ItemTextFrame, "TOPLEFT", 30, -50)
|
||||
ItemTextNextPageButton:SetPoint("TOPRIGHT", ItemTextFrame, "TOPRIGHT", -48, -50)
|
||||
|
||||
S:HandleCloseButton(ItemTextCloseButton)
|
||||
|
||||
ItemTextPageText:SetTextColor(1, 1, 1)
|
||||
ItemTextPageText.SetTextColor = E.noop
|
||||
|
||||
-- GossipFrame
|
||||
E:StripTextures(GossipFrameGreetingPanel)
|
||||
|
||||
S:HandleScrollBar(GossipGreetingScrollFrameScrollBar, 5)
|
||||
|
||||
E:Kill(GossipFramePortrait)
|
||||
|
||||
E:CreateBackdrop(GossipFrame, "Transparent")
|
||||
GossipFrame.backdrop:SetPoint("TOPLEFT", 15, -19)
|
||||
GossipFrame.backdrop:SetPoint("BOTTOMRIGHT", -30, 67)
|
||||
|
||||
S:HandleButton(GossipFrameGreetingGoodbyeButton)
|
||||
GossipFrameGreetingGoodbyeButton:SetPoint("BOTTOMRIGHT", GossipFrame, -34, 71)
|
||||
|
||||
S:HandleCloseButton(GossipFrameCloseButton)
|
||||
|
||||
GossipGreetingText:SetTextColor(1, 1, 1)
|
||||
|
||||
for i = 1, NUMGOSSIPBUTTONS do
|
||||
local button = _G["GossipTitleButton"..i]
|
||||
button:SetTextColor(1, 1, 1)
|
||||
end
|
||||
end
|
||||
|
||||
S:AddCallback("Gossip", LoadSkin)
|
||||
@@ -0,0 +1,30 @@
|
||||
local E, L, V, P, G = unpack(ElvUI); --Import: Engine, Locales, PrivateDB, ProfileDB, GlobalDB
|
||||
local S = E:GetModule("Skins");
|
||||
|
||||
--Cache global variables
|
||||
--Lua functions
|
||||
local _G = _G
|
||||
--WoW API / Variables
|
||||
|
||||
local function LoadSkin()
|
||||
if E.private.skins.blizzard.enable ~= true or E.private.skins.blizzard.greeting ~= true then return end
|
||||
|
||||
E:StripTextures(QuestFrameGreetingPanel)
|
||||
|
||||
E:Kill(QuestGreetingFrameHorizontalBreak)
|
||||
|
||||
S:HandleScrollBar(QuestGreetingScrollFrameScrollBar)
|
||||
|
||||
S:HandleButton(QuestFrameGreetingGoodbyeButton, true)
|
||||
|
||||
GreetingText:SetTextColor(1, 1, 1)
|
||||
CurrentQuestsText:SetTextColor(1, 1, 0)
|
||||
AvailableQuestsText:SetTextColor(1, 1, 0)
|
||||
|
||||
for i = 1, MAX_NUM_QUESTS do
|
||||
local button = _G["QuestTitleButton"..i]
|
||||
button:SetTextColor(1, 1, 0)
|
||||
end
|
||||
end
|
||||
|
||||
S:AddCallback("Greeting", LoadSkin)
|
||||
@@ -0,0 +1,35 @@
|
||||
local E, L, V, P, G = unpack(ElvUI); --Import: Engine, Locales, PrivateDB, ProfileDB, GlobalDB
|
||||
local S = E:GetModule("Skins");
|
||||
|
||||
--Cache global variables
|
||||
--Lua functions
|
||||
local _G = _G
|
||||
--WoW API / Variables
|
||||
|
||||
local function LoadSkin()
|
||||
if E.private.skins.blizzard.enable ~= true or E.private.skins.blizzard.guildregistrar ~= true then return end
|
||||
|
||||
E:StripTextures(GuildRegistrarFrame, true)
|
||||
E:CreateBackdrop(GuildRegistrarFrame, "Transparent")
|
||||
GuildRegistrarFrame.backdrop:SetPoint("TOPLEFT", 12, -17)
|
||||
GuildRegistrarFrame.backdrop:SetPoint("BOTTOMRIGHT", -28, 65)
|
||||
E:StripTextures(GuildRegistrarGreetingFrame)
|
||||
S:HandleButton(GuildRegistrarFrameGoodbyeButton)
|
||||
S:HandleButton(GuildRegistrarFrameCancelButton)
|
||||
S:HandleButton(GuildRegistrarFramePurchaseButton)
|
||||
S:HandleCloseButton(GuildRegistrarFrameCloseButton)
|
||||
S:HandleEditBox(GuildRegistrarFrameEditBox)
|
||||
|
||||
GuildRegistrarFrameEditBox:DisableDrawLayer("BACKGROUND")
|
||||
|
||||
GuildRegistrarFrameEditBox:SetHeight(20)
|
||||
|
||||
for i = 1, 2 do
|
||||
_G["GuildRegistrarButton"..i]:GetFontString():SetTextColor(1, 1, 1)
|
||||
end
|
||||
|
||||
GuildRegistrarPurchaseText:SetTextColor(1, 1, 1)
|
||||
AvailableServicesText:SetTextColor(1, 1, 0)
|
||||
end
|
||||
|
||||
S:AddCallback("GuildRegistrar", LoadSkin)
|
||||
@@ -0,0 +1,72 @@
|
||||
local E, L, V, P, G = unpack(ElvUI); --Import: Engine, Locales, PrivateDB, ProfileDB, GlobalDB
|
||||
local S = E:GetModule("Skins");
|
||||
|
||||
--Cache global variables
|
||||
--Lua functions
|
||||
local _G = _G
|
||||
local getn = table.getn
|
||||
--WoW API / Variables
|
||||
|
||||
local function LoadSkin()
|
||||
if E.private.skins.blizzard.enable ~= true or E.private.skins.blizzard.help ~= true then return end
|
||||
|
||||
local helpFrameButtons = {
|
||||
"GeneralBack",
|
||||
"GeneralButton",
|
||||
"GeneralButton2",
|
||||
"GeneralCancel",
|
||||
"GMBack",
|
||||
"GMCancel",
|
||||
"HarassmentBack",
|
||||
"HarassmentCancel",
|
||||
"HomeIssues",
|
||||
"HomeCancel",
|
||||
"OpenTicketSubmit",
|
||||
"OpenTicketCancel",
|
||||
"PhysicalHarassmentButton",
|
||||
"VerbalHarassmentButton",
|
||||
}
|
||||
|
||||
E:StripTextures(HelpFrame)
|
||||
E:CreateBackdrop(HelpFrame, "Transparent")
|
||||
HelpFrame.backdrop:SetPoint("TOPLEFT", 6, -2)
|
||||
HelpFrame.backdrop:SetPoint("BOTTOMRIGHT", -45, 14)
|
||||
|
||||
S:HandleCloseButton(HelpFrameCloseButton)
|
||||
HelpFrameCloseButton:SetPoint("TOPRIGHT", -42, 0)
|
||||
|
||||
for i = 1, getn(helpFrameButtons) do
|
||||
local helpButton = _G["HelpFrame"..helpFrameButtons[i]]
|
||||
S:HandleButton(helpButton)
|
||||
end
|
||||
|
||||
-- hide header textures and move text/buttons.
|
||||
local BlizzardHeader = {
|
||||
"KnowledgeBaseFrame"
|
||||
}
|
||||
|
||||
for i = 1, getn(BlizzardHeader) do
|
||||
local title = _G[BlizzardHeader[i].."Header"]
|
||||
if title then
|
||||
title:SetTexture("")
|
||||
title:ClearAllPoints()
|
||||
if title == _G["GameMenuFrameHeader"] then
|
||||
title:SetPoint("TOP", GameMenuFrame, 0, 0)
|
||||
else
|
||||
title:SetPoint("TOP", BlizzardHeader[i], -22, -8)
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
E:StripTextures(HelpFrameOpenTicketDivider)
|
||||
|
||||
S:HandleScrollBar(HelpFrameOpenTicketScrollFrame)
|
||||
S:HandleScrollBar(HelpFrameOpenTicketScrollFrameScrollBar)
|
||||
|
||||
HelpFrameOpenTicketSubmit:SetPoint("RIGHT", HelpFrameOpenTicketCancel, "LEFT", -2, 0)
|
||||
|
||||
E:Kill(HelpFrameHarassmentDivider)
|
||||
E:Kill(HelpFrameHarassmentDivider2)
|
||||
end
|
||||
|
||||
S:AddCallback("Help", LoadSkin)
|
||||
@@ -0,0 +1,99 @@
|
||||
local E, L, V, P, G = unpack(ElvUI); --Import: Engine, Locales, PrivateDB, ProfileDB, GlobalDB
|
||||
local S = E:GetModule("Skins");
|
||||
|
||||
--Cache global variables
|
||||
--Lua functions
|
||||
local _G = _G
|
||||
local unpack = unpack
|
||||
local pairs = pairs
|
||||
local find, match, split = string.find, string.match, string.split
|
||||
--WoW API / Variables
|
||||
local GetInventoryItemLink = GetInventoryItemLink
|
||||
local GetItemInfo = GetItemInfo
|
||||
local GetItemQualityColor = GetItemQualityColor
|
||||
local hooksecurefunc = hooksecurefunc
|
||||
|
||||
local function LoadSkin()
|
||||
if not E.private.skins.blizzard.enable or not E.private.skins.blizzard.inspect then return end
|
||||
|
||||
E:StripTextures(InspectFrame, true)
|
||||
E:CreateBackdrop(InspectFrame, "Transparent")
|
||||
InspectFrame.backdrop:SetPoint("TOPLEFT", 10, -12)
|
||||
InspectFrame.backdrop:SetPoint("BOTTOMRIGHT", -31, 75)
|
||||
|
||||
S:HandleCloseButton(InspectFrameCloseButton)
|
||||
|
||||
for i = 1, 2 do
|
||||
S:HandleTab(_G["InspectFrameTab"..i])
|
||||
end
|
||||
|
||||
E:StripTextures(InspectPaperDollFrame)
|
||||
|
||||
local slots = {
|
||||
"HeadSlot",
|
||||
"NeckSlot",
|
||||
"ShoulderSlot",
|
||||
"BackSlot",
|
||||
"ChestSlot",
|
||||
"ShirtSlot",
|
||||
"TabardSlot",
|
||||
"WristSlot",
|
||||
"HandsSlot",
|
||||
"WaistSlot",
|
||||
"LegsSlot",
|
||||
"FeetSlot",
|
||||
"Finger0Slot",
|
||||
"Finger1Slot",
|
||||
"Trinket0Slot",
|
||||
"Trinket1Slot",
|
||||
"MainHandSlot",
|
||||
"SecondaryHandSlot",
|
||||
"RangedSlot"
|
||||
}
|
||||
|
||||
for _, slot in pairs(slots) do
|
||||
local icon = _G["Inspect"..slot.."IconTexture"]
|
||||
local slot = _G["Inspect"..slot]
|
||||
|
||||
E:StripTextures(slot)
|
||||
E:StyleButton(slot, false)
|
||||
E:SetTemplate(slot, "Default", true)
|
||||
|
||||
icon:SetTexCoord(unpack(E.TexCoords))
|
||||
E:SetInside(icon)
|
||||
end
|
||||
|
||||
hooksecurefunc("InspectPaperDollItemSlotButton_Update", function(button)
|
||||
if button.hasItem then
|
||||
local itemLink = GetInventoryItemLink(InspectFrame.unit, button:GetID())
|
||||
if itemLink then
|
||||
local _, _, quality = GetItemInfo(match(itemLink, "item:(%d+)"))
|
||||
if not quality then
|
||||
E:Delay(0.1, function()
|
||||
if InspectFrame.unit then
|
||||
InspectPaperDollItemSlotButton_Update(button)
|
||||
end
|
||||
end)
|
||||
return
|
||||
elseif quality then
|
||||
button:SetBackdropBorderColor(GetItemQualityColor(quality))
|
||||
return
|
||||
end
|
||||
end
|
||||
end
|
||||
button:SetBackdropBorderColor(unpack(E.media.bordercolor))
|
||||
end)
|
||||
|
||||
S:HandleRotateButton(InspectModelRotateLeftButton)
|
||||
InspectModelRotateLeftButton:SetPoint("TOPLEFT", 3, -3)
|
||||
|
||||
S:HandleRotateButton(InspectModelRotateRightButton)
|
||||
InspectModelRotateRightButton:SetPoint("TOPLEFT", InspectModelRotateLeftButton, "TOPRIGHT", 3, 0)
|
||||
|
||||
E:StripTextures(InspectHonorFrame)
|
||||
|
||||
InspectHonorFrameProgressBar:SetStatusBarTexture(E.media.normTex)
|
||||
E:RegisterStatusBar(InspectHonorFrameProgressBar)
|
||||
end
|
||||
|
||||
S:AddCallbackForAddon("Blizzard_InspectUI", "Inspect", LoadSkin)
|
||||
@@ -0,0 +1,38 @@
|
||||
<Ui xmlns="http://www.blizzard.com/wow/ui/">
|
||||
<Script file="AuctionHouse.lua"/>
|
||||
<Script file="Battlefield.lua"/>
|
||||
<Script file="Bags.lua"/>
|
||||
<Script file="BGScore.lua"/>
|
||||
<Script file="Binding.lua"/>
|
||||
<Script file="Character.lua"/>
|
||||
<Script file="Craft.lua"/>
|
||||
<Script file="Debug.lua"/>
|
||||
<Script file="DressingRoom.lua"/>
|
||||
<Script file="Friends.lua"/>
|
||||
<Script file="Gossip.lua"/>
|
||||
<Script file="Greeting.lua"/>
|
||||
<Script file="GuildRegistrar.lua"/>
|
||||
<Script file="Help.lua"/>
|
||||
<Script file="Inspect.lua"/>
|
||||
<Script file="Loot.lua"/>
|
||||
<Script file="Macro.lua"/>
|
||||
<Script file="Mail.lua"/>
|
||||
<Script file="Merchant.lua"/>
|
||||
<Script file="MirrorTimers.lua"/>
|
||||
<Script file="Misc.lua"/>
|
||||
<Script file="Petition.lua"/>
|
||||
<Script file="Quest.lua"/>
|
||||
<Script file="QuestTimers.lua"/>
|
||||
<Script file="Raid.lua"/>
|
||||
<Script file="SpellBook.lua"/>
|
||||
<Script file="Stable.lua"/>
|
||||
<Script file="Tabard.lua"/>
|
||||
<Script file="Talent.lua"/>
|
||||
<Script file="Taxi.lua"/>
|
||||
<Script file="Tooltip.lua"/>
|
||||
<Script file="Trade.lua"/>
|
||||
<Script file="TradeSkill.lua"/>
|
||||
<Script file="Trainer.lua"/>
|
||||
<Script file="Tutorial.lua"/>
|
||||
<Script file="WorldMap.lua"/>
|
||||
</Ui>
|
||||
@@ -0,0 +1,142 @@
|
||||
local E, L, V, P, G = unpack(ElvUI); --Import: Engine, Locales, PrivateDB, ProfileDB, GlobalDB
|
||||
local S = E:GetModule("Skins");
|
||||
|
||||
--Cache global variables
|
||||
--Lua functions
|
||||
local _G = _G
|
||||
local unpack = unpack
|
||||
local match = string.match
|
||||
--WoW API / Variables
|
||||
local UnitName = UnitName
|
||||
local IsFishingLoot = IsFishingLoot
|
||||
local GetLootRollItemInfo = GetLootRollItemInfo
|
||||
local GetItemQualityColor = GetItemQualityColor
|
||||
local LOOTFRAME_NUMBUTTONS = LOOTFRAME_NUMBUTTONS
|
||||
local NUM_GROUP_LOOT_FRAMES = NUM_GROUP_LOOT_FRAMES
|
||||
local LOOT = LOOT
|
||||
|
||||
local function LoadSkin()
|
||||
if E.private.general.loot then return end
|
||||
if E.private.skins.blizzard.enable ~= true or E.private.skins.blizzard.loot ~= true then return end
|
||||
|
||||
E:StripTextures(LootFrame)
|
||||
|
||||
E:CreateBackdrop(LootFrame, "Transparent")
|
||||
LootFrame.backdrop:SetPoint("TOPLEFT", 13, -14)
|
||||
LootFrame.backdrop:SetPoint("BOTTOMRIGHT", -68, 5)
|
||||
|
||||
LootFramePortraitOverlay:SetParent(E.HiddenFrame)
|
||||
|
||||
S:HandleCloseButton(LootCloseButton)
|
||||
|
||||
--[[for i = 1, LootFrame:GetNumRegions() do
|
||||
local region = select(i, LootFrame:GetRegions())
|
||||
if region:GetObjectType() == "FontString" then
|
||||
if region:GetText() == ITEMS then
|
||||
LootFrame.Title = region
|
||||
end
|
||||
end
|
||||
end]]
|
||||
|
||||
--[[LootFrame.Title:ClearAllPoints()
|
||||
LootFrame.Title:SetPoint("TOPLEFT", LootFrame.backdrop, "TOPLEFT", 4, -4)
|
||||
LootFrame.Title:SetJustifyH("LEFT")]]
|
||||
|
||||
S:HandleNextPrevButton(LootFrameDownButton)
|
||||
S:HandleNextPrevButton(LootFrameUpButton)
|
||||
S:SquareButton_SetIcon(LootFrameUpButton, "UP")
|
||||
S:SquareButton_SetIcon(LootFrameDownButton, "DOWN")
|
||||
|
||||
LootFrameDownButton:ClearAllPoints()
|
||||
LootFrameDownButton:SetPoint("RIGHT", LootFrameNext, "RIGHT", 32, 0)
|
||||
LootFramePrev:SetPoint("BOTTOMLEFT", 57, 22)
|
||||
|
||||
hooksecurefunc("LootFrame_Update", function()
|
||||
local numLootItems = LootFrame.numLootItems
|
||||
local numLootToShow = LOOTFRAME_NUMBUTTONS
|
||||
if numLootItems > LOOTFRAME_NUMBUTTONS then
|
||||
numLootToShow = numLootToShow - 1
|
||||
end
|
||||
for i = 1, LOOTFRAME_NUMBUTTONS do
|
||||
local slot = (((LootFrame.page - 1) * numLootToShow) + i)
|
||||
local lootButton = _G["LootButton"..i]
|
||||
local lootButtonIcon = _G["LootButton"..i.."IconTexture"]
|
||||
|
||||
S:HandleItemButton(lootButton, true)
|
||||
|
||||
if slot <= numLootItems then
|
||||
local itemLink = GetLootSlotLink(slot)
|
||||
if itemLink then
|
||||
local _, _, quality = GetItemInfo(match(itemLink, "item:(%d+)"))
|
||||
if quality then
|
||||
lootButton.backdrop:SetBackdropBorderColor(GetItemQualityColor(quality))
|
||||
else
|
||||
lootButton.backdrop:SetBackdropBorderColor(unpack(E["media"].bordercolor))
|
||||
end
|
||||
else
|
||||
lootButton.backdrop:SetBackdropBorderColor(unpack(E["media"].bordercolor))
|
||||
end
|
||||
end
|
||||
end
|
||||
end)
|
||||
|
||||
--[[HookScript(LootFrame, "OnShow", function()
|
||||
if IsFishingLoot() then
|
||||
this.Title:SetText(L["Fishy Loot"])
|
||||
elseif not UnitIsFriend("player", "target") and UnitIsDead("target") then
|
||||
this.Title:SetText(UnitName("target"))
|
||||
else
|
||||
this.Title:SetText(LOOT)
|
||||
end
|
||||
end)--]]
|
||||
end
|
||||
|
||||
local function LoadRollSkin()
|
||||
if E.private.general.lootRoll then return end
|
||||
if not E.private.skins.blizzard.enable or not E.private.skins.blizzard.lootRoll then return end
|
||||
|
||||
local function OnShow(self)
|
||||
E:SetTemplate(self, "Transparent")
|
||||
|
||||
local cornerTexture = _G[self:GetName().."Corner"]
|
||||
cornerTexture:SetTexture()
|
||||
|
||||
local iconFrame = _G[self:GetName().."IconFrame"]
|
||||
local _, _, _, quality = GetLootRollItemInfo(self.rollID)
|
||||
iconFrame:SetBackdropBorderColor(GetItemQualityColor(quality))
|
||||
end
|
||||
|
||||
for i = 1, NUM_GROUP_LOOT_FRAMES do
|
||||
local frame = _G["GroupLootFrame"..i]
|
||||
frame:SetParent(UIParent)
|
||||
E:StripTextures(frame)
|
||||
|
||||
local frameName = frame:GetName()
|
||||
local iconFrame = _G[frameName.."IconFrame"]
|
||||
E:SetTemplate(iconFrame, "Default")
|
||||
|
||||
local icon = _G[frameName.."IconFrameIcon"]
|
||||
E:SetInside(icon)
|
||||
icon:SetTexCoord(unpack(E.TexCoords))
|
||||
|
||||
local statusBar = _G[frameName.."Timer"]
|
||||
E:StripTextures(statusBar)
|
||||
E:CreateBackdrop(statusBar, "Default")
|
||||
statusBar:SetStatusBarTexture(E["media"].normTex)
|
||||
E:RegisterStatusBar(statusBar)
|
||||
|
||||
local decoration = _G[frameName.."Decoration"]
|
||||
decoration:SetTexture("Interface\\DialogFrame\\UI-DialogBox-Gold-Dragon")
|
||||
decoration:SetWidth(130)
|
||||
decoration:SetHeight(130)
|
||||
decoration:SetPoint("TOPLEFT", -37, 20)
|
||||
|
||||
local pass = _G[frameName.."PassButton"]
|
||||
S:HandleCloseButton(pass, frame)
|
||||
|
||||
HookScript(_G["GroupLootFrame"..i], "OnShow", OnShow)
|
||||
end
|
||||
end
|
||||
|
||||
S:AddCallback("Loot", LoadSkin)
|
||||
S:AddCallback("LootRoll", LoadRollSkin)
|
||||
@@ -0,0 +1,100 @@
|
||||
local E, L, V, P, G = unpack(ElvUI); --Import: Engine, Locales, PrivateDB, ProfileDB, GlobalDB
|
||||
local S = E:GetModule("Skins");
|
||||
|
||||
--Cache global variables
|
||||
--Lua functions
|
||||
local _G = _G
|
||||
local unpack = unpack
|
||||
local getn = table.getn
|
||||
--WoW API / Variables
|
||||
|
||||
local function LoadSkin()
|
||||
if E.private.skins.blizzard.enable ~= true or E.private.skins.blizzard.macro ~= true then return end
|
||||
|
||||
E:StripTextures(MacroFrame)
|
||||
E:CreateBackdrop(MacroFrame, "Transparent")
|
||||
MacroFrame.backdrop:SetPoint("TOPLEFT", 10, -11)
|
||||
MacroFrame.backdrop:SetPoint("BOTTOMRIGHT", -32, 71)
|
||||
|
||||
MacroFrame.bg = CreateFrame("Frame", nil, MacroFrame)
|
||||
E:SetTemplate(MacroFrame.bg, "Transparent", true)
|
||||
MacroFrame.bg:SetPoint("TOPLEFT", MacroButton1, -10, 10)
|
||||
MacroFrame.bg:SetPoint("BOTTOMRIGHT", MacroButton18, 10, -10)
|
||||
|
||||
E:StripTextures(MacroFrameTextBackground)
|
||||
E:CreateBackdrop(MacroFrameTextBackground, "Default")
|
||||
MacroFrameTextBackground.backdrop:SetPoint("TOPLEFT", 6, -3)
|
||||
MacroFrameTextBackground.backdrop:SetPoint("BOTTOMRIGHT", -2, 3)
|
||||
|
||||
local Buttons = {
|
||||
"MacroFrameTab1",
|
||||
"MacroFrameTab2",
|
||||
"MacroDeleteButton",
|
||||
"MacroNewButton",
|
||||
"MacroExitButton",
|
||||
"MacroEditButton",
|
||||
"MacroPopupOkayButton",
|
||||
"MacroPopupCancelButton"
|
||||
}
|
||||
|
||||
for i = 1, getn(Buttons) do
|
||||
E:StripTextures(_G[Buttons[i]])
|
||||
S:HandleButton(_G[Buttons[i]])
|
||||
end
|
||||
|
||||
for i = 1, 2 do
|
||||
local tab = _G["MacroFrameTab"..i]
|
||||
|
||||
tab:SetHeight(22)
|
||||
end
|
||||
|
||||
MacroFrameTab1:SetPoint("TOPLEFT", MacroFrame, "TOPLEFT", 85, -39)
|
||||
MacroFrameTab2:SetPoint("LEFT", MacroFrameTab1, "RIGHT", 4, 0)
|
||||
|
||||
S:HandleCloseButton(MacroFrameCloseButton)
|
||||
|
||||
S:HandleScrollBar(MacroFrameScrollFrameScrollBar)
|
||||
S:HandleScrollBar(MacroPopupScrollFrameScrollBar)
|
||||
|
||||
MacroEditButton:ClearAllPoints()
|
||||
MacroEditButton:SetPoint("BOTTOMLEFT", MacroFrameSelectedMacroButton, "BOTTOMRIGHT", 10, 0)
|
||||
|
||||
MacroFrameSelectedMacroName:SetPoint("TOPLEFT", MacroFrameSelectedMacroBackground, "TOPRIGHT", -4, -10)
|
||||
|
||||
E:StripTextures(MacroFrameSelectedMacroButton)
|
||||
E:SetTemplate(MacroFrameSelectedMacroButton, "Transparent")
|
||||
E:StyleButton(MacroFrameSelectedMacroButton, true)
|
||||
MacroFrameSelectedMacroButton:GetNormalTexture():SetTexture(nil)
|
||||
|
||||
MacroFrameSelectedMacroButtonIcon:SetTexCoord(unpack(E.TexCoords))
|
||||
E:SetInside(MacroFrameSelectedMacroButtonIcon)
|
||||
|
||||
MacroFrameCharLimitText:ClearAllPoints()
|
||||
MacroFrameCharLimitText:SetPoint("BOTTOM", MacroFrameTextBackground, 0, -9)
|
||||
|
||||
for i = 1, MAX_MACROS do
|
||||
local Button = _G["MacroButton"..i]
|
||||
local ButtonIcon = _G["MacroButton"..i.."Icon"]
|
||||
|
||||
if Button then
|
||||
E:StripTextures(Button)
|
||||
E:SetTemplate(Button, "Default", true)
|
||||
E:StyleButton(Button, nil, true)
|
||||
end
|
||||
|
||||
if ButtonIcon then
|
||||
ButtonIcon:SetTexCoord(unpack(E.TexCoords))
|
||||
E:SetInside(ButtonIcon)
|
||||
end
|
||||
end
|
||||
|
||||
S:HandleIconSelectionFrame(MacroPopupFrame, NUM_MACRO_ICONS_SHOWN, "MacroPopupButton", "MacroPopup")
|
||||
|
||||
E:CreateBackdrop(MacroPopupScrollFrame, "Transparent")
|
||||
MacroPopupScrollFrame.backdrop:SetPoint("TOPLEFT", 51, 2)
|
||||
MacroPopupScrollFrame.backdrop:SetPoint("BOTTOMRIGHT", 0, 4)
|
||||
|
||||
MacroPopupFrame:SetPoint("TOPLEFT", MacroFrame, "TOPRIGHT", -41, 1)
|
||||
end
|
||||
|
||||
S:AddCallbackForAddon("Blizzard_MacroUI", "Macro", LoadSkin)
|
||||
@@ -0,0 +1,229 @@
|
||||
local E, L, V, P, G = unpack(ElvUI); --Import: Engine, Locales, PrivateDB, ProfileDB, GlobalDB
|
||||
local S = E:GetModule("Skins");
|
||||
|
||||
--Cache global variables
|
||||
--Lua functions
|
||||
local _G = _G
|
||||
local unpack = unpack
|
||||
--WoW API / Variables
|
||||
local GetInboxItem = GetInboxItem
|
||||
local GetItemInfo = GetItemInfo
|
||||
local GetItemQualityColor = GetItemQualityColor
|
||||
local GetSendMailItem = GetSendMailItem
|
||||
local hooksecurefunc = hooksecurefunc
|
||||
local INBOXITEMS_TO_DISPLAY = INBOXITEMS_TO_DISPLAY
|
||||
|
||||
local function LoadSkin()
|
||||
if E.private.skins.blizzard.enable ~= true or E.private.skins.blizzard.mail ~= true then return end
|
||||
|
||||
-- Inbox Frame
|
||||
E:StripTextures(MailFrame, true)
|
||||
E:CreateBackdrop(MailFrame, "Transparent")
|
||||
MailFrame.backdrop:SetPoint("TOPLEFT", 10, -12)
|
||||
MailFrame.backdrop:SetPoint("BOTTOMRIGHT", -30, 74)
|
||||
|
||||
for i = 1, INBOXITEMS_TO_DISPLAY do
|
||||
local mail = _G["MailItem"..i]
|
||||
local button = _G["MailItem"..i.."Button"]
|
||||
local icon = _G["MailItem"..i.."ButtonIcon"]
|
||||
|
||||
E:StripTextures(mail)
|
||||
E:CreateBackdrop(mail, "Default")
|
||||
mail.backdrop:SetPoint("TOPLEFT", 2, 1)
|
||||
mail.backdrop:SetPoint("BOTTOMRIGHT", -2, 2)
|
||||
|
||||
E:StripTextures(button)
|
||||
E:SetTemplate(button, "Default", true)
|
||||
E:StyleButton(button)
|
||||
|
||||
icon:SetTexCoord(unpack(E.TexCoords))
|
||||
E:SetInside(icon)
|
||||
end
|
||||
|
||||
hooksecurefunc("InboxFrame_Update", function()
|
||||
local numItems = GetInboxNumItems()
|
||||
local index = ((InboxFrame.pageNum - 1) * INBOXITEMS_TO_DISPLAY) + 1
|
||||
|
||||
for i = 1, INBOXITEMS_TO_DISPLAY do
|
||||
if index <= numItems then
|
||||
local packageIcon, _, _, _, _, _, _, _, _, _, _, _, isGM = GetInboxHeaderInfo(index)
|
||||
local button = _G["MailItem"..i.."Button"]
|
||||
|
||||
button:SetBackdropBorderColor(unpack(E["media"].bordercolor))
|
||||
if packageIcon and not isGM then
|
||||
local itemName = GetInboxItem(index)
|
||||
if itemName then
|
||||
local _, itemString = GetItemInfoByName(itemName)
|
||||
local _, _, quality = GetItemInfo(itemString, "item:(%d+)")
|
||||
if quality then
|
||||
button:SetBackdropBorderColor(GetItemQualityColor(quality))
|
||||
else
|
||||
button:SetBackdropBorderColor(unpack(E["media"].bordercolor))
|
||||
end
|
||||
end
|
||||
elseif isGM then
|
||||
button:SetBackdropBorderColor(0, 0.56, 0.94)
|
||||
end
|
||||
end
|
||||
|
||||
index = index + 1
|
||||
end
|
||||
end)
|
||||
|
||||
S:HandleNextPrevButton(InboxPrevPageButton)
|
||||
S:HandleNextPrevButton(InboxNextPageButton)
|
||||
|
||||
S:HandleCloseButton(InboxCloseButton)
|
||||
|
||||
for i = 1, 2 do
|
||||
local tab = _G["MailFrameTab"..i]
|
||||
|
||||
E:StripTextures(tab)
|
||||
S:HandleTab(tab)
|
||||
end
|
||||
|
||||
-- Send Mail Frame
|
||||
E:StripTextures(SendMailFrame)
|
||||
|
||||
E:StripTextures(SendMailScrollFrame, true)
|
||||
E:SetTemplate(SendMailScrollFrame, "Default")
|
||||
|
||||
hooksecurefunc("SendMailFrame_Update", function()
|
||||
if not SendMailPackageButton.skinned then
|
||||
E:StripTextures(SendMailPackageButton)
|
||||
E:SetTemplate(SendMailPackageButton, "Default", true)
|
||||
E:StyleButton(SendMailPackageButton, nil, true)
|
||||
|
||||
SendMailPackageButton.skinned = true
|
||||
end
|
||||
|
||||
local itemName = GetSendMailItem()
|
||||
if itemName then
|
||||
local _, _, _, quality = GetSendMailItem()
|
||||
if quality then
|
||||
SendMailPackageButton:SetBackdropBorderColor(GetItemQualityColor(quality))
|
||||
else
|
||||
SendMailPackageButton:SetBackdropBorderColor(unpack(E["media"].bordercolor))
|
||||
end
|
||||
SendMailPackageButton:GetNormalTexture():SetTexCoord(unpack(E.TexCoords))
|
||||
E:SetInside(SendMailPackageButton:GetNormalTexture())
|
||||
else
|
||||
SendMailPackageButton:SetBackdropBorderColor(unpack(E["media"].bordercolor))
|
||||
end
|
||||
end)
|
||||
|
||||
SendMailBodyEditBox:SetTextColor(1, 1, 1)
|
||||
|
||||
S:HandleScrollBar(SendMailScrollFrameScrollBar)
|
||||
|
||||
S:HandleEditBox(SendMailNameEditBox)
|
||||
SendMailNameEditBox.backdrop:SetPoint("BOTTOMRIGHT", 2, 0)
|
||||
SendMailNameEditBox:SetPoint("TOPLEFT", 79, -46)
|
||||
|
||||
S:HandleEditBox(SendMailSubjectEditBox)
|
||||
SendMailSubjectEditBox.backdrop:SetPoint("BOTTOMRIGHT", 2, 0)
|
||||
|
||||
S:HandleEditBox(SendMailMoneyGold)
|
||||
S:HandleEditBox(SendMailMoneySilver)
|
||||
S:HandleEditBox(SendMailMoneyCopper)
|
||||
|
||||
S:HandleButton(SendMailMailButton)
|
||||
SendMailMailButton:SetPoint("RIGHT", SendMailCancelButton, "LEFT", -2, 0)
|
||||
|
||||
S:HandleButton(SendMailCancelButton)
|
||||
SendMailCancelButton:SetPoint("BOTTOMRIGHT", -45, 80)
|
||||
|
||||
SendMailMoneyFrame:SetPoint("BOTTOMLEFT", 170, 84)
|
||||
|
||||
-- Open Mail Frame
|
||||
E:StripTextures(OpenMailFrame, true)
|
||||
E:CreateBackdrop(OpenMailFrame, "Transparent")
|
||||
OpenMailFrame.backdrop:SetPoint("TOPLEFT", 12, -12)
|
||||
OpenMailFrame.backdrop:SetPoint("BOTTOMRIGHT", -34, 74)
|
||||
|
||||
E:StripTextures(OpenMailPackageButton)
|
||||
E:StyleButton(OpenMailPackageButton)
|
||||
E:SetTemplate(OpenMailPackageButton, "Default", true)
|
||||
|
||||
for _, region in ipairs({OpenMailPackageButton:GetRegions()}) do
|
||||
if region:GetObjectType() == "Texture" then
|
||||
region:SetTexCoord(unpack(E.TexCoords))
|
||||
E:SetInside(region)
|
||||
end
|
||||
end
|
||||
|
||||
--[[for i = 1, OpenMailPackageButton:GetNumRegions() do
|
||||
local region = select(i, OpenMailPackageButton:GetRegions())
|
||||
if region:GetObjectType() == "Texture" then
|
||||
region:SetTexCoord(unpack(E.TexCoords))
|
||||
E:SetInside(region)
|
||||
end
|
||||
end]]
|
||||
|
||||
hooksecurefunc("OpenMail_Update", function()
|
||||
local index = InboxFrame.openMailID
|
||||
if not index then return end
|
||||
|
||||
local _, stationeryIcon, _, _, _, _, _, hasItem = GetInboxHeaderInfo(index)
|
||||
|
||||
if hasItem then
|
||||
local itemName = GetInboxItem(index)
|
||||
if itemName then
|
||||
local _, itemString = GetItemInfoByName(itemName)
|
||||
local _, _, quality = GetItemInfo(itemString, "item:(%d+)")
|
||||
if quality then
|
||||
OpenMailPackageButton:SetBackdropBorderColor(GetItemQualityColor(quality))
|
||||
else
|
||||
OpenMailPackageButton:SetBackdropBorderColor(unpack(E["media"].bordercolor))
|
||||
end
|
||||
OpenMailPackageButton:GetNormalTexture():SetTexCoord(unpack(E.TexCoords))
|
||||
E:SetInside(OpenMailPackageButton:GetNormalTexture())
|
||||
else
|
||||
OpenMailPackageButton:SetBackdropBorderColor(unpack(E["media"].bordercolor))
|
||||
end
|
||||
end
|
||||
end)
|
||||
|
||||
S:HandleCloseButton(OpenMailCloseButton)
|
||||
|
||||
S:HandleButton(OpenMailReplyButton)
|
||||
OpenMailReplyButton:SetPoint("RIGHT", OpenMailDeleteButton, "LEFT", -2, 0)
|
||||
|
||||
S:HandleButton(OpenMailDeleteButton)
|
||||
OpenMailDeleteButton:SetPoint("RIGHT", OpenMailCancelButton, "LEFT", -2, 0)
|
||||
|
||||
S:HandleButton(OpenMailCancelButton)
|
||||
|
||||
E:StripTextures(OpenMailScrollFrame, true)
|
||||
E:SetTemplate(OpenMailScrollFrame, "Default")
|
||||
|
||||
S:HandleScrollBar(OpenMailScrollFrameScrollBar)
|
||||
|
||||
OpenMailBodyText:SetTextColor(1, 1, 1)
|
||||
InvoiceTextFontNormal:SetTextColor(1, 1, 1)
|
||||
OpenMailInvoiceBuyMode:SetTextColor(1, 0.80, 0.10)
|
||||
|
||||
E:Kill(OpenMailArithmeticLine)
|
||||
|
||||
E:StripTextures(OpenMailLetterButton)
|
||||
E:SetTemplate(OpenMailLetterButton, "Default", true)
|
||||
E:StyleButton(OpenMailLetterButton)
|
||||
|
||||
OpenMailLetterButtonIconTexture:SetTexCoord(unpack(E.TexCoords))
|
||||
OpenMailLetterButtonIconTexture:SetDrawLayer("ARTWORK")
|
||||
E:SetInside(OpenMailLetterButtonIconTexture)
|
||||
|
||||
OpenMailLetterButtonCount:SetDrawLayer("OVERLAY")
|
||||
|
||||
E:StripTextures(OpenMailMoneyButton)
|
||||
E:SetTemplate(OpenMailMoneyButton, "Default", true)
|
||||
E:StyleButton(OpenMailMoneyButton)
|
||||
|
||||
OpenMailMoneyButtonIconTexture:SetTexCoord(unpack(E.TexCoords))
|
||||
OpenMailMoneyButtonIconTexture:SetDrawLayer("ARTWORK")
|
||||
E:SetInside(OpenMailMoneyButtonIconTexture)
|
||||
|
||||
OpenMailMoneyButtonCount:SetDrawLayer("OVERLAY")
|
||||
end
|
||||
|
||||
S:AddCallback("Mail", LoadSkin)
|
||||
@@ -0,0 +1,151 @@
|
||||
local E, L, V, P, G = unpack(ElvUI); --Import: Engine, Locales, PrivateDB, ProfileDB, GlobalDB
|
||||
local S = E:GetModule("Skins");
|
||||
|
||||
--Cache global variables
|
||||
--Lua functions
|
||||
local _G = _G
|
||||
local unpack = unpack
|
||||
local match, split = string.match, string.split
|
||||
--WoW API / Variables
|
||||
local GetBuybackItemInfo = GetBuybackItemInfo
|
||||
local GetItemInfo = GetItemInfo
|
||||
local GetItemQualityColor = GetItemQualityColor
|
||||
local GetMerchantItemLink = GetMerchantItemLink
|
||||
local GetItemLinkByName = GetItemLinkByName
|
||||
local hooksecurefunc = hooksecurefunc
|
||||
|
||||
local function LoadSkin()
|
||||
if E.private.skins.blizzard.enable ~= true or E.private.skins.blizzard.merchant ~= true then return end
|
||||
|
||||
E:StripTextures(MerchantFrame, true)
|
||||
E:CreateBackdrop(MerchantFrame, "Transparent")
|
||||
MerchantFrame.backdrop:SetPoint("TOPLEFT", 10, -11)
|
||||
MerchantFrame.backdrop:SetPoint("BOTTOMRIGHT", -28, 60)
|
||||
|
||||
S:HandleCloseButton(MerchantFrameCloseButton, MerchantFrame.backdrop)
|
||||
|
||||
for i = 1, 12 do
|
||||
local item = _G["MerchantItem"..i]
|
||||
local itemButton = _G["MerchantItem"..i.."ItemButton"]
|
||||
local iconTexture = _G["MerchantItem"..i.."ItemButtonIconTexture"]
|
||||
local altCurrencyTex1 = _G["MerchantItem"..i.."AltCurrencyFrameItem1Texture"]
|
||||
local altCurrencyTex2 = _G["MerchantItem"..i.."AltCurrencyFrameItem2Texture"]
|
||||
|
||||
E:StripTextures(item, true)
|
||||
E:CreateBackdrop(item, "Default")
|
||||
|
||||
E:StripTextures(itemButton)
|
||||
E:StyleButton(itemButton)
|
||||
E:SetTemplate(itemButton, "Default", true)
|
||||
itemButton:SetPoint("TOPLEFT", item, "TOPLEFT", 4, -4)
|
||||
|
||||
iconTexture:SetTexCoord(unpack(E.TexCoords))
|
||||
E:SetInside(iconTexture)
|
||||
|
||||
_G["MerchantItem"..i.."MoneyFrame"]:ClearAllPoints()
|
||||
_G["MerchantItem"..i.."MoneyFrame"]:SetPoint("BOTTOMLEFT", itemButton, "BOTTOMRIGHT", 3, 0)
|
||||
end
|
||||
|
||||
S:HandleNextPrevButton(MerchantNextPageButton)
|
||||
S:HandleNextPrevButton(MerchantPrevPageButton)
|
||||
|
||||
E:StyleButton(MerchantRepairItemButton)
|
||||
E:SetTemplate(MerchantRepairItemButton, "Default", true)
|
||||
|
||||
for _, region in ipairs({MerchantRepairItemButton:GetRegions()}) do
|
||||
if region:GetObjectType() == "Texture" then
|
||||
region:SetTexCoord(0.04, 0.24, 0.06, 0.5)
|
||||
E:SetInside(region)
|
||||
end
|
||||
end
|
||||
|
||||
--[[for i = 1, MerchantRepairItemButton:GetNumRegions() do
|
||||
local region = select(i, MerchantRepairItemButton:GetRegions())
|
||||
if region:GetObjectType() == "Texture" then
|
||||
region:SetTexCoord(0.04, 0.24, 0.06, 0.5)
|
||||
E:SetInside(region)
|
||||
end
|
||||
end--]]
|
||||
|
||||
E:StyleButton(MerchantRepairAllButton)
|
||||
E:SetTemplate(MerchantRepairAllButton, "Default", true)
|
||||
MerchantRepairAllIcon:SetTexCoord(0.34, 0.1, 0.34, 0.535, 0.535, 0.1, 0.535, 0.535)
|
||||
E:SetInside(MerchantRepairAllIcon)
|
||||
|
||||
E:StripTextures(MerchantBuyBackItem, true)
|
||||
E:CreateBackdrop(MerchantBuyBackItem, "Transparent")
|
||||
MerchantBuyBackItem.backdrop:SetPoint("TOPLEFT", -6, 6)
|
||||
MerchantBuyBackItem.backdrop:SetPoint("BOTTOMRIGHT", 6, -6)
|
||||
|
||||
E:StripTextures(MerchantBuyBackItemItemButton)
|
||||
E:StyleButton(MerchantBuyBackItemItemButton)
|
||||
E:SetTemplate(MerchantBuyBackItemItemButton, "Default", true)
|
||||
MerchantBuyBackItemItemButtonIconTexture:SetTexCoord(unpack(E.TexCoords))
|
||||
E:SetInside(MerchantBuyBackItemItemButtonIconTexture)
|
||||
|
||||
for i = 1, 2 do
|
||||
S:HandleTab(_G["MerchantFrameTab"..i])
|
||||
end
|
||||
|
||||
hooksecurefunc("MerchantFrame_UpdateMerchantInfo", function()
|
||||
local numMerchantItems = GetMerchantNumItems()
|
||||
for i = 1, MERCHANT_ITEMS_PER_PAGE do
|
||||
local index = (((MerchantFrame.page - 1) * MERCHANT_ITEMS_PER_PAGE) + i)
|
||||
local itemButton = _G["MerchantItem"..i.."ItemButton"]
|
||||
local itemName = _G["MerchantItem"..i.."Name"]
|
||||
|
||||
if index <= numMerchantItems then
|
||||
local itemLink = GetMerchantItemLink(index)
|
||||
if itemLink then
|
||||
local _, _, quality = GetItemInfo(match(itemLink, "item:(%d+)"))
|
||||
if quality then
|
||||
itemName:SetTextColor(GetItemQualityColor(quality))
|
||||
itemButton:SetBackdropBorderColor(GetItemQualityColor(quality))
|
||||
else
|
||||
itemButton:SetBackdropBorderColor(unpack(E["media"].bordercolor))
|
||||
end
|
||||
else
|
||||
itemButton:SetBackdropBorderColor(unpack(E["media"].bordercolor))
|
||||
end
|
||||
end
|
||||
|
||||
HookScript(MerchantBuyBackItemItemButton, "OnEvent", function()
|
||||
this:SetBackdropBorderColor(unpack(E["media"].bordercolor))
|
||||
end)
|
||||
|
||||
local buybackName = GetBuybackItemInfo(GetNumBuybackItems())
|
||||
if buybackName then
|
||||
local _, _, quality = GetItemInfoByName(buybackName)
|
||||
if quality then
|
||||
MerchantBuyBackItemName:SetTextColor(GetItemQualityColor(quality))
|
||||
MerchantBuyBackItemItemButton:SetBackdropBorderColor(GetItemQualityColor(quality))
|
||||
else
|
||||
MerchantBuyBackItemItemButton:SetBackdropBorderColor(unpack(E["media"].bordercolor))
|
||||
end
|
||||
end
|
||||
end
|
||||
end)
|
||||
|
||||
hooksecurefunc("MerchantFrame_UpdateBuybackInfo", function()
|
||||
local numBuybackItems = GetNumBuybackItems()
|
||||
for i = 1, BUYBACK_ITEMS_PER_PAGE do
|
||||
local itemButton = _G["MerchantItem"..i.."ItemButton"]
|
||||
local itemName = _G["MerchantItem"..i.."Name"]
|
||||
|
||||
if i <= numBuybackItems then
|
||||
local buybackName = GetBuybackItemInfo(i)
|
||||
if buybackName then
|
||||
local _, _, quality = GetItemInfoByName(buybackName)
|
||||
if quality then
|
||||
itemName:SetTextColor(GetItemQualityColor(quality))
|
||||
itemButton:SetBackdropBorderColor(GetItemQualityColor(quality))
|
||||
else
|
||||
itemButton:SetBackdropBorderColor(unpack(E["media"].bordercolor))
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
end)
|
||||
end
|
||||
|
||||
S:AddCallback("Merchant", LoadSkin)
|
||||
@@ -0,0 +1,62 @@
|
||||
local E, L, V, P, G = unpack(ElvUI); --Import: Engine, Locales, PrivateDB, ProfileDB, GlobalDB
|
||||
local S = E:GetModule("Skins");
|
||||
|
||||
--Cache global variables
|
||||
--Lua functions
|
||||
local _G = _G
|
||||
local floor, format = math.floor, string.format
|
||||
--WoW API / Variables
|
||||
local hooksecurefunc = hooksecurefunc
|
||||
|
||||
local function LoadSkin()
|
||||
if E.private.skins.blizzard.enable ~= true or E.private.skins.blizzard.mirrorTimers ~= true then return end
|
||||
|
||||
hooksecurefunc("MirrorTimerFrame_OnUpdate", function(frame, elapsed)
|
||||
if frame.paused then
|
||||
return
|
||||
end
|
||||
|
||||
if frame.timeSinceUpdate >= 0.3 then
|
||||
local minutes = frame.value / 60
|
||||
local seconds = frame.value - floor(frame.value / 60) * 60
|
||||
local text = frame.label:GetText()
|
||||
|
||||
if frame.value > 0 then
|
||||
frame.TimerText:SetText(format("%s (%d:%02d)", text, minutes, seconds))
|
||||
else
|
||||
frame.TimerText:SetText(format("%s (0:00)", text))
|
||||
end
|
||||
frame.timeSinceUpdate = 0
|
||||
else
|
||||
frame.timeSinceUpdate = frame.timeSinceUpdate + elapsed
|
||||
end
|
||||
end)
|
||||
|
||||
for i = 1, MIRRORTIMER_NUMTIMERS do
|
||||
local mirrorTimer = _G["MirrorTimer"..i]
|
||||
local statusBar = _G["MirrorTimer"..i.."StatusBar"]
|
||||
local text = _G["MirrorTimer"..i.."Text"]
|
||||
|
||||
E:StripTextures(mirrorTimer)
|
||||
mirrorTimer:SetWidth(222)
|
||||
mirrorTimer:SetHeight(18)
|
||||
mirrorTimer.label = text
|
||||
statusBar:SetStatusBarTexture(E["media"].normTex)
|
||||
E:RegisterStatusBar(statusBar)
|
||||
E:CreateBackdrop(statusBar)
|
||||
statusBar:SetWidth(222)
|
||||
statusBar:SetHeight(18)
|
||||
text:Hide()
|
||||
|
||||
local TimerText = mirrorTimer:CreateFontString(nil, "OVERLAY")
|
||||
E:FontTemplate(TimerText)
|
||||
TimerText:SetPoint("CENTER", statusBar, "CENTER", 0, 0)
|
||||
mirrorTimer.TimerText = TimerText
|
||||
|
||||
mirrorTimer.timeSinceUpdate = 0.3
|
||||
|
||||
E:CreateMover(mirrorTimer, "MirrorTimer"..i.."Mover", L["MirrorTimer"]..i, nil, nil, nil, "ALL,SOLO")
|
||||
end
|
||||
end
|
||||
|
||||
S:AddCallback("MirrorTimers", LoadSkin)
|
||||
@@ -0,0 +1,456 @@
|
||||
local E, L, V, P, G = unpack(ElvUI); --Import: Engine, Locales, PrivateDB, ProfileDB, GlobalDB
|
||||
local S = E:GetModule("Skins");
|
||||
|
||||
--Cache global variables
|
||||
--Lua functions
|
||||
local _G = _G
|
||||
local unpack = unpack
|
||||
local find, getn = string.find, table.getn
|
||||
--WoW API / Variables
|
||||
local IsAddOnLoaded = IsAddOnLoaded
|
||||
local UnitIsUnit = UnitIsUnit
|
||||
local hooksecurefunc = hooksecurefunc
|
||||
|
||||
local function LoadSkin()
|
||||
if E.private.skins.blizzard.enable ~= true or E.private.skins.blizzard.misc ~= true then return end
|
||||
|
||||
-- Blizzard frame we want to reskin
|
||||
local skins = {
|
||||
"GameMenuFrame",
|
||||
"UIOptionsFrame",
|
||||
"OptionsFrame",
|
||||
"OptionsFrameDisplay",
|
||||
"OptionsFrameBrightness",
|
||||
"OptionsFrameWorldAppearance",
|
||||
"OptionsFramePixelShaders",
|
||||
"OptionsFrameMiscellaneous",
|
||||
"SoundOptionsFrame",
|
||||
"TicketStatusFrame",
|
||||
"StackSplitFrame"
|
||||
}
|
||||
|
||||
for i = 1, getn(skins) do
|
||||
E:SetTemplate(_G[skins[i]], "Transparent")
|
||||
end
|
||||
|
||||
-- ChatMenus
|
||||
local ChatMenus = {
|
||||
"ChatMenu",
|
||||
"EmoteMenu",
|
||||
"LanguageMenu",
|
||||
"VoiceMacroMenu",
|
||||
}
|
||||
|
||||
for i = 1, getn(ChatMenus) do
|
||||
if _G[ChatMenus[i]] == _G["ChatMenu"] then
|
||||
HookScript(_G[ChatMenus[i]], "OnShow", function()
|
||||
E:SetTemplate(this, "Transparent", true)
|
||||
this:SetBackdropColor(unpack(E["media"].backdropfadecolor))
|
||||
this:ClearAllPoints()
|
||||
this:SetPoint("BOTTOMLEFT", ChatFrame1, "TOPLEFT", 0, 35)
|
||||
end)
|
||||
else
|
||||
HookScript(_G[ChatMenus[i]], "OnShow", function()
|
||||
E:SetTemplate(this, "Transparent", true)
|
||||
this:SetBackdropColor(unpack(E["media"].backdropfadecolor))
|
||||
end)
|
||||
end
|
||||
end
|
||||
|
||||
local function StyleButton(f)
|
||||
local width, height = (f:GetWidth() * .54), f:GetHeight()
|
||||
|
||||
local left = f:CreateTexture(nil, "HIGHLIGHT")
|
||||
left:SetWidth(width)
|
||||
left:SetHeight(height)
|
||||
left:SetPoint("LEFT", f, "CENTER")
|
||||
left:SetTexture(1, 1, 1, 0.3)
|
||||
left:SetHeight(16)
|
||||
|
||||
local right = f:CreateTexture(nil, "HIGHLIGHT")
|
||||
right:SetWidth(width)
|
||||
right:SetHeight(height)
|
||||
right:SetPoint("RIGHT", f, "CENTER")
|
||||
right:SetTexture(1, 1, 1, 0.3)
|
||||
right:SetHeight(16)
|
||||
end
|
||||
|
||||
for i = 1, UIDROPDOWNMENU_MAXBUTTONS do
|
||||
StyleButton(_G["ChatMenuButton"..i])
|
||||
StyleButton(_G["EmoteMenuButton"..i])
|
||||
StyleButton(_G["LanguageMenuButton"..i])
|
||||
StyleButton(_G["VoiceMacroMenuButton"..i])
|
||||
end
|
||||
|
||||
-- UIDropDownMenu
|
||||
hooksecurefunc("UIDropDownMenu_Initialize", function()
|
||||
for i = 1, UIDROPDOWNMENU_MAXLEVELS do
|
||||
local buttonBackdrop = _G["DropDownList"..i.."Backdrop"]
|
||||
local buttonBackdropMenu = _G["DropDownList"..i.."MenuBackdrop"]
|
||||
|
||||
E:SetTemplate(buttonBackdrop, "Transparent")
|
||||
E:SetTemplate(buttonBackdropMenu, "Transparent")
|
||||
|
||||
for j = 1, UIDROPDOWNMENU_MAXBUTTONS do
|
||||
local button = _G["DropDownList"..i.."Button"..j]
|
||||
local buttonHighlight = _G["DropDownList"..i.."Button"..j.."Highlight"]
|
||||
|
||||
button:SetFrameLevel(buttonBackdrop:GetFrameLevel() + 1)
|
||||
buttonHighlight:SetTexture(1, 1, 1, 0.3)
|
||||
buttonHighlight:SetAllPoints(button)
|
||||
|
||||
if i == 1 then
|
||||
buttonHighlight:SetPoint("TOPLEFT", button, "TOPLEFT", -8, 0)
|
||||
buttonHighlight:SetPoint("TOPRIGHT", button, "TOPRIGHT", -8, 0)
|
||||
else
|
||||
buttonHighlight:SetPoint("TOPLEFT", button, "TOPLEFT", -4, 0)
|
||||
buttonHighlight:SetPoint("TOPRIGHT", button, "TOPRIGHT", -4, 0)
|
||||
end
|
||||
end
|
||||
end
|
||||
end)
|
||||
|
||||
-- L_UIDropDownMenu
|
||||
hooksecurefunc("L_UIDropDownMenu_Initialize", function()
|
||||
for i = 1, 2 do
|
||||
local buttonBackdrop = _G["L_DropDownList"..i.."Backdrop"]
|
||||
local buttonBackdropMenu = _G["L_DropDownList"..i.."MenuBackdrop"]
|
||||
|
||||
E:SetTemplate(buttonBackdrop, "Transparent")
|
||||
E:SetTemplate(buttonBackdropMenu, "Transparent")
|
||||
|
||||
if i == 2 then
|
||||
buttonBackdropMenu:SetPoint("TOPRIGHT", -4, 0)
|
||||
end
|
||||
|
||||
for j = 1, UIDROPDOWNMENU_MAXBUTTONS do
|
||||
local button = _G["L_DropDownList"..i.."Button"..j]
|
||||
local buttonHighlight = _G["L_DropDownList"..i.."Button"..j.."Highlight"]
|
||||
|
||||
button:SetFrameLevel(buttonBackdrop:GetFrameLevel() + 1)
|
||||
buttonHighlight:SetTexture(1, 1, 1, 0.3)
|
||||
buttonHighlight:SetAllPoints(button)
|
||||
|
||||
if i == 2 then
|
||||
buttonHighlight:SetPoint("TOPLEFT", button, "TOPLEFT", -8, 0)
|
||||
buttonHighlight:SetPoint("TOPRIGHT", button, "TOPRIGHT", 0, 0)
|
||||
end
|
||||
end
|
||||
end
|
||||
end)
|
||||
|
||||
-- Kill the nVidia logo
|
||||
local _, _, nVidiaLogo = OptionsFrame:GetRegions()
|
||||
if nVidiaLogo:GetObjectType() == "Texture" then
|
||||
E:Kill(nVidiaLogo)
|
||||
end
|
||||
|
||||
-- Static Popups
|
||||
for i = 1, STATICPOPUP_NUMDIALOGS do
|
||||
local staticPopup = _G["StaticPopup"..i]
|
||||
local itemFrameBox = _G["StaticPopup"..i.."EditBox"]
|
||||
local closeButton = _G["StaticPopup"..i.."CloseButton"]
|
||||
local wideBox = _G["StaticPopup"..i.."WideEditBox"]
|
||||
|
||||
E:SetTemplate(staticPopup, "Transparent")
|
||||
|
||||
itemFrameBox:DisableDrawLayer("BACKGROUND")
|
||||
|
||||
S:HandleEditBox(itemFrameBox)
|
||||
itemFrameBox.backdrop:SetPoint("TOPLEFT", -2, -4)
|
||||
itemFrameBox.backdrop:SetPoint("BOTTOMRIGHT", 2, 4)
|
||||
|
||||
E:StripTextures(closeButton)
|
||||
S:HandleCloseButton(closeButton)
|
||||
|
||||
local _, _, _, _, _, _, _, region = wideBox:GetRegions()
|
||||
if region then
|
||||
region:Hide()
|
||||
end
|
||||
--select(8, wideBox:GetRegions()):Hide()
|
||||
S:HandleEditBox(wideBox)
|
||||
wideBox:SetHeight(22)
|
||||
|
||||
for j = 1, 2 do
|
||||
S:HandleButton(_G["StaticPopup"..i.."Button"..j])
|
||||
end
|
||||
end
|
||||
|
||||
-- reskin all esc/menu buttons
|
||||
local BlizzardMenuButtons = {
|
||||
"Options",
|
||||
"SoundOptions",
|
||||
"UIOptions",
|
||||
"Keybindings",
|
||||
"Macros",
|
||||
"Logout",
|
||||
"Quit",
|
||||
"Continue",
|
||||
}
|
||||
|
||||
for i = 1, getn(BlizzardMenuButtons) do
|
||||
local ElvuiMenuButtons = _G["GameMenuButton"..BlizzardMenuButtons[i]]
|
||||
if ElvuiMenuButtons then
|
||||
S:HandleButton(ElvuiMenuButtons)
|
||||
end
|
||||
end
|
||||
|
||||
-- hide header textures and move text/buttons.
|
||||
local BlizzardHeader = {
|
||||
"GameMenuFrame",
|
||||
"SoundOptionsFrame",
|
||||
"OptionsFrame",
|
||||
}
|
||||
|
||||
for i = 1, getn(BlizzardHeader) do
|
||||
local title = _G[BlizzardHeader[i].."Header"]
|
||||
if title then
|
||||
title:SetTexture("")
|
||||
title:ClearAllPoints()
|
||||
if title == _G["GameMenuFrameHeader"] then
|
||||
title:SetPoint("TOP", GameMenuFrame, 0, 7)
|
||||
else
|
||||
title:SetPoint("TOP", BlizzardHeader[i], 0, 0)
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
-- here we reskin all "normal" buttons
|
||||
local BlizzardButtons = {
|
||||
"OptionsFrameOkay",
|
||||
"OptionsFrameCancel",
|
||||
"OptionsFrameDefaults",
|
||||
"SoundOptionsFrameOkay",
|
||||
"SoundOptionsFrameCancel",
|
||||
"SoundOptionsFrameDefaults",
|
||||
"UIOptionsFrameDefaults",
|
||||
"UIOptionsFrameOkay",
|
||||
"UIOptionsFrameCancel",
|
||||
"StackSplitOkayButton",
|
||||
"StackSplitCancelButton",
|
||||
"RolePollPopupAcceptButton"
|
||||
}
|
||||
|
||||
for i = 1, getn(BlizzardButtons) do
|
||||
local ElvuiButtons = _G[BlizzardButtons[i]]
|
||||
if ElvuiButtons then
|
||||
S:HandleButton(ElvuiButtons)
|
||||
end
|
||||
end
|
||||
|
||||
-- if a button position is not really where we want, we move it here
|
||||
OptionsFrameCancel:ClearAllPoints()
|
||||
OptionsFrameCancel:SetPoint("BOTTOMLEFT",OptionsFrame,"BOTTOMRIGHT",-105,15)
|
||||
OptionsFrameOkay:ClearAllPoints()
|
||||
OptionsFrameOkay:SetPoint("RIGHT",OptionsFrameCancel,"LEFT",-4,0)
|
||||
SoundOptionsFrameOkay:ClearAllPoints()
|
||||
SoundOptionsFrameOkay:SetPoint("RIGHT",SoundOptionsFrameCancel,"LEFT",-4,0)
|
||||
UIOptionsFrameOkay:ClearAllPoints()
|
||||
UIOptionsFrameOkay:SetPoint("RIGHT",UIOptionsFrameCancel,"LEFT", -4,0)
|
||||
|
||||
-- others
|
||||
ZoneTextFrame:ClearAllPoints()
|
||||
ZoneTextFrame:SetPoint("TOP", UIParent, 0, -128)
|
||||
|
||||
E:StripTextures(CoinPickupFrame)
|
||||
E:SetTemplate(CoinPickupFrame, "Transparent")
|
||||
|
||||
S:HandleButton(CoinPickupOkayButton)
|
||||
S:HandleButton(CoinPickupCancelButton)
|
||||
|
||||
-- Stack Split Frame
|
||||
StackSplitFrame:GetRegions():Hide()
|
||||
|
||||
StackSplitFrame.bg1 = CreateFrame("Frame", nil, StackSplitFrame)
|
||||
E:SetTemplate(StackSplitFrame.bg1, "Transparent")
|
||||
StackSplitFrame.bg1:SetPoint("TOPLEFT", 10, -15)
|
||||
StackSplitFrame.bg1:SetPoint("BOTTOMRIGHT", -10, 55)
|
||||
StackSplitFrame.bg1:SetFrameLevel(StackSplitFrame.bg1:GetFrameLevel() - 1)
|
||||
|
||||
-- Declension frame
|
||||
if GetLocale() == "ruRU" then
|
||||
DeclensionFrame:SetTemplate("Transparent")
|
||||
|
||||
S:HandleNextPrevButton(DeclensionFrameSetPrev)
|
||||
S:HandleNextPrevButton(DeclensionFrameSetNext)
|
||||
S:HandleButton(DeclensionFrameOkayButton)
|
||||
S:HandleButton(DeclensionFrameCancelButton)
|
||||
|
||||
for i = 1, RUSSIAN_DECLENSION_PATTERNS do
|
||||
local editBox = _G["DeclensionFrameDeclension"..i.."Edit"]
|
||||
if editBox then
|
||||
E:StripTextures(editBox)
|
||||
S:HandleEditBox(editBox)
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
if GetLocale() == "koKR" then
|
||||
S:HandleButton(GameMenuButtonRatings)
|
||||
|
||||
RatingMenuFrame:SetTemplate("Transparent")
|
||||
RatingMenuFrameHeader:Kill()
|
||||
S:HandleButton(RatingMenuButtonOkay)
|
||||
end
|
||||
|
||||
E:StripTextures(OpacityFrame)
|
||||
E:SetTemplate(OpacityFrame, "Transparent")
|
||||
|
||||
S:HandleSliderFrame(OpacityFrameSlider)
|
||||
|
||||
-- Interface Options
|
||||
UIOptionsFrame:SetParent(E.UIParent)
|
||||
UIOptionsFrame:EnableMouse(false)
|
||||
|
||||
hooksecurefunc("UIOptionsFrame_Load", function()
|
||||
E:StripTextures(UIOptionsFrame)
|
||||
end)
|
||||
|
||||
local UIOptions = {
|
||||
"BasicOptions",
|
||||
"BasicOptionsGeneral",
|
||||
"BasicOptionsDisplay",
|
||||
"BasicOptionsCamera",
|
||||
"BasicOptionsHelp",
|
||||
"AdvancedOptions",
|
||||
"AdvancedOptionsActionBars",
|
||||
"AdvancedOptionsChat",
|
||||
"AdvancedOptionsRaid",
|
||||
"AdvancedOptionsCombatText",
|
||||
}
|
||||
|
||||
for i = 1, getn(UIOptions) do
|
||||
local options = _G[UIOptions[i]]
|
||||
E:SetTemplate(options, "Transparent")
|
||||
end
|
||||
|
||||
BasicOptions.backdrop = CreateFrame("Frame", nil, BasicOptions)
|
||||
BasicOptions.backdrop:SetPoint("TOPLEFT", BasicOptionsGeneral, -20, 35)
|
||||
BasicOptions.backdrop:SetPoint("BOTTOMRIGHT", BasicOptionsHelp, 20, -130)
|
||||
E:SetTemplate(BasicOptions.backdrop, "Transparent")
|
||||
|
||||
AdvancedOptions.backdrop = CreateFrame("Frame", nil, AdvancedOptions)
|
||||
AdvancedOptions.backdrop:SetPoint("TOPLEFT", BasicOptionsGeneral, -20, 35)
|
||||
AdvancedOptions.backdrop:SetPoint("BOTTOMRIGHT", BasicOptionsHelp, 20, -130)
|
||||
E:SetTemplate(AdvancedOptions.backdrop, "Transparent")
|
||||
|
||||
for i = 1, 2 do
|
||||
local tab = _G["UIOptionsFrameTab"..i]
|
||||
E:StripTextures(tab, true)
|
||||
E:CreateBackdrop(tab, "Transparent")
|
||||
|
||||
tab:SetFrameLevel(tab:GetParent():GetFrameLevel() + 2)
|
||||
tab.backdrop:SetFrameLevel(tab:GetParent():GetFrameLevel() + 1)
|
||||
|
||||
tab.backdrop:SetPoint("TOPLEFT", 5, E.PixelMode and -14 or -16)
|
||||
tab.backdrop:SetPoint("BOTTOMRIGHT", -5, E.PixelMode and -4 or -6)
|
||||
|
||||
tab:SetScript("OnClick", function()
|
||||
PanelTemplates_Tab_OnClick(UIOptionsFrame)
|
||||
if AdvancedOptions:IsShown() then
|
||||
BasicOptions:Show()
|
||||
AdvancedOptions:Hide()
|
||||
else
|
||||
BasicOptions:Hide()
|
||||
AdvancedOptions:Show()
|
||||
end
|
||||
PlaySound("igCharacterInfoTab")
|
||||
end)
|
||||
|
||||
HookScript(tab, "OnEnter", S.SetModifiedBackdrop)
|
||||
HookScript(tab, "OnLeave", S.SetOriginalBackdrop)
|
||||
end
|
||||
|
||||
for _, child in ipairs({UIOptionsFrame:GetChildren()}) do
|
||||
if child.GetPushedTexture and child:GetPushedTexture() and not child:GetName() then
|
||||
child:SetFrameLevel(UIOptionsFrame:GetFrameLevel() + 2)
|
||||
S:HandleCloseButton(child, UIOptionsFrame.backdrop)
|
||||
end
|
||||
end
|
||||
|
||||
--[[for i = 1, UIOptionsFrame:GetNumChildren() do
|
||||
local child = select(i, UIOptionsFrame:GetChildren())
|
||||
if child.GetPushedTexture and child:GetPushedTexture() and not child:GetName() then
|
||||
child:SetFrameLevel(UIOptionsFrame:GetFrameLevel() + 2)
|
||||
S:HandleCloseButton(child, UIOptionsFrame.backdrop)
|
||||
end
|
||||
end--]]
|
||||
|
||||
OptionsFrameDefaults:ClearAllPoints()
|
||||
OptionsFrameDefaults:SetPoint("TOPLEFT", OptionsFrame, "BOTTOMLEFT", 15, 36)
|
||||
|
||||
S:HandleButton(UIOptionsFrameResetTutorials)
|
||||
|
||||
SoundOptionsFrameCheckButton1:SetPoint("TOPLEFT", "SoundOptionsFrame", "TOPLEFT", 16, -15)
|
||||
|
||||
-- Interface Options Frame Dropdown
|
||||
local interfacedropdown ={
|
||||
"CombatTextDropDown",
|
||||
"TargetofTargetDropDown",
|
||||
"CameraDropDown",
|
||||
"ClickCameraDropDown"
|
||||
}
|
||||
|
||||
for i = 1, getn(interfacedropdown) do
|
||||
local idropdown = _G["UIOptionsFrame"..interfacedropdown[i]]
|
||||
if idropdown then
|
||||
S:HandleDropDownBox(idropdown)
|
||||
end
|
||||
end
|
||||
|
||||
-- Video Options Frame Dropdown
|
||||
local optiondropdown = {
|
||||
"OptionsFrameResolutionDropDown",
|
||||
"OptionsFrameRefreshDropDown",
|
||||
"OptionsFrameMultiSampleDropDown",
|
||||
"SoundOptionsOutputDropDown",
|
||||
}
|
||||
|
||||
for i = 1, getn(optiondropdown) do
|
||||
local odropdown = _G[optiondropdown[i]]
|
||||
if odropdown then
|
||||
S:HandleDropDownBox(odropdown, i == 3 and 195 or 165)
|
||||
end
|
||||
end
|
||||
|
||||
-- Interface Options Checkboxes
|
||||
for index, value in UIOptionsFrameCheckButtons do
|
||||
local UIOptionsFrameCheckBox = _G["UIOptionsFrameCheckButton"..value.index]
|
||||
if UIOptionsFrameCheckBox then
|
||||
S:HandleCheckBox(UIOptionsFrameCheckBox)
|
||||
end
|
||||
end
|
||||
|
||||
-- Video Options Checkboxes
|
||||
for index, value in OptionsFrameCheckButtons do
|
||||
local OptionsFrameCheckButton = _G["OptionsFrameCheckButton"..value.index]
|
||||
if OptionsFrameCheckButton then
|
||||
S:HandleCheckBox(OptionsFrameCheckButton)
|
||||
end
|
||||
end
|
||||
|
||||
-- Sound Options Checkboxes
|
||||
for index, value in SoundOptionsFrameCheckButtons do
|
||||
local SoundOptionsFrameCheckButton = _G["SoundOptionsFrameCheckButton"..value.index]
|
||||
if SoundOptionsFrameCheckButton then
|
||||
S:HandleCheckBox(SoundOptionsFrameCheckButton)
|
||||
end
|
||||
end
|
||||
|
||||
-- Interface Options Sliders
|
||||
for i, v in UIOptionsFrameSliders do
|
||||
S:HandleSliderFrame(_G["UIOptionsFrameSlider"..i])
|
||||
end
|
||||
|
||||
-- Video Options Sliders
|
||||
for i, v in OptionsFrameSliders do
|
||||
S:HandleSliderFrame(_G["OptionsFrameSlider"..i])
|
||||
end
|
||||
|
||||
-- Sound Options Sliders
|
||||
for i, v in SoundOptionsFrameSliders do
|
||||
S:HandleSliderFrame(_G["SoundOptionsFrameSlider"..i])
|
||||
end
|
||||
end
|
||||
|
||||
S:AddCallback("SkinMisc", LoadSkin)
|
||||
@@ -0,0 +1,39 @@
|
||||
local E, L, V, P, G = unpack(ElvUI); --Import: Engine, Locales, PrivateDB, ProfileDB, GlobalDB
|
||||
local S = E:GetModule("Skins");
|
||||
|
||||
--Cache global variables
|
||||
--Lua functions
|
||||
local _G = _G
|
||||
--WoW API / Variables
|
||||
|
||||
local function LoadSkin()
|
||||
if E.private.skins.blizzard.enable ~= true or E.private.skins.blizzard.petition ~= true then return end
|
||||
|
||||
E:StripTextures(PetitionFrame, true)
|
||||
E:CreateBackdrop(PetitionFrame, "Transparent")
|
||||
PetitionFrame.backdrop:SetPoint("TOPLEFT", 12, -17)
|
||||
PetitionFrame.backdrop:SetPoint("BOTTOMRIGHT", -28, 65)
|
||||
|
||||
S:HandleButton(PetitionFrameSignButton)
|
||||
S:HandleButton(PetitionFrameRequestButton)
|
||||
S:HandleButton(PetitionFrameRenameButton)
|
||||
S:HandleButton(PetitionFrameCancelButton)
|
||||
S:HandleCloseButton(PetitionFrameCloseButton)
|
||||
|
||||
PetitionFrameCharterTitle:SetTextColor(1, 1, 0)
|
||||
PetitionFrameCharterName:SetTextColor(1, 1, 1)
|
||||
PetitionFrameMasterTitle:SetTextColor(1, 1, 0)
|
||||
PetitionFrameMasterName:SetTextColor(1, 1, 1)
|
||||
PetitionFrameMemberTitle:SetTextColor(1, 1, 0)
|
||||
|
||||
for i = 1, 9 do
|
||||
_G["PetitionFrameMemberName"..i]:SetTextColor(1, 1, 1)
|
||||
end
|
||||
|
||||
PetitionFrameInstructions:SetTextColor(1, 1, 1)
|
||||
|
||||
PetitionFrameRenameButton:SetPoint("LEFT", PetitionFrameRequestButton, "RIGHT", 3, 0)
|
||||
PetitionFrameRenameButton:SetPoint("RIGHT", PetitionFrameCancelButton, "LEFT", -3, 0)
|
||||
end
|
||||
|
||||
S:AddCallback("Petition", LoadSkin)
|
||||
@@ -0,0 +1,439 @@
|
||||
local E, L, V, P, G = unpack(ElvUI); --Import: Engine, Locales, PrivateDB, ProfileDB, GlobalDB
|
||||
local S = E:GetModule("Skins");
|
||||
|
||||
--Cache global variables
|
||||
--Lua functions
|
||||
local _G = _G
|
||||
local pairs = pairs
|
||||
local unpack = unpack
|
||||
local find, format, match, split = string.find, string.format, string.match, string.split
|
||||
--WoW API / Variables
|
||||
local GetItemInfo = GetItemInfo
|
||||
local GetItemQualityColor = GetItemQualityColor
|
||||
local hooksecurefunc = hooksecurefunc
|
||||
|
||||
local function LoadSkin()
|
||||
if E.private.skins.blizzard.enable ~= true or E.private.skins.blizzard.quest ~= true then return end
|
||||
|
||||
local QuestStrip = {
|
||||
"QuestFrame",
|
||||
"QuestLogFrame",
|
||||
"EmptyQuestLogFrame",
|
||||
"QuestFrameDetailPanel",
|
||||
"QuestDetailScrollFrame",
|
||||
"QuestDetailScrollChildFrame",
|
||||
"QuestRewardScrollFrame",
|
||||
"QuestRewardScrollChildFrame",
|
||||
"QuestFrameProgressPanel",
|
||||
"QuestFrameRewardPanel",
|
||||
"QuestFrameRewardPanel"
|
||||
}
|
||||
|
||||
for _, object in pairs(QuestStrip) do
|
||||
E:StripTextures(_G[object], true)
|
||||
end
|
||||
|
||||
local QuestButtons = {
|
||||
"QuestLogFrameAbandonButton",
|
||||
"QuestFrameExitButton",
|
||||
"QuestFramePushQuestButton",
|
||||
"QuestFrameCompleteButton",
|
||||
"QuestFrameGoodbyeButton",
|
||||
"QuestFrameCompleteQuestButton",
|
||||
"QuestFrameCancelButton",
|
||||
"QuestFrameGreetingGoodbyeButton",
|
||||
"QuestFrameAcceptButton",
|
||||
"QuestFrameDeclineButton"
|
||||
}
|
||||
|
||||
for _, button in pairs(QuestButtons) do
|
||||
E:StripTextures(_G[button])
|
||||
S:HandleButton(_G[button])
|
||||
end
|
||||
|
||||
for i = 1, MAX_NUM_ITEMS do
|
||||
local item = _G["QuestLogItem"..i]
|
||||
local icon = _G["QuestLogItem"..i.."IconTexture"]
|
||||
local count = _G["QuestLogItem"..i.."Count"]
|
||||
|
||||
E:StripTextures(item)
|
||||
E:SetTemplate(item, "Default")
|
||||
E:StyleButton(item)
|
||||
item:SetWidth(item:GetWidth() - 4)
|
||||
item:SetFrameLevel(item:GetFrameLevel() + 2)
|
||||
|
||||
icon:SetDrawLayer("OVERLAY")
|
||||
icon:SetWidth(icon:GetWidth() -(E.Spacing*2))
|
||||
icon:SetHeight(icon:GetHeight() -(E.Spacing*2))
|
||||
icon:SetPoint("TOPLEFT", E.Border, -E.Border)
|
||||
S:HandleIcon(icon)
|
||||
|
||||
count:SetParent(item.backdrop)
|
||||
count:SetDrawLayer("OVERLAY")
|
||||
end
|
||||
|
||||
for i = 1, 6 do
|
||||
local item = _G["QuestDetailItem"..i]
|
||||
local icon = _G["QuestDetailItem"..i.."IconTexture"]
|
||||
local count = _G["QuestDetailItem"..i.."Count"]
|
||||
|
||||
E:StripTextures(item)
|
||||
E:SetTemplate(item, "Default")
|
||||
E:StyleButton(item)
|
||||
item:SetWidth(item:GetWidth() - 4)
|
||||
item:SetFrameLevel(item:GetFrameLevel() + 2)
|
||||
|
||||
icon:SetDrawLayer("OVERLAY")
|
||||
icon:SetWidth(icon:GetWidth() -(E.Spacing*2))
|
||||
icon:SetHeight(icon:GetHeight() -(E.Spacing*2))
|
||||
icon:SetPoint("TOPLEFT", E.Border, -E.Border)
|
||||
S:HandleIcon(icon)
|
||||
|
||||
count:SetParent(item.backdrop)
|
||||
count:SetDrawLayer("OVERLAY")
|
||||
end
|
||||
|
||||
for i = 1, 6 do
|
||||
local item = _G["QuestRewardItem"..i]
|
||||
local icon = _G["QuestRewardItem"..i.."IconTexture"]
|
||||
local count = _G["QuestRewardItem"..i.."Count"]
|
||||
|
||||
E:StripTextures(item)
|
||||
E:SetTemplate(item, "Default")
|
||||
E:StyleButton(item)
|
||||
item:SetWidth(item:GetWidth() - 4)
|
||||
item:SetFrameLevel(item:GetFrameLevel() + 2)
|
||||
|
||||
icon:SetDrawLayer("OVERLAY")
|
||||
icon:SetWidth(icon:GetWidth() -(E.Spacing*2))
|
||||
icon:SetHeight(icon:GetHeight() -(E.Spacing*2))
|
||||
icon:SetPoint("TOPLEFT", E.Border, -E.Border)
|
||||
S:HandleIcon(icon)
|
||||
|
||||
count:SetParent(item.backdrop)
|
||||
count:SetDrawLayer("OVERLAY")
|
||||
end
|
||||
|
||||
local function QuestQualityColors(frame, text, quality, link)
|
||||
if link and not quality then
|
||||
_, _, quality = GetItemInfo(match(link, "item:(%d+)"))
|
||||
end
|
||||
|
||||
if quality then
|
||||
if frame then
|
||||
frame:SetBackdropBorderColor(GetItemQualityColor(quality))
|
||||
frame.backdrop:SetBackdropBorderColor(GetItemQualityColor(quality))
|
||||
end
|
||||
text:SetTextColor(GetItemQualityColor(quality))
|
||||
else
|
||||
if frame then
|
||||
frame:SetBackdropBorderColor(unpack(E["media"].bordercolor))
|
||||
frame.backdrop:SetBackdropBorderColor(unpack(E["media"].bordercolor))
|
||||
end
|
||||
text:SetTextColor(1, 1, 1)
|
||||
end
|
||||
end
|
||||
|
||||
E:StripTextures(QuestRewardItemHighlight)
|
||||
E:SetTemplate(QuestRewardItemHighlight, "Default", nil, true)
|
||||
QuestRewardItemHighlight:SetBackdropBorderColor(1, 1, 0)
|
||||
QuestRewardItemHighlight:SetBackdropColor(0, 0, 0, 0)
|
||||
QuestRewardItemHighlight:SetWidth(142)
|
||||
QuestRewardItemHighlight:SetHeight(40)
|
||||
|
||||
hooksecurefunc("QuestRewardItem_OnClick", function()
|
||||
QuestRewardItemHighlight:ClearAllPoints();
|
||||
E:SetOutside(QuestRewardItemHighlight, this:GetName() .. "IconTexture")
|
||||
_G[this:GetName() .. "Name"]:SetTextColor(1, 1, 0)
|
||||
|
||||
for i = 1, MAX_NUM_ITEMS do
|
||||
local questItem = _G["QuestRewardItem"..i]
|
||||
local questName = _G["QuestRewardItem"..i.."Name"]
|
||||
local link = questItem.type and GetQuestItemLink(questItem.type, questItem:GetID())
|
||||
|
||||
if questItem ~= this then
|
||||
QuestQualityColors(nil, questName, nil, link)
|
||||
end
|
||||
end
|
||||
end)
|
||||
|
||||
local function QuestObjectiveTextColor()
|
||||
local numObjectives = GetNumQuestLeaderBoards()
|
||||
local objective
|
||||
local _, type, finished;
|
||||
local numVisibleObjectives = 0
|
||||
for i = 1, numObjectives do
|
||||
_, type, finished = GetQuestLogLeaderBoard(i)
|
||||
if type ~= "spell" then
|
||||
numVisibleObjectives = numVisibleObjectives + 1
|
||||
objective = _G["QuestLogObjective"..numVisibleObjectives]
|
||||
if finished then
|
||||
objective:SetTextColor(1, 0.80, 0.10)
|
||||
else
|
||||
objective:SetTextColor(0.6, 0.6, 0.6)
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
hooksecurefunc("QuestLog_UpdateQuestDetails", function()
|
||||
local requiredMoney = GetQuestLogRequiredMoney()
|
||||
if requiredMoney > 0 then
|
||||
if requiredMoney > GetMoney() then
|
||||
QuestLogRequiredMoneyText:SetTextColor(0.6, 0.6, 0.6)
|
||||
else
|
||||
QuestLogRequiredMoneyText:SetTextColor(1, 0.80, 0.10)
|
||||
end
|
||||
end
|
||||
end)
|
||||
|
||||
hooksecurefunc("QuestFrameItems_Update", function(questState)
|
||||
local titleTextColor = {1, 0.80, 0.10}
|
||||
local textColor = {1, 1, 1}
|
||||
|
||||
QuestDetailObjectiveTitleText:SetTextColor(unpack(titleTextColor))
|
||||
QuestDetailRewardTitleText:SetTextColor(unpack(titleTextColor))
|
||||
QuestLogDescriptionTitle:SetTextColor(unpack(titleTextColor))
|
||||
QuestLogQuestTitle:SetTextColor(unpack(titleTextColor))
|
||||
QuestLogTitleText:SetTextColor(unpack(titleTextColor))
|
||||
QuestLogRewardTitleText:SetTextColor(unpack(titleTextColor))
|
||||
QuestRewardRewardTitleText:SetTextColor(unpack(titleTextColor))
|
||||
QuestRewardTitleText:SetTextColor(unpack(titleTextColor))
|
||||
QuestTitleText:SetTextColor(unpack(titleTextColor))
|
||||
QuestTitleFont:SetTextColor(unpack(titleTextColor))
|
||||
QuestTitleFont:SetFont("Fonts\\MORPHEUS.TTF", E.db.general.fontSize + 6)
|
||||
QuestTitleFont.SetFont = E.noop
|
||||
|
||||
QuestDescription:SetTextColor(unpack(textColor))
|
||||
QuestDetailItemReceiveText:SetTextColor(unpack(textColor))
|
||||
QuestDetailSpellLearnText:SetTextColor(unpack(textColor))
|
||||
QuestDetailItemChooseText:SetTextColor(unpack(textColor))
|
||||
QuestFont:SetTextColor(unpack(textColor))
|
||||
QuestFontNormalSmall:SetTextColor(unpack(textColor))
|
||||
QuestLogObjectivesText:SetTextColor(unpack(textColor))
|
||||
QuestLogQuestDescription:SetTextColor(unpack(textColor))
|
||||
QuestLogItemChooseText:SetTextColor(unpack(textColor))
|
||||
QuestLogItemReceiveText:SetTextColor(unpack(textColor))
|
||||
QuestLogSpellLearnText:SetTextColor(unpack(textColor))
|
||||
QuestObjectiveText:SetTextColor(unpack(textColor))
|
||||
QuestRewardItemChooseText:SetTextColor(unpack(textColor))
|
||||
QuestRewardItemReceiveText:SetTextColor(unpack(textColor))
|
||||
QuestRewardSpellLearnText:SetTextColor(unpack(textColor))
|
||||
QuestRewardText:SetTextColor(unpack(textColor))
|
||||
|
||||
QuestObjectiveTextColor()
|
||||
|
||||
local numQuestRewards, numQuestChoices
|
||||
if questState == "QuestLog" then
|
||||
numQuestRewards, numQuestChoices = GetNumQuestLogRewards(), GetNumQuestLogChoices()
|
||||
else
|
||||
numQuestRewards, numQuestChoices = GetNumQuestRewards(), GetNumQuestChoices()
|
||||
end
|
||||
|
||||
local rewardsCount = numQuestChoices + numQuestRewards
|
||||
if rewardsCount > 0 then
|
||||
local questItem, itemName, link
|
||||
local questItemName = questState.."Item"
|
||||
|
||||
for i = 1, rewardsCount do
|
||||
questItem = _G[questItemName..i]
|
||||
itemName = _G[questItemName..i.."Name"]
|
||||
link = questItem.type and (questState == "QuestLog" and GetQuestLogItemLink or GetQuestItemLink)(questItem.type, questItem:GetID())
|
||||
|
||||
QuestQualityColors(questItem, itemName, nil, link)
|
||||
end
|
||||
end
|
||||
end)
|
||||
|
||||
QuestLogTimerText:SetTextColor(1, 1, 1)
|
||||
|
||||
HookScript(QuestFrameGreetingPanel, "OnShow", function()
|
||||
GreetingText:SetTextColor(1, 0.80, 0.10)
|
||||
CurrentQuestsText:SetTextColor(1, 1, 1)
|
||||
AvailableQuestsText:SetTextColor(1, 1, 1)
|
||||
end)
|
||||
|
||||
E:CreateBackdrop(QuestFrame, "Transparent")
|
||||
QuestFrame.backdrop:SetPoint("TOPLEFT", 15, -19)
|
||||
QuestFrame.backdrop:SetPoint("BOTTOMRIGHT", -30, 67)
|
||||
|
||||
E:CreateBackdrop(QuestLogFrame, "Transparent")
|
||||
QuestLogFrame.backdrop:SetPoint("TOPLEFT", 10, -12)
|
||||
QuestLogFrame.backdrop:SetPoint("BOTTOMRIGHT", -1, 8)
|
||||
|
||||
E:StripTextures(QuestLogListScrollFrame)
|
||||
E:CreateBackdrop(QuestLogListScrollFrame, "Default", true)
|
||||
QuestLogListScrollFrame:SetWidth(334)
|
||||
|
||||
E:StripTextures(QuestLogDetailScrollFrame)
|
||||
E:CreateBackdrop(QuestLogDetailScrollFrame, "Default", true)
|
||||
QuestLogDetailScrollFrame:SetWidth(334)
|
||||
QuestLogDetailScrollFrame:SetHeight(296)
|
||||
QuestLogDetailScrollFrame:ClearAllPoints()
|
||||
QuestLogDetailScrollFrame:SetPoint("TOPRIGHT", QuestLogListScrollFrame, "BOTTOMRIGHT", 0, -6)
|
||||
|
||||
QuestLogNoQuestsText:ClearAllPoints()
|
||||
QuestLogNoQuestsText:SetPoint("CENTER", EmptyQuestLogFrame, "CENTER", -45, 65)
|
||||
|
||||
QuestLogFrameAbandonButton:SetPoint("BOTTOMLEFT", 18, 15)
|
||||
QuestLogFrameAbandonButton:SetWidth(126)
|
||||
|
||||
QuestFramePushQuestButton:ClearAllPoints()
|
||||
QuestFramePushQuestButton:SetPoint("BOTTOM", QuestFrame, "BOTTOM", 18, 15)
|
||||
QuestFramePushQuestButton:SetWidth(118)
|
||||
|
||||
QuestFrameExitButton:SetPoint("BOTTOMRIGHT", -8, 15)
|
||||
QuestFrameExitButton:SetWidth(100)
|
||||
|
||||
S:HandleScrollBar(QuestLogDetailScrollFrameScrollBar)
|
||||
S:HandleScrollBar(QuestDetailScrollFrameScrollBar)
|
||||
S:HandleScrollBar(QuestLogListScrollFrameScrollBar)
|
||||
S:HandleScrollBar(QuestProgressScrollFrameScrollBar)
|
||||
S:HandleScrollBar(QuestRewardScrollFrameScrollBar)
|
||||
|
||||
S:HandleCloseButton(QuestFrameCloseButton)
|
||||
|
||||
S:HandleCloseButton(QuestLogFrameCloseButton)
|
||||
QuestLogFrameCloseButton:ClearAllPoints()
|
||||
QuestLogFrameCloseButton:SetPoint("TOPRIGHT", 2, -9)
|
||||
|
||||
QuestLogTrack:Hide()
|
||||
|
||||
local QuestTrack = CreateFrame("Button", "QuestTrack", QuestLogFrame, "UIPanelButtonTemplate")
|
||||
|
||||
S:HandleButton(QuestTrack)
|
||||
QuestTrack:SetText(TRACK_QUEST)
|
||||
QuestTrack:SetPoint("TOP", QuestLogFrame, "TOP", -64, -42)
|
||||
QuestTrack:SetWidth(110)
|
||||
QuestTrack:SetHeight(21)
|
||||
|
||||
HookScript(QuestTrack, "OnClick", function()
|
||||
if IsQuestWatched(GetQuestLogSelection()) then
|
||||
RemoveQuestWatch(GetQuestLogSelection())
|
||||
|
||||
QuestWatch_Update()
|
||||
else
|
||||
if GetNumQuestLeaderBoards(GetQuestLogSelection()) == 0 then
|
||||
UIErrorsFrame:AddMessage(QUEST_WATCH_NO_OBJECTIVES, 1.0, 0.1, 0.1, 1.0)
|
||||
return
|
||||
end
|
||||
|
||||
if GetNumQuestWatches() >= MAX_WATCHABLE_QUESTS then
|
||||
UIErrorsFrame:AddMessage(format(QUEST_WATCH_TOO_MANY, MAX_WATCHABLE_QUESTS), 1.0, 0.1, 0.1, 1.0)
|
||||
return
|
||||
end
|
||||
|
||||
AddQuestWatch(GetQuestLogSelection())
|
||||
|
||||
QuestLog_Update()
|
||||
QuestWatch_Update()
|
||||
end
|
||||
|
||||
QuestLog_Update()
|
||||
end)
|
||||
|
||||
hooksecurefunc("QuestLog_Update", function()
|
||||
local numEntries = GetNumQuestLogEntries()
|
||||
if numEntries == 0 then
|
||||
QuestTrack:Disable()
|
||||
else
|
||||
QuestTrack:Enable()
|
||||
end
|
||||
if EmptyQuestLogFrame:IsVisible() then
|
||||
QuestLogListScrollFrame:Hide()
|
||||
else
|
||||
QuestLogListScrollFrame:Show()
|
||||
end
|
||||
end)
|
||||
|
||||
for i = 1, 6 do
|
||||
local item = _G["QuestProgressItem"..i]
|
||||
local icon = _G["QuestProgressItem"..i.."IconTexture"]
|
||||
local count = _G["QuestProgressItem"..i.."Count"]
|
||||
|
||||
E:StripTextures(item)
|
||||
E:SetTemplate(item, "Default")
|
||||
E:StyleButton(item)
|
||||
item:SetWidth(item:GetWidth() - 4)
|
||||
item:SetFrameLevel(item:GetFrameLevel() + 2)
|
||||
|
||||
icon:SetDrawLayer("OVERLAY")
|
||||
icon:SetWidth(icon:GetWidth() -(E.Spacing*2))
|
||||
icon:SetHeight(icon:GetHeight() -(E.Spacing*2))
|
||||
icon:SetPoint("TOPLEFT", E.Border, -E.Border)
|
||||
S:HandleIcon(icon)
|
||||
|
||||
count:SetParent(item.backdrop)
|
||||
count:SetDrawLayer("OVERLAY")
|
||||
end
|
||||
|
||||
hooksecurefunc("QuestFrameProgressItems_Update", function()
|
||||
QuestProgressTitleText:SetTextColor(1, 0.80, 0.10)
|
||||
QuestProgressText:SetTextColor(1, 1, 1)
|
||||
|
||||
QuestProgressRequiredItemsText:SetTextColor(1, 0.80, 0.10)
|
||||
|
||||
if GetQuestMoneyToGet() > GetMoney() then
|
||||
QuestProgressRequiredMoneyText:SetTextColor(0.6, 0.6, 0.6)
|
||||
else
|
||||
QuestProgressRequiredMoneyText:SetTextColor(1, 0.80, 0.10)
|
||||
end
|
||||
|
||||
for i = 1, MAX_REQUIRED_ITEMS do
|
||||
local item = _G["QuestProgressItem"..i]
|
||||
local name = _G["QuestProgressItem"..i.."Name"]
|
||||
local link = item.type and GetQuestItemLink(item.type, item:GetID())
|
||||
|
||||
QuestQualityColors(item, name, nil, link)
|
||||
end
|
||||
end)
|
||||
|
||||
for i = 1, QUESTS_DISPLAYED do
|
||||
local questLogTitle = _G["QuestLogTitle"..i]
|
||||
|
||||
questLogTitle:SetNormalTexture("")
|
||||
questLogTitle.SetNormalTexture = E.noop
|
||||
|
||||
_G["QuestLogTitle"..i.."Highlight"]:SetTexture("")
|
||||
_G["QuestLogTitle"..i.."Highlight"].SetTexture = E.noop
|
||||
|
||||
questLogTitle.Text = questLogTitle:CreateFontString(nil, "OVERLAY")
|
||||
E:FontTemplate(questLogTitle.Text, nil, 22)
|
||||
questLogTitle.Text:SetPoint("LEFT", 3, 0)
|
||||
questLogTitle.Text:SetText("+")
|
||||
|
||||
hooksecurefunc(questLogTitle, "SetNormalTexture", function(self, texture)
|
||||
if find(texture, "MinusButton") then
|
||||
self.Text:SetText("-")
|
||||
elseif find(texture, "PlusButton") then
|
||||
self.Text:SetText("+")
|
||||
else
|
||||
self.Text:SetText("")
|
||||
end
|
||||
end)
|
||||
end
|
||||
|
||||
E:StripTextures(QuestLogCollapseAllButton)
|
||||
QuestLogCollapseAllButton:SetNormalTexture("")
|
||||
QuestLogCollapseAllButton.SetNormalTexture = E.noop
|
||||
QuestLogCollapseAllButton:SetHighlightTexture("")
|
||||
QuestLogCollapseAllButton.SetHighlightTexture = E.noop
|
||||
QuestLogCollapseAllButton:SetDisabledTexture("")
|
||||
QuestLogCollapseAllButton.SetDisabledTexture = E.noop
|
||||
QuestLogCollapseAllButton:SetPoint("TOPLEFT", -45, 7)
|
||||
|
||||
QuestLogCollapseAllButton.Text = QuestLogCollapseAllButton:CreateFontString(nil, "OVERLAY")
|
||||
E:FontTemplate(QuestLogCollapseAllButton.Text, nil, 22)
|
||||
QuestLogCollapseAllButton.Text:SetPoint("LEFT", 3, 0)
|
||||
QuestLogCollapseAllButton.Text:SetText("+")
|
||||
|
||||
hooksecurefunc(QuestLogCollapseAllButton, "SetNormalTexture", function(self, texture)
|
||||
if find(texture, "MinusButton") then
|
||||
self.Text:SetText("-")
|
||||
else
|
||||
self.Text:SetText("+")
|
||||
end
|
||||
end)
|
||||
end
|
||||
|
||||
S:AddCallback("Quest", LoadSkin)
|
||||
@@ -0,0 +1,35 @@
|
||||
local E, L, V, P, G = unpack(ElvUI); --Import: Engine, Locales, PrivateDB, ProfileDB, GlobalDB
|
||||
local S = E:GetModule("Skins");
|
||||
|
||||
--Cache global variables
|
||||
--Lua functions
|
||||
--WoW API / Variables
|
||||
local hooksecurefunc = hooksecurefunc
|
||||
|
||||
local function LoadSkin()
|
||||
if E.private.skins.blizzard.enable ~= true or E.private.skins.blizzard.questtimers ~= true then return end
|
||||
|
||||
E:StripTextures(QuestTimerFrame)
|
||||
E:SetTemplate(QuestTimerFrame, "Transparent")
|
||||
|
||||
QuestTimerHeader:SetPoint("TOP", 1, 8)
|
||||
|
||||
E:CreateMover(QuestTimerFrame, "QuestTimerFrameMover", QUEST_TIMERS)
|
||||
|
||||
QuestTimerFrame:ClearAllPoints()
|
||||
QuestTimerFrame:SetAllPoints(QuestTimerFrameMover)
|
||||
|
||||
local QuestTimerFrameHolder = CreateFrame("Frame", "QuestTimerFrameHolder", E.UIParent)
|
||||
QuestTimerFrameHolder:SetWidth(150)
|
||||
QuestTimerFrameHolder:SetHeight(22)
|
||||
QuestTimerFrameHolder:SetPoint("TOP", QuestTimerFrameMover, "TOP")
|
||||
|
||||
hooksecurefunc(QuestTimerFrame, "SetPoint", function(_, _, parent)
|
||||
if parent ~= QuestTimerFrameHolder then
|
||||
QuestTimerFrame:ClearAllPoints()
|
||||
QuestTimerFrame:SetPoint("TOP", QuestTimerFrameHolder, "TOP")
|
||||
end
|
||||
end)
|
||||
end
|
||||
|
||||
S:AddCallback("QuestTimer", LoadSkin)
|
||||
@@ -0,0 +1,107 @@
|
||||
local E, L, V, P, G = unpack(ElvUI); --Import: Engine, Locales, PrivateDB, ProfileDB, GlobalDB
|
||||
local S = E:GetModule("Skins");
|
||||
|
||||
--Cache global variables
|
||||
--Lua functions
|
||||
local _G = _G
|
||||
local unpack = unpack
|
||||
local pairs = pairs
|
||||
--WoW API / Variables
|
||||
local hooksecurefunc = hooksecurefunc
|
||||
|
||||
function LoadSkin()
|
||||
if E.private.skins.blizzard.enable ~= true or E.private.skins.blizzard.raid ~= true then return end
|
||||
|
||||
-- RaidFrame
|
||||
local StripAllTextures = {
|
||||
"RaidGroup1",
|
||||
"RaidGroup2",
|
||||
"RaidGroup3",
|
||||
"RaidGroup4",
|
||||
"RaidGroup5",
|
||||
"RaidGroup6",
|
||||
"RaidGroup7",
|
||||
"RaidGroup8"
|
||||
}
|
||||
|
||||
for _, object in pairs(StripAllTextures) do
|
||||
if _G[object] then
|
||||
E:StripTextures(_G[object])
|
||||
end
|
||||
end
|
||||
|
||||
S:HandleButton(RaidFrameAddMemberButton)
|
||||
S:HandleButton(RaidFrameReadyCheckButton)
|
||||
S:HandleButton(RaidFrameRaidInfoButton)
|
||||
|
||||
for i = 1, NUM_RAID_GROUPS*5 do
|
||||
S:HandleButton(_G["RaidGroupButton"..i], true)
|
||||
end
|
||||
|
||||
for i = 1, 8 do
|
||||
for j = 1, 5 do
|
||||
E:StripTextures(_G["RaidGroup"..i.."Slot"..j])
|
||||
E:SetTemplate(_G["RaidGroup"..i.."Slot"..j], "Transparent")
|
||||
end
|
||||
end
|
||||
|
||||
local function skinPulloutFrames()
|
||||
for i = 1, NUM_RAID_PULLOUT_FRAMES do
|
||||
local rp = _G["RaidPullout"..i]
|
||||
if not rp.backdrop then
|
||||
_G["RaidPullout"..i.."MenuBackdrop"]:SetBackdrop(nil)
|
||||
E:CreateBackdrop(rp, "Transparent")
|
||||
rp.backdrop:SetPoint("TOPLEFT", 9, -17)
|
||||
rp.backdrop:SetPoint("BOTTOMRIGHT", -7, 10)
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
hooksecurefunc("RaidPullout_GetFrame", function()
|
||||
skinPulloutFrames()
|
||||
end)
|
||||
|
||||
--[[hooksecurefunc("RaidPullout_Update", function(pullOutFrame)
|
||||
local pfName = pullOutFrame:GetName()
|
||||
for i = 1, pullOutFrame.numPulloutButtons do
|
||||
local pfBName = pfName.."Button"..i
|
||||
local pfBObj = _G[pfBName]
|
||||
if not pfBObj.backdrop then
|
||||
for _, v in pairs{"HealthBar", "ManaBar", "Target", "TargetTarget"} do
|
||||
local sBar = pfBName..v
|
||||
E:StripTextures(_G[sBar])
|
||||
_G[sBar]:SetStatusBarTexture(E["media"].normTex)
|
||||
end
|
||||
|
||||
_G[pfBName.."ManaBar"]:SetPoint("TOP", "$parentHealthBar", "BOTTOM", 0, 0)
|
||||
_G[pfBName.."Target"]:SetPoint("TOP", "$parentManaBar", "BOTTOM", 0, -1)
|
||||
|
||||
E:CreateBackdrop(pfBObj, "Default")
|
||||
pfBObj.backdrop:SetPoint("TOPLEFT", E.PixelMode and 0 or -1, -(E.PixelMode and 10 or 9))
|
||||
pfBObj.backdrop:SetPoint("BOTTOMRIGHT", E.PixelMode and 0 or 1, E.PixelMode and 1 or 0)
|
||||
end
|
||||
|
||||
if not _G[pfBName.."TargetTargetFrame"].backdrop then
|
||||
E:StripTextures(_G[pfBName.."TargetTargetFrame"])
|
||||
E:CreateBackdrop(_G[pfBName.."TargetTargetFrame"], "Default")
|
||||
_G[pfBName.."TargetTargetFrame"].backdrop:SetPoint("TOPLEFT", E.PixelMode and 10 or 9, -(E.PixelMode and 15 or 14))
|
||||
_G[pfBName.."TargetTargetFrame"].backdrop:SetPoint("BOTTOMRIGHT", -(E.PixelMode and 10 or 9), E.PixelMode and 8 or 7)
|
||||
end
|
||||
end
|
||||
end)]]
|
||||
|
||||
-- ReadyCheckFrame
|
||||
E:StripTextures(ReadyCheckFrame)
|
||||
E:SetTemplate(ReadyCheckFrame, "Transparent")
|
||||
|
||||
E:Kill(ReadyCheckPortrait)
|
||||
|
||||
S:HandleButton(ReadyCheckFrameYesButton)
|
||||
S:HandleButton(ReadyCheckFrameNoButton)
|
||||
|
||||
ReadyCheckFrameYesButton:SetPoint("RIGHT", ReadyCheckFrame, "CENTER", -1, 0)
|
||||
ReadyCheckFrameNoButton:SetPoint("LEFT", ReadyCheckFrameYesButton, "RIGHT", 3, 0)
|
||||
ReadyCheckFrameText:SetPoint("TOP", ReadyCheckFrame, "TOP", 0, -18)
|
||||
end
|
||||
|
||||
S:AddCallbackForAddon("Blizzard_RaidUI", "RaidUI", LoadSkin)
|
||||
@@ -0,0 +1,70 @@
|
||||
local E, L, V, P, G = unpack(ElvUI); --Import: Engine, Locales, PrivateDB, ProfileDB, GlobalDB
|
||||
local S = E:GetModule("Skins");
|
||||
|
||||
--Cache global variables
|
||||
--Lua functions
|
||||
local _G = _G
|
||||
local unpack = unpack
|
||||
--WoW API / Variables
|
||||
|
||||
local function LoadSkin()
|
||||
if E.private.skins.blizzard.enable ~= true or E.private.skins.blizzard.spellbook ~= true then return end
|
||||
|
||||
E:StripTextures(SpellBookFrame, true)
|
||||
E:CreateBackdrop(SpellBookFrame, "Transparent")
|
||||
SpellBookFrame.backdrop:SetPoint("TOPLEFT", 10, -12)
|
||||
SpellBookFrame.backdrop:SetPoint("BOTTOMRIGHT", -31, 75)
|
||||
|
||||
for i = 1, 3 do
|
||||
local tab = _G["SpellBookFrameTabButton"..i]
|
||||
|
||||
tab:GetNormalTexture():SetTexture("")
|
||||
tab:GetDisabledTexture():SetTexture("")
|
||||
|
||||
S:HandleTab(tab)
|
||||
|
||||
tab.backdrop:SetPoint("TOPLEFT", 14, E.PixelMode and -17 or -19)
|
||||
tab.backdrop:SetPoint("BOTTOMRIGHT", -14, 19)
|
||||
end
|
||||
|
||||
S:HandleNextPrevButton(SpellBookPrevPageButton)
|
||||
S:HandleNextPrevButton(SpellBookNextPageButton)
|
||||
|
||||
S:HandleCloseButton(SpellBookCloseButton)
|
||||
|
||||
for i = 1, SPELLS_PER_PAGE do
|
||||
local button = _G["SpellButton"..i]
|
||||
E:StripTextures(button)
|
||||
|
||||
_G["SpellButton"..i.."AutoCastable"]:SetTexture("Interface\\Buttons\\UI-AutoCastableOverlay")
|
||||
E:SetOutside(_G["SpellButton"..i.."AutoCastable"], button, 16, 16)
|
||||
|
||||
E:CreateBackdrop(button, "Default", true)
|
||||
|
||||
_G["SpellButton"..i.."IconTexture"]:SetTexCoord(unpack(E.TexCoords))
|
||||
|
||||
E:RegisterCooldown(_G["SpellButton"..i.."Cooldown"])
|
||||
end
|
||||
|
||||
hooksecurefunc("SpellButton_UpdateButton", function()
|
||||
local name = this:GetName()
|
||||
_G[name.."SpellName"]:SetTextColor(1, 0.80, 0.10)
|
||||
_G[name.."SubSpellName"]:SetTextColor(1, 1, 1)
|
||||
_G[name.."Highlight"]:SetTexture(1, 1, 1, 0.3)
|
||||
end)
|
||||
|
||||
for i = 1, MAX_SKILLLINE_TABS do
|
||||
local tab = _G["SpellBookSkillLineTab"..i]
|
||||
|
||||
E:StripTextures(tab)
|
||||
E:StyleButton(tab, nil, true)
|
||||
E:SetTemplate(tab, "Default", true)
|
||||
|
||||
E:SetInside(tab:GetNormalTexture())
|
||||
tab:GetNormalTexture():SetTexCoord(unpack(E.TexCoords))
|
||||
end
|
||||
|
||||
SpellBookPageText:SetTextColor(1, 1, 1)
|
||||
end
|
||||
|
||||
S:AddCallback("SpellBook", LoadSkin)
|
||||
@@ -0,0 +1,58 @@
|
||||
local E, L, V, P, G = unpack(ElvUI); --Import: Engine, Locales, PrivateDB, ProfileDB, GlobalDB
|
||||
local S = E:GetModule("Skins");
|
||||
|
||||
--Cache global variables
|
||||
--Lua functions
|
||||
local _G = _G
|
||||
--WoW API / Variables
|
||||
local GetPetHappiness = GetPetHappiness
|
||||
local HasPetUI = HasPetUI
|
||||
local hooksecurefunc = hooksecurefunc
|
||||
local UnitExists = UnitExists
|
||||
|
||||
function LoadSkin()
|
||||
if E.private.skins.blizzard.enable ~= true or E.private.skins.blizzard.stable ~= true then return end
|
||||
|
||||
E:StripTextures(PetStableFrame)
|
||||
E:Kill(PetStableFramePortrait)
|
||||
E:CreateBackdrop(PetStableFrame, "Transparent")
|
||||
PetStableFrame.backdrop:SetPoint("TOPLEFT", 10, -11)
|
||||
PetStableFrame.backdrop:SetPoint("BOTTOMRIGHT", -32, 71)
|
||||
|
||||
S:HandleButton(PetStablePurchaseButton)
|
||||
S:HandleCloseButton(PetStableFrameCloseButton)
|
||||
S:HandleRotateButton(PetStableModelRotateRightButton)
|
||||
S:HandleRotateButton(PetStableModelRotateLeftButton)
|
||||
|
||||
S:HandleItemButton(_G["PetStableCurrentPet"], true)
|
||||
_G["PetStableCurrentPetIconTexture"]:SetDrawLayer("OVERLAY")
|
||||
|
||||
for i = 1, NUM_PET_STABLE_SLOTS do
|
||||
S:HandleItemButton(_G["PetStableStabledPet"..i], true)
|
||||
_G["PetStableStabledPet"..i.."IconTexture"]:SetDrawLayer("OVERLAY")
|
||||
end
|
||||
|
||||
PetStablePetInfo:GetRegions():SetTexCoord(0.04, 0.15, 0.06, 0.30)
|
||||
PetStablePetInfo:SetFrameLevel(PetModelFrame:GetFrameLevel() + 2)
|
||||
E:CreateBackdrop(PetStablePetInfo, "Default")
|
||||
PetStablePetInfo:SetWidth(24)
|
||||
PetStablePetInfo:SetHeight(24)
|
||||
|
||||
hooksecurefunc("PetStable_Update", function()
|
||||
local happiness = GetPetHappiness()
|
||||
local hasPetUI, isHunterPet = HasPetUI()
|
||||
if UnitExists("pet") and hasPetUI and not isHunterPet then
|
||||
return
|
||||
end
|
||||
local texture = PetStablePetInfo:GetRegions()
|
||||
if happiness == 1 then
|
||||
texture:SetTexCoord(0.41, 0.53, 0.06, 0.30)
|
||||
elseif happiness == 2 then
|
||||
texture:SetTexCoord(0.22, 0.345, 0.06, 0.30)
|
||||
elseif happiness == 3 then
|
||||
texture:SetTexCoord(0.04, 0.15, 0.06, 0.30)
|
||||
end
|
||||
end)
|
||||
end
|
||||
|
||||
S:AddCallback("Stable", LoadSkin)
|
||||
@@ -0,0 +1,57 @@
|
||||
local E, L, V, P, G = unpack(ElvUI); --Import: Engine, Locales, PrivateDB, ProfileDB, GlobalDB
|
||||
local S = E:GetModule("Skins");
|
||||
|
||||
--Cache global variables
|
||||
--Lua functions
|
||||
local _G = _G
|
||||
--WoW API / Variables
|
||||
local hooksecurefunc = hooksecurefunc
|
||||
|
||||
local function LoadSkin()
|
||||
if E.private.skins.blizzard.enable ~= true or E.private.skins.blizzard.tabard ~= true then return end
|
||||
|
||||
E:StripTextures(TabardFrame)
|
||||
E:Kill(TabardFramePortrait)
|
||||
E:CreateBackdrop(TabardFrame, "Transparent")
|
||||
TabardFrame.backdrop:SetPoint("TOPLEFT", 10, -12)
|
||||
TabardFrame.backdrop:SetPoint("BOTTOMRIGHT", -32, 74)
|
||||
E:CreateBackdrop(TabardModel, "Default")
|
||||
S:HandleButton(TabardFrameCancelButton)
|
||||
S:HandleButton(TabardFrameAcceptButton)
|
||||
S:HandleCloseButton(TabardFrameCloseButton)
|
||||
S:HandleRotateButton(TabardCharacterModelRotateLeftButton)
|
||||
S:HandleRotateButton(TabardCharacterModelRotateRightButton)
|
||||
E:StripTextures(TabardFrameCostFrame)
|
||||
E:StripTextures(TabardFrameCustomizationFrame)
|
||||
|
||||
for i = 1, 5 do
|
||||
local custom = "TabardFrameCustomization"..i
|
||||
E:StripTextures(_G[custom])
|
||||
S:HandleNextPrevButton(_G[custom.."LeftButton"])
|
||||
S:HandleNextPrevButton(_G[custom.."RightButton"])
|
||||
|
||||
if(i > 1) then
|
||||
_G[custom]:ClearAllPoints()
|
||||
_G[custom]:SetPoint("TOP", _G["TabardFrameCustomization"..i-1], "BOTTOM", 0, -6)
|
||||
else
|
||||
local point, anchor, point2, x, y = _G[custom]:GetPoint()
|
||||
_G[custom]:SetPoint(point, anchor, point2, x, y+4)
|
||||
end
|
||||
end
|
||||
|
||||
TabardCharacterModelRotateLeftButton:SetPoint("BOTTOMLEFT", 4, 4)
|
||||
TabardCharacterModelRotateRightButton:SetPoint("TOPLEFT", TabardCharacterModelRotateLeftButton, "TOPRIGHT", 4, 0)
|
||||
hooksecurefunc(TabardCharacterModelRotateLeftButton, "SetPoint", function(self, point, _, _, xOffset, yOffset)
|
||||
if point ~= "BOTTOMLEFT" or xOffset ~= 4 or yOffset ~= 4 then
|
||||
self:SetPoint("BOTTOMLEFT", 4, 4)
|
||||
end
|
||||
end)
|
||||
|
||||
hooksecurefunc(TabardCharacterModelRotateRightButton, "SetPoint", function(self, point, _, _, xOffset, yOffset)
|
||||
if point ~= "TOPLEFT" or xOffset ~= 4 or yOffset ~= 0 then
|
||||
self:SetPoint("TOPLEFT", TabardCharacterModelRotateLeftButton, "TOPRIGHT", 4, 0)
|
||||
end
|
||||
end)
|
||||
end
|
||||
|
||||
S:AddCallback("Tabard", LoadSkin)
|
||||
@@ -0,0 +1,58 @@
|
||||
local E, L, V, P, G = unpack(ElvUI); --Import: Engine, Locales, PrivateDB, ProfileDB, GlobalDB
|
||||
local S = E:GetModule("Skins");
|
||||
|
||||
--Cache global variables
|
||||
--Lua functions
|
||||
local _G = _G
|
||||
local unpack = unpack
|
||||
--WoW API / Variables
|
||||
|
||||
local function LoadSkin()
|
||||
if E.private.skins.blizzard.enable ~= true or E.private.skins.blizzard.talent ~= true then return end
|
||||
|
||||
E:StripTextures(TalentFrame)
|
||||
E:CreateBackdrop(TalentFrame, "Transparent")
|
||||
TalentFrame.backdrop:SetPoint("TOPLEFT", 13, -12)
|
||||
TalentFrame.backdrop:SetPoint("BOTTOMRIGHT", -31, 76)
|
||||
|
||||
TalentFramePortrait:Hide()
|
||||
|
||||
S:HandleCloseButton(TalentFrameCloseButton)
|
||||
|
||||
E:Kill(TalentFrameCancelButton)
|
||||
|
||||
for i = 1, 5 do
|
||||
S:HandleTab(_G["TalentFrameTab"..i])
|
||||
end
|
||||
|
||||
E:StripTextures(TalentFrameScrollFrame)
|
||||
E:CreateBackdrop(TalentFrameScrollFrame, "Default")
|
||||
TalentFrameScrollFrame.backdrop:SetPoint("TOPLEFT", -1, 2)
|
||||
TalentFrameScrollFrame.backdrop:SetPoint("BOTTOMRIGHT", 6, -2)
|
||||
|
||||
S:HandleScrollBar(TalentFrameScrollFrameScrollBar)
|
||||
TalentFrameScrollFrameScrollBar:SetPoint("TOPLEFT", TalentFrameScrollFrame, "TOPRIGHT", 10, -16)
|
||||
|
||||
TalentFrameSpentPoints:SetPoint("TOP", 0, -42)
|
||||
TalentFrameTalentPointsText:SetPoint("BOTTOMRIGHT", TalentFrame, "BOTTOMLEFT", 220, 84)
|
||||
|
||||
for i = 1, MAX_NUM_TALENTS do
|
||||
local talent = _G["TalentFrameTalent"..i]
|
||||
local icon = _G["TalentFrameTalent"..i.."IconTexture"]
|
||||
local rank = _G["TalentFrameTalent"..i.."Rank"]
|
||||
|
||||
if talent then
|
||||
E:StripTextures(talent)
|
||||
E:SetTemplate(talent, "Default")
|
||||
E:StyleButton(talent)
|
||||
|
||||
E:SetInside(icon)
|
||||
icon:SetTexCoord(unpack(E.TexCoords))
|
||||
icon:SetDrawLayer("ARTWORK")
|
||||
|
||||
rank:SetFont(E.LSM:Fetch("font", E.db["general"].font), 12, "OUTLINE")
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
S:AddCallbackForAddon("Blizzard_TalentUI", "Talent", LoadSkin)
|
||||
@@ -0,0 +1,20 @@
|
||||
local E, L, V, P, G = unpack(ElvUI); --Import: Engine, Locales, PrivateDB, ProfileDB, GlobalDB
|
||||
local S = E:GetModule("Skins");
|
||||
|
||||
local function LoadSkin()
|
||||
if E.private.skins.blizzard.enable ~= true or E.private.skins.blizzard.taxi ~= true then return end
|
||||
|
||||
E:CreateBackdrop(TaxiFrame, "Transparent")
|
||||
TaxiFrame.backdrop:SetPoint("TOPLEFT", 11, -12)
|
||||
TaxiFrame.backdrop:SetPoint("BOTTOMRIGHT", -34, 75)
|
||||
|
||||
E:StripTextures(TaxiFrame)
|
||||
|
||||
E:Kill(TaxiPortrait)
|
||||
|
||||
S:HandleCloseButton(TaxiCloseButton)
|
||||
|
||||
E:CreateBackdrop(TaxiRouteMap, "Default")
|
||||
end
|
||||
|
||||
S:AddCallback("Taxi", LoadSkin)
|
||||
@@ -0,0 +1,51 @@
|
||||
local E, L, V, P, G = unpack(ElvUI); --Import: Engine, Locales, PrivateDB, ProfileDB, GlobalDB
|
||||
local S = E:GetModule("Skins");
|
||||
local TT = E:GetModule("Tooltip");
|
||||
|
||||
--Cache global variables
|
||||
--Lua functions
|
||||
local _G = _G
|
||||
local pairs = pairs
|
||||
--WoW API / Variables
|
||||
|
||||
local function LoadSkin()
|
||||
if E.private.skins.blizzard.enable ~= true or E.private.skins.blizzard.tooltip ~= true then return end
|
||||
|
||||
S:HandleCloseButton(ItemRefCloseButton)
|
||||
|
||||
local GameTooltip = _G["GameTooltip"]
|
||||
local GameTooltipStatusBar = _G["GameTooltipStatusBar"]
|
||||
local tooltips = {
|
||||
GameTooltip,
|
||||
ItemRefTooltip,
|
||||
ItemRefShoppingTooltip1,
|
||||
ItemRefShoppingTooltip2,
|
||||
ItemRefShoppingTooltip3,
|
||||
AutoCompleteBox,
|
||||
FriendsTooltip,
|
||||
ConsolidatedBuffsTooltip,
|
||||
ShoppingTooltip1,
|
||||
ShoppingTooltip2,
|
||||
ShoppingTooltip3,
|
||||
WorldMapTooltip,
|
||||
WorldMapCompareTooltip1,
|
||||
WorldMapCompareTooltip2,
|
||||
WorldMapCompareTooltip3
|
||||
}
|
||||
for _, tt in pairs(tooltips) do
|
||||
TT:SecureHookScript(tt, "OnShow", "SetStyle")
|
||||
end
|
||||
|
||||
GameTooltipStatusBar:SetStatusBarTexture(E["media"].normTex)
|
||||
E:RegisterStatusBar(GameTooltipStatusBar)
|
||||
E:CreateBackdrop(GameTooltipStatusBar, "Transparent")
|
||||
GameTooltipStatusBar:ClearAllPoints()
|
||||
GameTooltipStatusBar:SetPoint("TOPLEFT", GameTooltip, "BOTTOMLEFT", E.Border, -(E.Spacing * 3))
|
||||
GameTooltipStatusBar:SetPoint("TOPRIGHT", GameTooltip, "BOTTOMRIGHT", -E.Border, -(E.Spacing * 3))
|
||||
|
||||
TT:SecureHookScript(GameTooltip, "OnSizeChanged", "CheckBackdropColor")
|
||||
TT:SecureHookScript(GameTooltip, "OnUpdate", "CheckBackdropColor")
|
||||
TT:RegisterEvent("CURSOR_UPDATE", "CheckBackdropColor")
|
||||
end
|
||||
|
||||
S:AddCallback("SkinTooltip", LoadSkin)
|
||||
@@ -0,0 +1,125 @@
|
||||
local E, L, V, P, G = unpack(ElvUI); --Import: Engine, Locales, PrivateDB, ProfileDB, GlobalDB
|
||||
local S = E:GetModule("Skins");
|
||||
|
||||
--Cache global variables
|
||||
--Lua functions
|
||||
local _G = _G
|
||||
local unpack = unpack
|
||||
--WoW API / Variables
|
||||
local GetItemQualityColor = GetItemQualityColor
|
||||
local GetTradePlayerItemInfo = GetTradePlayerItemInfo
|
||||
local GetTradeTargetItemInfo = GetTradeTargetItemInfo
|
||||
local hooksecurefunc = hooksecurefunc
|
||||
|
||||
local function LoadSkin()
|
||||
if E.private.skins.blizzard.enable ~= true or E.private.skins.blizzard.trade ~= true then return end
|
||||
|
||||
E:StripTextures(TradeFrame, true)
|
||||
TradeFrame:SetWidth(400)
|
||||
E:CreateBackdrop(TradeFrame, "Transparent")
|
||||
TradeFrame.backdrop:SetPoint("TOPLEFT", 10, -11)
|
||||
TradeFrame.backdrop:SetPoint("BOTTOMRIGHT", -28, 48)
|
||||
|
||||
S:HandleCloseButton(TradeFrameCloseButton, TradeFrame.backdrop)
|
||||
|
||||
S:HandleEditBox(TradePlayerInputMoneyFrameGold)
|
||||
S:HandleEditBox(TradePlayerInputMoneyFrameSilver)
|
||||
S:HandleEditBox(TradePlayerInputMoneyFrameCopper)
|
||||
|
||||
for i = 1, MAX_TRADE_ITEMS do
|
||||
local player = _G["TradePlayerItem"..i]
|
||||
local recipient = _G["TradeRecipientItem"..i]
|
||||
local playerButton = _G["TradePlayerItem"..i.."ItemButton"]
|
||||
local playerButtonIcon = _G["TradePlayerItem"..i.."ItemButtonIconTexture"]
|
||||
local recipientButton = _G["TradeRecipientItem"..i.."ItemButton"]
|
||||
local recipientButtonIcon = _G["TradeRecipientItem"..i.."ItemButtonIconTexture"]
|
||||
local playerNameFrame = _G["TradePlayerItem"..i.."NameFrame"]
|
||||
local recipientNameFrame = _G["TradeRecipientItem"..i.."NameFrame"]
|
||||
|
||||
E:StripTextures(player)
|
||||
E:StripTextures(recipient)
|
||||
|
||||
E:StripTextures(playerButton)
|
||||
E:StyleButton(playerButton)
|
||||
E:SetTemplate(playerButton, "Default", true)
|
||||
|
||||
E:SetInside(playerButtonIcon)
|
||||
playerButtonIcon:SetTexCoord(unpack(E.TexCoords))
|
||||
|
||||
E:StripTextures(recipientButton)
|
||||
E:StyleButton(recipientButton)
|
||||
E:SetTemplate(recipientButton, "Default", true)
|
||||
|
||||
E:SetInside(recipientButtonIcon)
|
||||
recipientButtonIcon:SetTexCoord(unpack(E.TexCoords))
|
||||
|
||||
playerButton.bg = CreateFrame("Frame", nil, playerButton)
|
||||
E:SetTemplate(playerButton.bg, "Default")
|
||||
playerButton.bg:SetPoint("TOPLEFT", playerButton, "TOPRIGHT", 4, 0)
|
||||
playerButton.bg:SetPoint("BOTTOMRIGHT", playerNameFrame, "BOTTOMRIGHT", -5, 14)
|
||||
playerButton.bg:SetFrameLevel(playerButton:GetFrameLevel() - 4)
|
||||
|
||||
recipientButton.bg = CreateFrame("Frame", nil, recipientButton)
|
||||
E:SetTemplate(recipientButton.bg, "Default")
|
||||
recipientButton.bg:SetPoint("TOPLEFT", recipientButton, "TOPRIGHT", 4, 0)
|
||||
recipientButton.bg:SetPoint("BOTTOMRIGHT", recipientNameFrame, "BOTTOMRIGHT", -5, 14)
|
||||
recipientButton.bg:SetFrameLevel(recipientButton:GetFrameLevel() - 4)
|
||||
end
|
||||
|
||||
TradePlayerItem1:SetPoint("TOPLEFT", 24, -104)
|
||||
|
||||
TradeHighlightPlayerTop:SetTexture(0, 1, 0, 0.2)
|
||||
TradeHighlightPlayerBottom:SetTexture(0, 1, 0, 0.2)
|
||||
TradeHighlightPlayerMiddle:SetTexture(0, 1, 0, 0.2)
|
||||
|
||||
TradeHighlightPlayerEnchantTop:SetTexture(0, 1, 0, 0.2)
|
||||
TradeHighlightPlayerEnchantBottom:SetTexture(0, 1, 0, 0.2)
|
||||
TradeHighlightPlayerEnchantMiddle:SetTexture(0, 1, 0, 0.2)
|
||||
|
||||
TradeHighlightRecipientTop:SetTexture(0, 1, 0, 0.2)
|
||||
TradeHighlightRecipientBottom:SetTexture(0, 1, 0, 0.2)
|
||||
TradeHighlightRecipientMiddle:SetTexture(0, 1, 0, 0.2)
|
||||
|
||||
TradeHighlightRecipientEnchantTop:SetTexture(0, 1, 0, 0.2)
|
||||
TradeHighlightRecipientEnchantBottom:SetTexture(0, 1, 0, 0.2)
|
||||
TradeHighlightRecipientEnchantMiddle:SetTexture(0, 1, 0, 0.2)
|
||||
|
||||
S:HandleButton(TradeFrameTradeButton)
|
||||
TradeFrameTradeButton:SetPoint("BOTTOMRIGHT", -120, 55)
|
||||
|
||||
S:HandleButton(TradeFrameCancelButton)
|
||||
|
||||
hooksecurefunc("TradeFrame_UpdatePlayerItem", function(id)
|
||||
local tradeItemButton = _G["TradePlayerItem"..id.."ItemButton"]
|
||||
local tradeItemName = _G["TradePlayerItem"..id.."Name"]
|
||||
|
||||
local name = GetTradePlayerItemInfo(id)
|
||||
if name then
|
||||
local _, _, _, quality = GetTradePlayerItemInfo(id)
|
||||
tradeItemName:SetTextColor(GetItemQualityColor(quality))
|
||||
if quality then
|
||||
tradeItemButton:SetBackdropBorderColor(GetItemQualityColor(quality))
|
||||
end
|
||||
else
|
||||
tradeItemButton:SetBackdropBorderColor(unpack(E["media"].bordercolor))
|
||||
end
|
||||
end)
|
||||
|
||||
hooksecurefunc("TradeFrame_UpdateTargetItem", function(id)
|
||||
local tradeItemButton = _G["TradeRecipientItem"..id.."ItemButton"]
|
||||
local tradeItemName = _G["TradeRecipientItem"..id.."Name"]
|
||||
|
||||
local name = GetTradeTargetItemInfo(id)
|
||||
if name then
|
||||
local _, _, _, quality = GetTradeTargetItemInfo(id)
|
||||
tradeItemName:SetTextColor(GetItemQualityColor(quality))
|
||||
if quality then
|
||||
tradeItemButton:SetBackdropBorderColor(GetItemQualityColor(quality))
|
||||
end
|
||||
else
|
||||
tradeItemButton:SetBackdropBorderColor(unpack(E["media"].bordercolor))
|
||||
end
|
||||
end)
|
||||
end
|
||||
|
||||
S:AddCallback("Trade", LoadSkin)
|
||||
@@ -0,0 +1,182 @@
|
||||
local E, L, V, P, G = unpack(ElvUI); --Import: Engine, Locales, PrivateDB, ProfileDB, GlobalDB
|
||||
local S = E:GetModule("Skins");
|
||||
|
||||
--Cache global variables
|
||||
--Lua functions
|
||||
local _G = _G
|
||||
local unpack = unpack
|
||||
local find, match, split = string.find, string.match, string.split
|
||||
--WoW API / Variables
|
||||
local GetItemInfo = GetItemInfo
|
||||
local GetItemQualityColor = GetItemQualityColor
|
||||
local GetTradeSkillItemLink = GetTradeSkillItemLink
|
||||
local GetTradeSkillReagentInfo = GetTradeSkillReagentInfo
|
||||
local GetTradeSkillReagentItemLink = GetTradeSkillReagentItemLink
|
||||
local hooksecurefunc = hooksecurefunc
|
||||
|
||||
local function LoadSkin()
|
||||
if E.private.skins.blizzard.enable ~= true or E.private.skins.blizzard.tradeskill ~= true then return end
|
||||
|
||||
E:StripTextures(TradeSkillFrame, true)
|
||||
E:CreateBackdrop(TradeSkillFrame, "Transparent")
|
||||
TradeSkillFrame.backdrop:SetPoint("TOPLEFT", 10, -11)
|
||||
TradeSkillFrame.backdrop:SetPoint("BOTTOMRIGHT", -32, 74)
|
||||
|
||||
E:StripTextures(TradeSkillRankFrameBorder)
|
||||
TradeSkillRankFrame:SetWidth(322)
|
||||
TradeSkillRankFrame:SetHeight(16)
|
||||
TradeSkillRankFrame:ClearAllPoints()
|
||||
TradeSkillRankFrame:SetPoint("TOP", -10, -45)
|
||||
E:CreateBackdrop(TradeSkillRankFrame)
|
||||
TradeSkillRankFrame:SetStatusBarTexture(E["media"].normTex)
|
||||
TradeSkillRankFrame:SetStatusBarColor(0.13, 0.35, 0.80)
|
||||
E:RegisterStatusBar(TradeSkillRankFrame)
|
||||
|
||||
E:StripTextures(TradeSkillExpandButtonFrame)
|
||||
|
||||
TradeSkillCollapseAllButton:SetNormalTexture("")
|
||||
TradeSkillCollapseAllButton.SetNormalTexture = E.noop
|
||||
TradeSkillCollapseAllButton:SetHighlightTexture("")
|
||||
TradeSkillCollapseAllButton.SetHighlightTexture = E.noop
|
||||
TradeSkillCollapseAllButton:SetDisabledTexture("")
|
||||
TradeSkillCollapseAllButton.SetDisabledTexture = E.noop
|
||||
|
||||
TradeSkillCollapseAllButton.Text = TradeSkillCollapseAllButton:CreateFontString(nil, "OVERLAY")
|
||||
E:FontTemplate(TradeSkillCollapseAllButton.Text, nil, 22)
|
||||
TradeSkillCollapseAllButton.Text:SetPoint("LEFT", 3, 0)
|
||||
TradeSkillCollapseAllButton.Text:SetText("+")
|
||||
|
||||
hooksecurefunc(TradeSkillCollapseAllButton, "SetNormalTexture", function(self, texture)
|
||||
if find(texture, "MinusButton") then
|
||||
self.Text:SetText("-")
|
||||
else
|
||||
self.Text:SetText("+")
|
||||
end
|
||||
end)
|
||||
|
||||
S:HandleDropDownBox(TradeSkillInvSlotDropDown, 140)
|
||||
TradeSkillSubClassDropDown:ClearAllPoints()
|
||||
TradeSkillInvSlotDropDown:SetPoint("TOPRIGHT", TradeSkillFrame, "TOPRIGHT", -32, -68)
|
||||
|
||||
S:HandleDropDownBox(TradeSkillSubClassDropDown, 140)
|
||||
TradeSkillSubClassDropDown:ClearAllPoints()
|
||||
TradeSkillSubClassDropDown:SetPoint("RIGHT", TradeSkillInvSlotDropDown, "RIGHT", -120, 0)
|
||||
|
||||
TradeSkillFrameTitleText:ClearAllPoints()
|
||||
TradeSkillFrameTitleText:SetPoint("TOP", TradeSkillFrame, "TOP", 0, -18)
|
||||
|
||||
for i = 1, TRADE_SKILLS_DISPLAYED do
|
||||
local skillButton = _G["TradeSkillSkill"..i]
|
||||
skillButton:SetNormalTexture("")
|
||||
skillButton.SetNormalTexture = 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)
|
||||
skillButton.Text:SetPoint("LEFT", 3, 0)
|
||||
skillButton.Text:SetText("+")
|
||||
|
||||
hooksecurefunc(skillButton, "SetNormalTexture", function(self, texture)
|
||||
if find(texture, "MinusButton") then
|
||||
self.Text:SetText("-")
|
||||
elseif find(texture, "PlusButton") then
|
||||
self.Text:SetText("+")
|
||||
else
|
||||
self.Text:SetText("")
|
||||
end
|
||||
end)
|
||||
end
|
||||
|
||||
E:StripTextures(TradeSkillDetailScrollFrame)
|
||||
E:StripTextures(TradeSkillListScrollFrame)
|
||||
E:StripTextures(TradeSkillDetailScrollChildFrame)
|
||||
|
||||
S:HandleScrollBar(TradeSkillListScrollFrameScrollBar)
|
||||
S:HandleScrollBar(TradeSkillDetailScrollFrameScrollBar)
|
||||
|
||||
E:StyleButton(TradeSkillSkillIcon, nil, true)
|
||||
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"]
|
||||
|
||||
icon:SetTexCoord(unpack(E.TexCoords))
|
||||
icon:SetDrawLayer("OVERLAY")
|
||||
|
||||
icon.backdrop = CreateFrame("Frame", nil, reagent)
|
||||
icon.backdrop:SetFrameLevel(reagent:GetFrameLevel() - 1)
|
||||
E:SetTemplate(icon.backdrop, "Default")
|
||||
E:SetOutside(icon.backdrop, icon)
|
||||
|
||||
icon:SetParent(icon.backdrop)
|
||||
count:SetParent(icon.backdrop)
|
||||
count:SetDrawLayer("OVERLAY")
|
||||
|
||||
E:Kill(nameFrame)
|
||||
end
|
||||
|
||||
S:HandleButton(TradeSkillCancelButton)
|
||||
S:HandleButton(TradeSkillCreateButton)
|
||||
S:HandleButton(TradeSkillCreateAllButton)
|
||||
|
||||
S:HandleNextPrevButton(TradeSkillDecrementButton)
|
||||
TradeSkillInputBox:SetHeight(16)
|
||||
S:HandleEditBox(TradeSkillInputBox)
|
||||
S:HandleNextPrevButton(TradeSkillIncrementButton)
|
||||
|
||||
S:HandleCloseButton(TradeSkillFrameCloseButton)
|
||||
|
||||
hooksecurefunc("TradeSkillFrame_SetSelection", function(id)
|
||||
E:SetTemplate(TradeSkillSkillIcon, "Default", true)
|
||||
E:StyleButton(TradeSkillSkillIcon, nil, true)
|
||||
if TradeSkillSkillIcon:GetNormalTexture() then
|
||||
TradeSkillSkillIcon:GetNormalTexture():SetTexCoord(unpack(E.TexCoords))
|
||||
E:SetInside(TradeSkillSkillIcon:GetNormalTexture())
|
||||
end
|
||||
|
||||
TradeSkillSkillIcon:SetWidth(40)
|
||||
TradeSkillSkillIcon:SetHeight(40)
|
||||
TradeSkillSkillIcon:SetPoint("TOPLEFT", 2, -3)
|
||||
|
||||
local skillLink = GetTradeSkillItemLink(id)
|
||||
if skillLink then
|
||||
local _, _, quality = GetItemInfo(match(skillLink, "item:(%d+)"))
|
||||
if quality then
|
||||
TradeSkillSkillIcon:SetBackdropBorderColor(GetItemQualityColor(quality))
|
||||
TradeSkillSkillName:SetTextColor(GetItemQualityColor(quality))
|
||||
else
|
||||
TradeSkillSkillIcon:SetBackdropBorderColor(unpack(E["media"].bordercolor))
|
||||
TradeSkillSkillName:SetTextColor(1, 1, 1)
|
||||
end
|
||||
end
|
||||
|
||||
local numReagents = GetTradeSkillNumReagents(id)
|
||||
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"]
|
||||
|
||||
if reagentLink 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)
|
||||
else
|
||||
name:SetTextColor(GetItemQualityColor(quality))
|
||||
end
|
||||
else
|
||||
icon.backdrop:SetBackdropBorderColor(unpack(E["media"].bordercolor))
|
||||
end
|
||||
end
|
||||
end
|
||||
end)
|
||||
end
|
||||
|
||||
S:AddCallbackForAddon("Blizzard_TradeSkillUI", "TradeSkill", LoadSkin)
|
||||
@@ -0,0 +1,94 @@
|
||||
local E, L, V, P, G = unpack(ElvUI); --Import: Engine, Locales, PrivateDB, ProfileDB, GlobalDB
|
||||
local S = E:GetModule("Skins");
|
||||
|
||||
--Cache global variables
|
||||
--Lua functions
|
||||
local _G = _G
|
||||
local unpack = unpack
|
||||
local find = string.find
|
||||
--WoW API / Variables
|
||||
local hooksecurefunc = hooksecurefunc
|
||||
|
||||
local function LoadSkin()
|
||||
if E.private.skins.blizzard.enable ~= true or E.private.skins.blizzard.trainer ~= true then return end
|
||||
|
||||
E:CreateBackdrop(ClassTrainerFrame, "Transparent")
|
||||
ClassTrainerFrame.backdrop:SetPoint("TOPLEFT", 10, -11)
|
||||
ClassTrainerFrame.backdrop:SetPoint("BOTTOMRIGHT", -32, 74)
|
||||
|
||||
E:StripTextures(ClassTrainerFrame, true)
|
||||
|
||||
E:StripTextures(ClassTrainerExpandButtonFrame)
|
||||
|
||||
S:HandleDropDownBox(ClassTrainerFrameFilterDropDown)
|
||||
ClassTrainerFrameFilterDropDown:SetPoint("TOPRIGHT", -40, -64)
|
||||
|
||||
E:StripTextures(ClassTrainerListScrollFrame)
|
||||
S:HandleScrollBar(ClassTrainerListScrollFrameScrollBar)
|
||||
|
||||
E:StripTextures(ClassTrainerDetailScrollFrame)
|
||||
S:HandleScrollBar(ClassTrainerDetailScrollFrameScrollBar)
|
||||
|
||||
E:StripTextures(ClassTrainerSkillIcon)
|
||||
|
||||
S:HandleButton(ClassTrainerTrainButton)
|
||||
S:HandleButton(ClassTrainerCancelButton)
|
||||
|
||||
S:HandleCloseButton(ClassTrainerFrameCloseButton)
|
||||
|
||||
hooksecurefunc("ClassTrainer_SetSelection", function()
|
||||
local skillIcon = ClassTrainerSkillIcon:GetNormalTexture()
|
||||
if skillIcon then
|
||||
E:SetInside(skillIcon)
|
||||
skillIcon:SetTexCoord(unpack(E.TexCoords))
|
||||
|
||||
E:SetTemplate(ClassTrainerSkillIcon, "Default")
|
||||
end
|
||||
end)
|
||||
|
||||
for i = 1, CLASS_TRAINER_SKILLS_DISPLAYED do
|
||||
local skillButton = _G["ClassTrainerSkill"..i]
|
||||
skillButton:SetNormalTexture("")
|
||||
skillButton.SetNormalTexture = E.noop
|
||||
|
||||
_G["ClassTrainerSkill"..i.."Highlight"]:SetTexture("")
|
||||
_G["ClassTrainerSkill"..i.."Highlight"].SetTexture = E.noop
|
||||
|
||||
skillButton.Text = skillButton:CreateFontString(nil, "OVERLAY")
|
||||
E:FontTemplate(skillButton.Text, nil, 22)
|
||||
skillButton.Text:SetPoint("LEFT", 3, 0)
|
||||
skillButton.Text:SetText("+")
|
||||
|
||||
hooksecurefunc(skillButton, "SetNormalTexture", function(self, texture)
|
||||
if find(texture, "MinusButton") then
|
||||
self.Text:SetText("-")
|
||||
elseif find(texture, "PlusButton") then
|
||||
self.Text:SetText("+")
|
||||
else
|
||||
self.Text:SetText("")
|
||||
end
|
||||
end)
|
||||
end
|
||||
|
||||
ClassTrainerCollapseAllButton:SetNormalTexture("")
|
||||
ClassTrainerCollapseAllButton.SetNormalTexture = E.noop
|
||||
ClassTrainerCollapseAllButton:SetHighlightTexture("")
|
||||
ClassTrainerCollapseAllButton.SetHighlightTexture = E.noop
|
||||
ClassTrainerCollapseAllButton:SetDisabledTexture("")
|
||||
ClassTrainerCollapseAllButton.SetDisabledTexture = E.noop
|
||||
|
||||
ClassTrainerCollapseAllButton.Text = ClassTrainerCollapseAllButton:CreateFontString(nil, "OVERLAY")
|
||||
E:FontTemplate(ClassTrainerCollapseAllButton.Text, nil, 22)
|
||||
ClassTrainerCollapseAllButton.Text:SetPoint("LEFT", 3, 0)
|
||||
ClassTrainerCollapseAllButton.Text:SetText("+")
|
||||
|
||||
hooksecurefunc(ClassTrainerCollapseAllButton, "SetNormalTexture", function(self, texture)
|
||||
if find(texture, "MinusButton") then
|
||||
self.Text:SetText("-")
|
||||
else
|
||||
self.Text:SetText("+")
|
||||
end
|
||||
end)
|
||||
end
|
||||
|
||||
S:AddCallbackForAddon("Blizzard_TrainerUI", "Trainer", LoadSkin)
|
||||
@@ -0,0 +1,33 @@
|
||||
local E, L, V, P, G = unpack(ElvUI); --Import: Engine, Locales, PrivateDB, ProfileDB, GlobalDB
|
||||
local S = E:GetModule("Skins");
|
||||
|
||||
--Cache global variables
|
||||
--Lua functions
|
||||
local _G = _G
|
||||
--WoW API / Variables
|
||||
local MAX_TUTORIAL_ALERTS = MAX_TUTORIAL_ALERTS
|
||||
|
||||
local function LoadSkin()
|
||||
if E.private.skins.blizzard.enable ~= true or E.private.skins.blizzard.tutorial ~= true then return end
|
||||
|
||||
for i = 1, MAX_TUTORIAL_ALERTS do
|
||||
local button = _G["TutorialFrameAlertButton"..i]
|
||||
local icon = button:GetNormalTexture()
|
||||
|
||||
button:SetWidth(35)
|
||||
button:SetHeight(45)
|
||||
E:SetTemplate(button, "Default", true)
|
||||
E:StyleButton(button, nil, true)
|
||||
|
||||
E:SetInside(icon)
|
||||
icon:SetTexCoord(0.09, 0.40, 0.11, 0.56)
|
||||
end
|
||||
|
||||
E:SetTemplate(TutorialFrame, "Transparent")
|
||||
|
||||
S:HandleCheckBox(TutorialFrameCheckButton)
|
||||
|
||||
S:HandleButton(TutorialFrameOkayButton)
|
||||
end
|
||||
|
||||
S:AddCallback("Tutorial", LoadSkin)
|
||||
@@ -0,0 +1,23 @@
|
||||
local E, L, V, P, G = unpack(ElvUI); --Import: Engine, Locales, PrivateDB, ProfileDB, GlobalDB
|
||||
local S = E:GetModule("Skins");
|
||||
|
||||
local function LoadSkin()
|
||||
if E.private.skins.blizzard.enable ~= true or E.private.skins.blizzard.worldmap ~= true then return end
|
||||
|
||||
E:StripTextures(WorldMapFrame)
|
||||
E:CreateBackdrop(WorldMapPositioningGuide, "Transparent")
|
||||
|
||||
S:HandleDropDownBox(WorldMapContinentDropDown, 170)
|
||||
S:HandleDropDownBox(WorldMapZoneDropDown, 170)
|
||||
|
||||
WorldMapZoneDropDown:SetPoint("LEFT", WorldMapContinentDropDown, "RIGHT", -24, 0)
|
||||
WorldMapZoomOutButton:SetPoint("LEFT", WorldMapZoneDropDown, "RIGHT", -4, 3)
|
||||
|
||||
S:HandleButton(WorldMapZoomOutButton)
|
||||
|
||||
S:HandleCloseButton(WorldMapFrameCloseButton)
|
||||
|
||||
E:CreateBackdrop(WorldMapDetailFrame, "Default")
|
||||
end
|
||||
|
||||
S:AddCallback("SkinWorldMap", LoadSkin)
|
||||
Reference in New Issue
Block a user