skins: only modify existing auction buttons

This commit is contained in:
shagu
2020-10-01 20:24:32 +02:00
parent dabd867944
commit e70f83f3bb
+15 -7
View File
@@ -58,15 +58,23 @@ pfUI:RegisterSkin("Auctionhouse", "vanilla:tbc", function ()
for i = 1, NUM_BROWSE_TO_DISPLAY do
local button = _G["BrowseButton"..i]
StripTextures(button, nil, "BACKGROUND")
CreateBackdrop(button, nil, true)
button:GetHighlightTexture():SetHeight(40)
if button then
StripTextures(button, nil, "BACKGROUND")
CreateBackdrop(button, nil, true)
local highlight = button:GetHighlightTexture()
if highlight then
highlight:SetHeight(40)
end
end
local item = _G["BrowseButton"..i.."Item"]
StripTextures(item)
SkinButton(item, nil, nil, nil, nil, true)
item:ClearAllPoints()
item:SetPoint("LEFT", 2, 0)
if item then
StripTextures(item)
SkinButton(item, nil, nil, nil, nil, true)
item:ClearAllPoints()
item:SetPoint("LEFT", 2, 0)
end
end
hooksecurefunc("AuctionFrameBrowse_Update", function()
for i = 1, NUM_BROWSE_TO_DISPLAY do