api: only add shadow to specific frames

This commit is contained in:
shagu
2019-06-02 20:41:09 +02:00
parent 85b4c4334a
commit 545be99fd7
63 changed files with 150 additions and 17 deletions
+16 -12
View File
@@ -790,20 +790,24 @@ function pfUI.api.CreateBackdrop(f, inset, legacy, transp, backdropSetting)
b:SetBackdropColor(br, bg, bb, ba)
b:SetBackdropBorderColor(er, eg, eb , ea)
end
end
-- add shadow
if not f.backdrop_shadow and pfUI_config.appearance.border.shadow == "1" then
local anchor = f.backdrop or f
f.backdrop_shadow = CreateFrame("Frame", nil, anchor)
f.backdrop_shadow:SetFrameStrata("BACKGROUND")
f.backdrop_shadow:SetFrameLevel(1)
f.backdrop_shadow:SetPoint("TOPLEFT", anchor, "TOPLEFT", -7, 7)
f.backdrop_shadow:SetPoint("BOTTOMRIGHT", anchor, "BOTTOMRIGHT", 7, -7)
f.backdrop_shadow:SetBackdrop(pfUI.backdrop_shadow)
f.backdrop_shadow:SetBackdropBorderColor(0,0,0,tonumber(pfUI_config.appearance.border.shadow_intensity))
-- [ Create Shadow ]
-- Creates a pfUI compatible frame as shadow element
-- 'f' [frame] the frame which should get a backdrop.
function pfUI.api.CreateBackdropShadow(f)
if f.backdrop_shadow or pfUI_config.appearance.border.shadow ~= "1" then
return
end
local anchor = f.backdrop or f
f.backdrop_shadow = CreateFrame("Frame", nil, anchor)
f.backdrop_shadow:SetFrameStrata("BACKGROUND")
f.backdrop_shadow:SetFrameLevel(1)
f.backdrop_shadow:SetPoint("TOPLEFT", anchor, "TOPLEFT", -7, 7)
f.backdrop_shadow:SetPoint("BOTTOMRIGHT", anchor, "BOTTOMRIGHT", 7, -7)
f.backdrop_shadow:SetBackdrop(pfUI.backdrop_shadow)
f.backdrop_shadow:SetBackdropBorderColor(0,0,0,tonumber(pfUI_config.appearance.border.shadow_intensity))
end
-- [ Bar Layout Options ] --
+1 -1
View File
@@ -117,7 +117,7 @@ function pfUI:LoadConfig()
pfUI:UpdateConfig("appearance", "border", "background", "0,0,0,1")
pfUI:UpdateConfig("appearance", "border", "color", "0.2,0.2,0.2,1")
pfUI:UpdateConfig("appearance", "border", "shadow", "0")
pfUI:UpdateConfig("appearance", "border", "shadow", "1")
pfUI:UpdateConfig("appearance", "border", "shadow_intensity", ".35")
pfUI:UpdateConfig("appearance", "border", "default", "3")
pfUI:UpdateConfig("appearance", "border", "actionbars", "-1")
+1
View File
@@ -674,6 +674,7 @@ function pfUI.api.CreateQuestionDialog(text, yes, no, editbox, onclose)
question:SetScript("OnHide", onclose)
pfUI.api.CreateBackdrop(question, nil, nil, .85)
pfUI.api.CreateBackdropShadow(question)
-- text
question.text = question:CreateFontString("Status", "LOW", "GameFontNormal")
+8 -2
View File
@@ -823,6 +823,8 @@ function pfUI.uf:CreateUnitFrame(unit, id, config, tick)
f.RegisterEvent = function() return end
end
CreateBackdropShadow(f)
f.hp = CreateFrame("Frame",nil, f)
f.hp.bar = CreateFrame("StatusBar", nil, f.hp)
f.power = CreateFrame("Frame",nil, f)
@@ -1154,7 +1156,9 @@ function pfUI.uf:RefreshUnit(unit, component)
texture, stacks = UnitBuff(unitstr, i)
end
pfUI.api.CreateBackdrop(unit.buffs[i], default_border)
CreateBackdrop(unit.buffs[i], default_border)
CreateBackdropShadow(unit.buffs[i])
unit.buffs[i].texture:SetTexture(texture)
if texture then
@@ -1219,7 +1223,9 @@ function pfUI.uf:RefreshUnit(unit, component)
texture, stacks, dtype = UnitDebuff(unitstr, i)
end
pfUI.api.CreateBackdrop(unit.debuffs[i], default_border)
CreateBackdrop(unit.debuffs[i], default_border)
CreateBackdropShadow(unit.debuffs[i])
unit.debuffs[i].texture:SetTexture(texture)
local r,g,b = DebuffTypeColor.none.r,DebuffTypeColor.none.g,DebuffTypeColor.none.b
+1
View File
@@ -885,6 +885,7 @@ pfUI:RegisterModule("actionbar", 20400, function ()
-- apply backdrop settings
if background == "1" then
CreateBackdrop(bars[i], border)
CreateBackdropShadow(bars[i])
bars[i].backdrop:Show()
-- share backdrop of main and top actionbar
+1
View File
@@ -34,6 +34,7 @@ pfUI:RegisterModule("addonbuttons", function ()
pfUI.addonbuttons:SetFrameStrata("HIGH")
pfUI.addonbuttons:Hide()
CreateBackdrop(pfUI.addonbuttons)
CreateBackdropShadow(frame.addonbuttons)
pfUI.addonbuttons.minimapbutton = CreateFrame("Button", "pfMinimapButton", pfUI.minimap or UIParent)
pfUI.addonbuttons.minimapbutton:SetFrameStrata("MEDIUM")
+1
View File
@@ -27,6 +27,7 @@ pfUI:RegisterModule("addons", 20400, function ()
pfUI.addons:Hide()
CreateBackdrop(pfUI.addons, nil, true, .75)
CreateBackdropShadow(pfUI.addons)
pfUI.addons:SetScript("OnHide", function()
UIDropDownMenu_ClearAll(this.profile.dropdown)
+2
View File
@@ -246,6 +246,7 @@ pfUI:RegisterModule("bags", 20400, function ()
pfUI.bag:CreateAdditions(frame)
frame:SetFrameStrata("HIGH")
CreateBackdrop(frame, default_border)
CreateBackdropShadow(frame)
local topspace = pfUI.bag.right.close:GetHeight() + default_border * 2
@@ -449,6 +450,7 @@ pfUI:RegisterModule("bags", 20400, function ()
frame.bagslots:SetPoint("BOTTOM"..position, frame, "TOP"..position, 0, default_border*3)
CreateBackdrop(frame.bagslots, default_border)
CreateBackdropShadow(frame.bagslots)
local extra = 0
if frame == pfUI.bag.left and GetNumBankSlots() < 6 then extra = 1 end
+1
View File
@@ -54,6 +54,7 @@ pfUI:RegisterModule("bubbles", 20400, function ()
f.frame.text:SetAllPoints(f.frame)
CreateBackdrop(f.frame, nil, nil, alpha)
CreateBackdropShadow(f.frame)
f.frame.backdrop:SetPoint("TOPLEFT", f, "TOPLEFT", -10, -10)
f.frame.backdrop:SetPoint("BOTTOMRIGHT", f, "BOTTOMRIGHT", 10, 10)
+2
View File
@@ -52,6 +52,7 @@ pfUI:RegisterModule("buff", 20400, function ()
buff.mode = buff.btype
buff.texture:SetTexture(GetPlayerBuffTexture(buff.bid))
CreateBackdrop(buff)
CreateBackdropShadow(buff)
if buff.btype == "HARMFUL" then
local dtype = GetPlayerBuffDispelType(buff.bid)
@@ -193,6 +194,7 @@ pfUI:RegisterModule("buff", 20400, function ()
end)
CreateBackdrop(buff)
CreateBackdropShadow(buff)
RefreshBuffButton(buff)
return buff
+1
View File
@@ -200,6 +200,7 @@ pfUI:RegisterModule("buffwatch", function ()
frame:SetScript("OnLeave", StatusBarOnLeave)
CreateBackdrop(frame)
CreateBackdropShadow(frame)
if bordercolor.r ~= "0" and bordercolor.g ~= "0" and bordercolor.b ~= "0" and bordercolor.a ~= "0" then
frame.backdrop:SetBackdropBorderColor(bordercolor.r,bordercolor.g,bordercolor.b,1)
end
+2
View File
@@ -28,6 +28,7 @@ pfUI:RegisterModule("castbar", 20400, function ()
cb.icon.texture:SetAllPoints()
cb.icon.texture:SetTexCoord(.08, .92, .08, .92)
CreateBackdrop(cb.icon, default_border)
CreateBackdropShadow(cb.icon)
-- statusbar
cb.bar = CreateFrame("StatusBar", nil, cb)
@@ -39,6 +40,7 @@ pfUI:RegisterModule("castbar", 20400, function ()
local r,g,b,a = strsplit(",", C.appearance.castbar.castbarcolor)
cb.bar:SetStatusBarColor(r,g,b,a)
CreateBackdrop(cb.bar, default_border)
CreateBackdropShadow(cb.bar)
-- text left
cb.bar.left = cb.bar:CreateFontString("Status", "DIALOG", "GameFontNormal")
+3
View File
@@ -38,6 +38,8 @@ pfUI:RegisterModule("chat", 20400, function ()
pfUI.chat.left:SetScript("OnShow", function() pfUI.chat:RefreshChat() end)
UpdateMovable(pfUI.chat.left)
CreateBackdrop(pfUI.chat.left, default_border, nil, .8)
CreateBackdropShadow(pfUI.chat.left)
if C.chat.global.custombg == "1" then
local r, g, b, a = strsplit(",", C.chat.global.background)
pfUI.chat.left.backdrop:SetBackdropColor(tonumber(r), tonumber(g), tonumber(b), tonumber(a))
@@ -195,6 +197,7 @@ pfUI:RegisterModule("chat", 20400, function ()
pfUI.chat.right:SetScript("OnShow", function() pfUI.chat:RefreshChat() end)
UpdateMovable(pfUI.chat.right)
CreateBackdrop(pfUI.chat.right, default_border, nil, .8)
CreateBackdropShadow(pfUI.chat.right)
if C.chat.global.custombg == "1" then
local r, g, b, a = strsplit(",", C.chat.global.background)
pfUI.chat.right.backdrop:SetBackdropColor(tonumber(r), tonumber(g), tonumber(b), tonumber(a))
+1
View File
@@ -23,6 +23,7 @@ pfUI:RegisterModule("combopoints", function ()
pfUI.combopoints["combopoint" .. point]:SetWidth(combo_size)
pfUI.combopoints["combopoint" .. point]:SetHeight(combo_size)
CreateBackdrop(pfUI.combopoints["combopoint" .. point])
CreateBackdropShadow(pfUI.combopoints["combopoint" .. point])
if pfUI.uf.target then
pfUI.combopoints["combopoint" .. point]:SetPoint("TOPLEFT", pfUI.uf.target, "TOPRIGHT", C.appearance.border.default*3, -(point - 1) * (combo_size + C.appearance.border.default*3))
+1
View File
@@ -66,6 +66,7 @@ pfUI:RegisterModule("firstrun", 20400, function ()
end)
CreateBackdrop(f, nil, nil, .85)
CreateBackdropShadow(f)
-- text
f.text = f:CreateFontString("Status", "OVERLAY", "GameFontNormal")
+1
View File
@@ -623,6 +623,7 @@ pfUI:RegisterModule("gui", 20400, function ()
end)
CreateBackdrop(pfUI.gui, nil, true, .85)
CreateBackdropShadow(pfUI.gui)
table.insert(UISpecialFrames, "pfConfigGUI")
-- make some locals available to thirdparty
+2
View File
@@ -493,8 +493,10 @@ pfUI:RegisterModule("loot", 20400, function ()
local color = ITEM_QUALITY_COLORS[maxrarity]
if maxrarity <= 1 then
CreateBackdrop(pfUI.loot)
CreateBackdropShadow(pfUI.loot)
else
CreateBackdrop(pfUI.loot)
CreateBackdropShadow(pfUI.loot)
pfUI.loot.backdrop:SetBackdropBorderColor(color.r, color.g, color.b, 1)
end
pfUI.loot:SetHeight(math.max((real*22)+4*C.appearance.border.default), 20)
+1
View File
@@ -71,6 +71,7 @@ pfUI:RegisterModule("map", 20400, function ()
-- skin
WorldMapFrameCloseButton:SetPoint("TOPRIGHT", WorldMapFrame, "TOPRIGHT", 0, 0)
CreateBackdrop(WorldMapFrame)
CreateBackdropShadow(WorldMapFrame)
BlackoutWorld:Hide()
StripTextures(WorldMapFrame)
+1
View File
@@ -11,6 +11,7 @@ pfUI:RegisterModule("minimap", 20400, function ()
pfUI.minimap = CreateFrame("Frame","pfMinimap",UIParent)
CreateBackdrop(pfUI.minimap)
CreateBackdropShadow(pfUI.minimap)
pfUI.minimap:SetPoint("TOPRIGHT", UIParent, -5, -5)
UpdateMovable(pfUI.minimap)
pfUI.minimap:SetWidth(140)
+1
View File
@@ -18,6 +18,7 @@ pfUI:RegisterModule("mirrortimers", function ()
statusBar:SetHeight(18)
statusBar:SetPoint("TOP", 0, 0)
CreateBackdrop(statusBar)
CreateBackdropShadow(statusBar)
mirrorTimer:SetWidth(statusBar:GetWidth())
mirrorTimer:SetHeight(statusBar:GetHeight())
+3
View File
@@ -538,6 +538,7 @@ pfUI:RegisterModule("panel", 20400, function()
pfUI.panel.left:SetHeight(C.global.font_size*1.5)
CreateBackdrop(pfUI.panel.left, default_border, nil)
CreateBackdropShadow(pfUI.panel.left)
UpdateMovable(pfUI.panel.left)
pfUI.panel.left.hide = CreateFrame("Button", nil, pfUI.panel.left)
@@ -618,6 +619,7 @@ pfUI:RegisterModule("panel", 20400, function()
pfUI.panel.right:SetHeight(C.global.font_size*1.5)
CreateBackdrop(pfUI.panel.right, default_border, nil)
CreateBackdropShadow(pfUI.panel.right)
UpdateMovable(pfUI.panel.right)
pfUI.panel.right.hide = CreateFrame("Button", nil, pfUI.panel.right)
@@ -695,6 +697,7 @@ pfUI:RegisterModule("panel", 20400, function()
pfUI.panel.minimap:SetFrameStrata("MEDIUM")
CreateBackdrop(pfUI.panel.minimap, default_border)
CreateBackdropShadow(pfUI.panel.minimap)
UpdateMovable(pfUI.panel.minimap)
pfUI.panel.minimap.text = pfUI.panel.minimap:CreateFontString("MinimapZoneText", "LOW", "GameFontNormal")
+2
View File
@@ -79,6 +79,8 @@ pfUI:RegisterModule("roll", 20400, function ()
local f = CreateFrame("Frame", "pfLootRollFrame" .. id, UIParent)
CreateBackdrop(f, nil, nil, .8)
CreateBackdropShadow(f)
f.backdrop:SetFrameStrata("BACKGROUND")
f.hasItem = 1
+1
View File
@@ -272,6 +272,7 @@ pfUI:RegisterModule("share", 20400, function ()
end)
CreateBackdrop(f, nil, true, 0.8)
CreateBackdropShadow(f)
table.insert(UISpecialFrames, "pfShare")
do -- Edit Box
+3
View File
@@ -58,7 +58,10 @@ pfUI:RegisterModule("skin", 20400, function ()
for i = 1, UIDROPDOWNMENU_MAXLEVELS do
CreateBackdrop(_G["DropDownList"..i.."MenuBackdrop"], nil, true, .8)
CreateBackdropShadow(_G["DropDownList"..i.."MenuBackdrop"])
CreateBackdrop(_G["DropDownList"..i.."Backdrop"], nil, true, .8)
CreateBackdropShadow(_G["DropDownList"..i.."Backdrop"])
end
if C.global.errors_limit == "1" then
+12 -1
View File
@@ -35,7 +35,7 @@ pfUI:RegisterModule("thirdparty", function ()
local function RefreshKtmWidth(width)
local width = width or pfUI.chat.right:GetWidth()
if (pfUI.thirdparty.meters.damage and pfUI.thirdparty.meters.threat) then
if (pfUI.thirdparty.meters.damage and pfUI.thirdparty.meters.threat) then
width = width / 2
end
SetKtmWidth(KLHTM_Gui.raid, GetKtmWidthDiff(KLHTM_Gui.raid, width))
@@ -210,6 +210,7 @@ pfUI:RegisterModule("thirdparty", function ()
end
CreateBackdrop(KLHTM_Frame, nil, nil, (C.thirdparty.chatbg == "1" and .8))
CreateBackdropShadow(KLHTM_Frame)
if C.thirdparty.chatbg == "1" and C.chat.global.custombg == "1" then
local r, g, b, a = strsplit(",", C.chat.global.background)
@@ -321,6 +322,7 @@ pfUI:RegisterModule("thirdparty", function ()
for k, val in pairs(DPSMateSettings["windows"]) do
local frame = _G["DPSMate_"..val["name"]]
CreateBackdrop(frame, nil, nil, (C.thirdparty.chatbg == "1" and .8))
CreateBackdropShadow(frame)
if C.thirdparty.chatbg == "1" and C.chat.global.custombg == "1" then
local r, g, b, a = strsplit(",", C.chat.global.background)
@@ -390,6 +392,7 @@ pfUI:RegisterModule("thirdparty", function ()
_G.SW_BARSEPY = 1
CreateBackdrop(SW_BarFrame1, nil, nil, (C.thirdparty.chatbg == "1" and .8))
CreateBackdropShadow(SW_BarFrame1)
if C.thirdparty.chatbg == "1" and C.chat.global.custombg == "1" then
local r, g, b, a = strsplit(",", C.chat.global.background)
@@ -447,6 +450,8 @@ pfUI:RegisterModule("thirdparty", function ()
local windowname = this:GetName()
CreateBackdrop(_G[windowname], nil, nil, .8)
CreateBackdropShadow(_G[windowname])
_G[windowname .. "From"]:ClearAllPoints()
_G[windowname .. "From"]:SetPoint("TOP", 0, -10)
@@ -724,6 +729,7 @@ pfUI:RegisterModule("thirdparty", function ()
FlightMapTimesFrame:SetStatusBarTexture("Interface\\AddOns\\pfUI\\img\\bar")
FlightMapTimesFrame:SetHeight(18)
CreateBackdrop(FlightMapTimesFrame)
CreateBackdropShadow(FlightMapTimesFrame)
FlightMapTimesText:ClearAllPoints()
FlightMapTimesText:SetPoint("CENTER", FlightMapTimesFrame, "CENTER", 0, 0)
@@ -800,6 +806,8 @@ pfUI:RegisterModule("thirdparty", function ()
if C.thirdparty.atlasloot.enable == "0" then return end
CreateBackdrop(AtlasLootTooltip)
CreateBackdropShadow(AtlasLootTooltip)
if pfUI.eqcompare then
HookScript(AtlasLootTooltip, "OnShow", pfUI.eqcompare.GameTooltipShow)
HookScript(AtlasLootTooltip, "OnHide", function()
@@ -852,6 +860,7 @@ pfUI:RegisterModule("thirdparty", function ()
DruidManaBar.text:SetFontObject(GameFontWhite)
CreateBackdrop(DruidManaBar)
CreateBackdropShadow(DruidManaBar)
DruidManaBar:SetScript("OnMouseUp", function(button)
f:Click(button)
@@ -892,6 +901,8 @@ pfUI:RegisterModule("thirdparty", function ()
-- Main window
pfUI.api.StripTextures(NoteInputFrame, true)
CreateBackdrop(NoteInputFrame, nil, nil, .75)
CreateBackdropShadow(NoteInputFrame)
NoteInputFrame.backdrop:SetPoint("TOPLEFT", 10, -12)
NoteInputFrame.backdrop:SetPoint("BOTTOMRIGHT", -32, 30)
+3 -1
View File
@@ -1,5 +1,5 @@
pfUI:RegisterModule("tooltip", 20400, function ()
pfUI.tooltip = CreateFrame('Frame', "pfTooltip", GameTooltip)
pfUI.tooltip.anchorframe = CreateFrame('Frame', "pfTooltipAnchor", UIParent)
pfUI.tooltip.anchorframe:SetWidth(128)
@@ -154,6 +154,8 @@ pfUI:RegisterModule("tooltip", 20400, function ()
GameTooltipStatusBar:SetPoint("BOTTOMRIGHT", GameTooltip, "TOPRIGHT", 0, 0)
GameTooltipStatusBar:SetStatusBarTexture("Interface\\AddOns\\pfUI\\img\\bar")
CreateBackdrop(GameTooltipStatusBar)
CreateBackdropShadow(GameTooltipStatusBar)
GameTooltipStatusBar.SetStatusBarColor_orig = GameTooltipStatusBar.SetStatusBarColor
GameTooltipStatusBar.SetStatusBarColor = function() return end
+2
View File
@@ -51,6 +51,8 @@ pfUI:RegisterModule("tracking", function ()
pfUI.tracking = CreateFrame("Button", "pfUITracking", UIParent)
pfUI.tracking:SetFrameStrata("LOW")
CreateBackdrop(pfUI.tracking, config.border)
CreateBackdropShadow(pfUI.tracking)
pfUI.tracking:SetPoint("TOPLEFT", pfUI.minimap, -10, -10)
UpdateMovable(pfUI.tracking)
pfUI.tracking:SetWidth(config.size)
+2
View File
@@ -23,6 +23,7 @@ pfUI:RegisterModule("xpbar", 20400, function ()
end
pfUI.xp:SetFrameStrata("BACKGROUND")
CreateBackdrop(pfUI.xp)
CreateBackdropShadow(pfUI.xp)
UpdateMovable(pfUI.xp)
pfUI.xp:RegisterEvent("PLAYER_LEVEL_UP")
@@ -142,6 +143,7 @@ pfUI:RegisterModule("xpbar", 20400, function ()
end
pfUI.rep:SetFrameStrata("BACKGROUND")
CreateBackdrop(pfUI.rep)
CreateBackdropShadow(pfUI.rep)
UpdateMovable(pfUI.rep)
pfUI.rep.bar = CreateFrame("StatusBar", nil, pfUI.rep)
+3
View File
@@ -10,6 +10,7 @@ pfUI:RegisterSkin("Auctionhouse", function ()
StripTextures(AuctionFrame, true)
CreateBackdrop(AuctionFrame, nil, nil, .75)
CreateBackdropShadow(AuctionFrame)
EnableMovable(AuctionFrame)
SkinCloseButton(AuctionFrameCloseButton, AuctionFrame.backdrop, -6, -6)
@@ -205,6 +206,8 @@ pfUI:RegisterSkin("Auctionhouse", function ()
do -- AuctionDressUpFrame
StripTextures(AuctionDressUpFrame, nil, "BACKGROUND")
CreateBackdrop(AuctionDressUpFrame, nil, true, .75)
CreateBackdropShadow(AuctionDressUpFrame)
AuctionDressUpFrame:ClearAllPoints()
AuctionDressUpFrame:SetPoint("LEFT", AuctionFrame.backdrop, "RIGHT", 4, 0)
+2
View File
@@ -4,6 +4,8 @@ pfUI:RegisterSkin("Battlefield", function ()
StripTextures(BattlefieldFrame)
CreateBackdrop(BattlefieldFrame, nil, nil, .75)
CreateBackdropShadow(BattlefieldFrame)
BattlefieldFrame.backdrop:SetPoint("TOPLEFT", 10, -10)
BattlefieldFrame.backdrop:SetPoint("BOTTOMRIGHT", -32, 72)
BattlefieldFrame:SetHitRectInsets(10,32,10,72)
+1
View File
@@ -4,6 +4,7 @@ pfUI:RegisterSkin("Battlefield Minimap", function ()
HookAddonOrVariable("Blizzard_BattlefieldMinimap", function()
StripTextures(BattlefieldMinimap)
CreateBackdrop(BattlefieldMinimap, nil, nil, 0)
CreateBackdropShadow(BattlefieldMinimap)
BattlefieldMinimap:SetWidth(220)
BattlefieldMinimap:SetHeight(146)
+2
View File
@@ -4,6 +4,8 @@ pfUI:RegisterSkin("Battlefield Score", function ()
StripTextures(WorldStateScoreFrame)
CreateBackdrop(WorldStateScoreFrame, nil, nil, .75)
CreateBackdropShadow(WorldStateScoreFrame)
WorldStateScoreFrame.backdrop:SetPoint("TOPLEFT", 10, -14)
WorldStateScoreFrame.backdrop:SetPoint("BOTTOMRIGHT", -112, 68)
WorldStateScoreFrame:SetHitRectInsets(10,112,14,68)
+2
View File
@@ -11,6 +11,8 @@ pfUI:RegisterSkin("Character", function ()
}
CreateBackdrop(CharacterFrame, nil, nil, .75)
CreateBackdropShadow(CharacterFrame)
CharacterFrame.backdrop:SetPoint("TOPLEFT", 10, -10)
CharacterFrame.backdrop:SetPoint("BOTTOMRIGHT", -30, 72)
CharacterFrame:SetHitRectInsets(10,30,10,72)
+2
View File
@@ -4,6 +4,8 @@ pfUI:RegisterSkin("Dress Up Frame", function ()
StripTextures(DressUpFrame, nil, "ARTWORK")
CreateBackdrop(DressUpFrame, nil, nil, .75)
CreateBackdropShadow(DressUpFrame)
DressUpFrame.backdrop:SetPoint("TOPLEFT", 10, -10)
DressUpFrame.backdrop:SetPoint("BOTTOMRIGHT", -32, 72)
DressUpFrame:SetHitRectInsets(10,32,10,72)
+2
View File
@@ -4,6 +4,8 @@ pfUI:RegisterSkin("Friends", function ()
StripTextures(FriendsFrame, true)
CreateBackdrop(FriendsFrame, nil, nil, .75)
CreateBackdropShadow(FriendsFrame)
FriendsFrame.backdrop:SetPoint("TOPLEFT", 8, -10)
FriendsFrame.backdrop:SetPoint("BOTTOMRIGHT", -32, 74)
FriendsFrame:SetHitRectInsets(8,32,10,74)
+2
View File
@@ -1,6 +1,8 @@
pfUI:RegisterSkin("Game Menu", 20400, function ()
StripTextures(GameMenuFrame)
CreateBackdrop(GameMenuFrame, nil, true, .75)
CreateBackdropShadow(GameMenuFrame)
GameMenuFrame:SetHeight(GameMenuFrame:GetHeight() + 2)
GameMenuFrame:SetWidth(GameMenuFrame:GetWidth() - 30)
+2
View File
@@ -74,6 +74,8 @@ pfUI:RegisterSkin("Gossip and Quest", function ()
local frame = _G[frameName.."Frame"]
local NPCName = _G[frame:GetName().."NpcNameText"]
CreateBackdrop(frame, nil, nil, .75)
CreateBackdropShadow(frame)
frame.backdrop:SetPoint("TOPLEFT", 12, -18)
frame.backdrop:SetPoint("BOTTOMRIGHT", -28, 66)
frame:SetHitRectInsets(12,28,18,66)
+2
View File
@@ -2,6 +2,8 @@ pfUI:RegisterSkin("Guild Registrar", function ()
StripTextures(GuildRegistrarFrame)
StripTextures(GuildRegistrarGreetingFrame)
CreateBackdrop(GuildRegistrarFrame, nil, nil, .75)
CreateBackdropShadow(GuildRegistrarFrame)
GuildRegistrarFrame.backdrop:SetPoint("TOPLEFT", 12, -16)
GuildRegistrarFrame.backdrop:SetPoint("BOTTOMRIGHT", -28, 66)
GuildRegistrarFrame:SetHitRectInsets(12,28,16,66)
+2
View File
@@ -4,6 +4,8 @@ pfUI:RegisterSkin("Help", function ()
StripTextures(HelpFrame)
CreateBackdrop(HelpFrame, nil, nil, .75)
CreateBackdropShadow(HelpFrame)
HelpFrame.backdrop:SetPoint("TOPLEFT", 4, -4)
HelpFrame.backdrop:SetPoint("BOTTOMRIGHT", -44, 12)
HelpFrame:SetHitRectInsets(4,44,4,12)
+2
View File
@@ -6,6 +6,8 @@ pfUI:RegisterSkin("Inspect", function ()
local cache = {}
CreateBackdrop(InspectFrame, nil, nil, .75)
CreateBackdropShadow(InspectFrame)
InspectFrame.backdrop:SetPoint("TOPLEFT", 10, -10)
InspectFrame.backdrop:SetPoint("BOTTOMRIGHT", -30, 72)
InspectFrame:SetHitRectInsets(10,30,10,72)
+2
View File
@@ -1,6 +1,8 @@
pfUI:RegisterSkin("Books", function ()
StripTextures(ItemTextFrame)
CreateBackdrop(ItemTextFrame, nil, nil, .75)
CreateBackdropShadow(ItemTextFrame)
ItemTextFrame.backdrop:SetPoint("TOPLEFT", 12, -12)
ItemTextFrame.backdrop:SetPoint("BOTTOMRIGHT", -30, 72)
ItemTextFrame:SetHitRectInsets(12,30,12,72)
+2
View File
@@ -5,6 +5,8 @@ pfUI:RegisterSkin("KeyBindings", function ()
HookAddonOrVariable("Blizzard_BindingUI", function()
StripTextures(KeyBindingFrame)
CreateBackdrop(KeyBindingFrame, nil, nil, .75)
CreateBackdropShadow(KeyBindingFrame)
KeyBindingFrame.backdrop:SetPoint("TOPLEFT", 2, 10)
KeyBindingFrame.backdrop:SetPoint("BOTTOMRIGHT", -42, 10)
KeyBindingFrame:SetHitRectInsets(2,42,10,10)
+2
View File
@@ -5,6 +5,8 @@ pfUI:RegisterSkin("Macro", function ()
HookAddonOrVariable("Blizzard_MacroUI", function()
StripTextures(MacroFrame)
CreateBackdrop(MacroFrame, nil, nil, .75)
CreateBackdropShadow(MacroFrame)
MacroFrame.backdrop:SetPoint("TOPLEFT", 10, -10)
MacroFrame.backdrop:SetPoint("BOTTOMRIGHT", -32, 72)
MacroFrame:SetHitRectInsets(10,32,10,72)
+2
View File
@@ -16,6 +16,8 @@ pfUI:RegisterSkin("Mailbox", function ()
StripTextures(MailFrame, true)
CreateBackdrop(MailFrame, nil, nil, .75)
CreateBackdropShadow(MailFrame)
MailFrame.backdrop:SetPoint("TOPLEFT", 12, -12)
MailFrame.backdrop:SetPoint("BOTTOMRIGHT", -30, 72)
MailFrame:SetHitRectInsets(12,30,12,72)
+2
View File
@@ -4,6 +4,8 @@ pfUI:RegisterSkin("Merchant", function ()
StripTextures(MerchantFrame)
CreateBackdrop(MerchantFrame, nil, nil, .75)
CreateBackdropShadow(MerchantFrame)
MerchantFrame.backdrop:SetPoint("TOPLEFT", 10, -10)
MerchantFrame.backdrop:SetPoint("BOTTOMRIGHT", -32, 58)
MerchantFrame:SetHitRectInsets(10,32,10,58)
+8
View File
@@ -1,6 +1,7 @@
pfUI:RegisterSkin("Stack Split", function ()
StripTextures(StackSplitFrame)
CreateBackdrop(StackSplitFrame, nil, nil, .75)
CreateBackdropShadow(StackSplitFrame)
SkinButton(StackSplitOkayButton)
SkinButton(StackSplitCancelButton)
@@ -9,6 +10,7 @@ end)
pfUI:RegisterSkin("Coin Pickup", function ()
StripTextures(CoinPickupFrame)
CreateBackdrop(CoinPickupFrame, nil, nil, .75)
CreateBackdropShadow(CoinPickupFrame)
SkinButton(CoinPickupOkayButton)
SkinButton(CoinPickupCancelButton)
@@ -16,6 +18,7 @@ end)
pfUI:RegisterSkin("Color Picker", function ()
CreateBackdrop(ColorPickerFrame)
CreateBackdropShadow(ColorPickerFrame)
ColorPickerFrameHeader:SetTexture("")
@@ -31,6 +34,7 @@ end)
pfUI:RegisterSkin("Opacity", function ()
CreateBackdrop(OpacityFrame, nil, true, .75)
CreateBackdropShadow(OpacityFrame)
SkinSlider(OpacityFrameSlider)
OpacityFrameSlider:ClearAllPoints()
@@ -39,11 +43,15 @@ end)
pfUI:RegisterSkin("Tutorial", function ()
CreateBackdrop(TutorialFrame, nil, true, .75)
CreateBackdropShadow(TutorialFrame)
SkinCheckbox(TutorialFrameCheckButton)
SkinButton(TutorialFrameOkayButton)
end)
pfUI:RegisterSkin("Quest Timer", function ()
CreateBackdrop(QuestTimerFrame, nil, nil, .75)
CreateBackdropShadow(QuestTimerFrame)
QuestTimerHeader:Hide()
end)
+2
View File
@@ -8,6 +8,8 @@ pfUI:RegisterSkin("Options - Interface", function ()
StripTextures(UIOptionsFrame)
CreateBackdrop(UIOptionsFrame, nil, nil, .75)
CreateBackdropShadow(UIOptionsFrame)
EnableMovable(UIOptionsFrame)
HookScript(UIOptionsFrame, "OnShow", function()
+2
View File
@@ -4,6 +4,8 @@ pfUI:RegisterSkin("Options - Sound", function ()
StripTextures(SoundOptionsFrame)
CreateBackdrop(SoundOptionsFrame, nil, true, .75)
CreateBackdropShadow(SoundOptionsFrame)
EnableMovable(SoundOptionsFrame)
HookScript(SoundOptionsFrame, "OnShow", function()
+2
View File
@@ -3,6 +3,8 @@ pfUI:RegisterSkin("Options - Video", function ()
local bpad = border > 1 and border - 1 or 1
CreateBackdrop(OptionsFrame, nil, nil, .75)
CreateBackdropShadow(OptionsFrame)
EnableMovable(OptionsFrame)
HookScript(OptionsFrame, "OnShow", function()
+2
View File
@@ -4,6 +4,8 @@ pfUI:RegisterSkin("Petition", function ()
StripTextures(PetitionFrame)
CreateBackdrop(PetitionFrame, nil, nil, .75)
CreateBackdropShadow(PetitionFrame)
PetitionFrame.backdrop:SetPoint("TOPLEFT", 12, -16)
PetitionFrame.backdrop:SetPoint("BOTTOMRIGHT", -28, 66)
PetitionFrame:SetHitRectInsets(12,28,16,66)
+2
View File
@@ -3,6 +3,8 @@ pfUI:RegisterSkin("Popup Dialogs", function ()
local dialog = _G["StaticPopup"..i]
CreateBackdrop(dialog, nil, true, .75)
CreateBackdropShadow(dialog)
SkinCloseButton(_G[dialog:GetName().."CloseButton"], dialog, -6, -6)
SkinButton(_G[dialog:GetName().."Button1"])
+1
View File
@@ -53,6 +53,7 @@ pfUI:RegisterSkin("Profession", function ()
StripTextures(frame)
CreateBackdrop(frame, nil, nil, .75)
CreateBackdropShadow(frame)
frame:SetWidth(676)
frame:SetHeight(440)
+2
View File
@@ -17,6 +17,8 @@ pfUI:RegisterSkin("Quest Log", function ()
StripTextures(QuestLogFrame, true)
CreateBackdrop(QuestLogFrame, nil, nil, .75)
CreateBackdropShadow(QuestLogFrame)
EnableMovable(QuestLogFrame)
QuestLogTitleText:ClearAllPoints()
+1
View File
@@ -2,6 +2,7 @@ pfUI:RegisterSkin("Readycheck", function ()
HookAddonOrVariable("Blizzard_RaidUI", function()
StripTextures(ReadyCheckFrame, true)
CreateBackdrop(ReadyCheckFrame, nil, nil, .75)
CreateBackdropShadow(ReadyCheckFrame)
SkinButton(ReadyCheckFrameYesButton)
ReadyCheckFrameYesButton:ClearAllPoints()
+2
View File
@@ -4,6 +4,8 @@ pfUI:RegisterSkin("Spellbook", function ()
StripTextures(SpellBookFrame)
CreateBackdrop(SpellBookFrame, nil, nil, .75)
CreateBackdropShadow(SpellBookFrame)
SpellBookFrame.backdrop:SetPoint("TOPLEFT", 12, -12)
SpellBookFrame.backdrop:SetPoint("BOTTOMRIGHT", -30, 72)
SpellBookFrame:SetHitRectInsets(12,30,12,72)
+2
View File
@@ -1,6 +1,8 @@
pfUI:RegisterSkin("Pet Stable Master", function ()
StripTextures(PetStableFrame)
CreateBackdrop(PetStableFrame, nil, nil, .75)
CreateBackdropShadow(PetStableFrame)
PetStableFrame.backdrop:SetPoint("TOPLEFT", 10, -10)
PetStableFrame.backdrop:SetPoint("BOTTOMRIGHT", -32, 72)
PetStableFrame:SetHitRectInsets(10,32,10,72)
+2
View File
@@ -2,6 +2,8 @@ pfUI:RegisterSkin("GM Survey", function ()
HookAddonOrVariable("Blizzard_GMSurveyUI", function()
StripTextures(GMSurveyFrame)
CreateBackdrop(GMSurveyFrame, nil, nil, .75)
CreateBackdropShadow(GMSurveyFrame)
GMSurveyFrame.backdrop:SetPoint("TOPLEFT", 10, 0)
GMSurveyFrame.backdrop:SetPoint("BOTTOMRIGHT", -72, 40)
GMSurveyFrame:SetHitRectInsets(10,72,0,40)
+2
View File
@@ -4,6 +4,8 @@ pfUI:RegisterSkin("Guild Tabard", function ()
StripTextures(TabardFrame)
CreateBackdrop(TabardFrame, nil, nil, .75)
CreateBackdropShadow(TabardFrame)
TabardFrame.backdrop:SetPoint("TOPLEFT", 10, -10)
TabardFrame.backdrop:SetPoint("BOTTOMRIGHT", -32, 72)
TabardFrame:SetHitRectInsets(10,32,10,72)
+2
View File
@@ -5,6 +5,8 @@ pfUI:RegisterSkin("Talents", function ()
HookAddonOrVariable("Blizzard_TalentUI", function()
StripTextures(TalentFrame)
CreateBackdrop(TalentFrame, nil, nil, .75)
CreateBackdropShadow(TalentFrame)
TalentFrame.backdrop:SetPoint("TOPLEFT", 10, -10)
TalentFrame.backdrop:SetPoint("BOTTOMRIGHT", -32, 72)
TalentFrame:SetHitRectInsets(10,32,10,72)
+2
View File
@@ -1,6 +1,8 @@
pfUI:RegisterSkin("Flightmaster", function ()
StripTextures(TaxiFrame)
CreateBackdrop(TaxiFrame, nil, nil, .75)
CreateBackdropShadow(TaxiFrame)
TaxiFrame.backdrop:SetPoint("TOPLEFT", 10, -10)
TaxiFrame.backdrop:SetPoint("BOTTOMRIGHT", -32, 72)
TaxiFrame:SetHitRectInsets(10,32,10,72)
+2
View File
@@ -4,10 +4,12 @@ pfUI:RegisterSkin("Tooltips", 20400, function ()
for _, tooltip in pairs({GameTooltip, ItemRefTooltip, ShoppingTooltip1, ShoppingTooltip2}) do
CreateBackdrop(tooltip, nil, nil, alpha)
CreateBackdropShadow(tooltip)
end
HookScript(WorldMapTooltip, "OnShow", function()
CreateBackdrop(WorldMapTooltip, nil, nil, alpha)
CreateBackdropShadow(WorldMapTooltip)
end)
SkinCloseButton(ItemRefCloseButton, ItemRefTooltip.backdrop, -6, -6)
+2
View File
@@ -4,6 +4,8 @@ pfUI:RegisterSkin("Trade", function ()
StripTextures(TradeFrame)
CreateBackdrop(TradeFrame, nil, nil, .75)
CreateBackdropShadow(TradeFrame)
TradeFrame.backdrop:SetPoint("TOPLEFT", 8, -20)
TradeFrame.backdrop:SetPoint("BOTTOMRIGHT", -16, 30)
TradeFrame:SetHitRectInsets(8,16,20,30)
+2
View File
@@ -5,6 +5,8 @@ pfUI:RegisterSkin("Trainer", function ()
HookAddonOrVariable("Blizzard_TrainerUI", function()
StripTextures(ClassTrainerFrame)
CreateBackdrop(ClassTrainerFrame, nil, nil, .75)
CreateBackdropShadow(ClassTrainerFrame)
ClassTrainerFrame.backdrop:SetPoint("TOPLEFT", 10, -10)
ClassTrainerFrame.backdrop:SetPoint("BOTTOMRIGHT", -32, 72)
ClassTrainerFrame:SetHitRectInsets(10,32,10,72)