diff --git a/modules/addonbuttons.lua b/modules/addonbuttons.lua index 0f70a913..2b84bb93 100644 --- a/modules/addonbuttons.lua +++ b/modules/addonbuttons.lua @@ -224,7 +224,7 @@ pfUI:RegisterModule("addonbuttons", function () frame.backup.is_clamped_to_screen = frame:IsClampedToScreen() frame.backup.is_movable = frame:IsMovable() frame.backup.point = {frame:GetPoint()} - frame.backup.size = {frame:GetHeight(), frame:GetWidth()} + frame.backup.size = {frame:GetSize()} frame.backup.scale = frame:GetScale() if frame:HasScript("OnDragStart") then frame.backup.on_drag_start = frame:GetScript("OnDragStart") diff --git a/modules/chatcopy.lua b/modules/chatcopy.lua index dc9ec1cc..dfa21925 100644 --- a/modules/chatcopy.lua +++ b/modules/chatcopy.lua @@ -96,8 +96,7 @@ pfUI:RegisterModule("chatcopy", function () scroll:Hide() local editbox = CreateFrame("EditBox", "pfChatCopyBox" .. i, scroll) - editbox:SetHeight(frame:GetHeight()) - editbox:SetWidth(frame:GetWidth()) + editbox:SetSize(frame:GetSize()) editbox:SetAllPoints(scroll) editbox:SetTextColor(1,1,1,1) editbox:SetFontObject(ChatFontNormal) diff --git a/modules/easteregg.lua b/modules/easteregg.lua index 10deefec..f605008d 100644 --- a/modules/easteregg.lua +++ b/modules/easteregg.lua @@ -123,8 +123,7 @@ pfUI:RegisterModule("easteregg", function () local f = GetExplosion() f:ClearAllPoints() f:SetPoint("CENTER", fireworks, "TOPLEFT", x, y) - f:SetWidth(25) - f:SetHeight(25) + f:SetSize(25, 25) f.tex:SetTexture(1,1,1,.5) f:SetAlpha(1) f:Show() @@ -134,8 +133,7 @@ pfUI:RegisterModule("easteregg", function () local f = GetExplosion() f:ClearAllPoints() f:SetPoint("CENTER", fireworks, "TOPLEFT", x+(math.random(0,100)-50), y+(math.random(0,100)-50)) - f:SetWidth(2) - f:SetHeight(2) + f:SetSize(2, 2) f.tex:SetTexture(math.random(),math.random(),math.random(),1) f:SetAlpha(1) f:Show() diff --git a/modules/farmmode.lua b/modules/farmmode.lua index 6a95e28a..e825ba2c 100644 --- a/modules/farmmode.lua +++ b/modules/farmmode.lua @@ -41,8 +41,9 @@ pfUI:RegisterModule("farmmode", function () pfUI.farmmap:RegisterForDrag("LeftButton") pfUI.farmmap:SetScript("OnMouseWheel", function() if IsControlKeyDown() then - this:SetWidth(this:GetWidth() + (arg1 > 0 and 10 or -10)) - this:SetHeight(this:GetHeight() + (arg1 > 0 and 10 or -10)) + local adjust = (arg1 > 0 and 10 or -10) + local width, height = this:GetSize() + this:SetSize(width + adjust, height + adjust) Minimap_ZoomIn() Minimap_ZoomOut() elseif IsShiftKeyDown() then diff --git a/skins/blizzard/game_menu.lua b/skins/blizzard/game_menu.lua index 1a8a05a0..4f1f6b79 100644 --- a/skins/blizzard/game_menu.lua +++ b/skins/blizzard/game_menu.lua @@ -3,8 +3,8 @@ pfUI:RegisterSkin("Game Menu", function () CreateBackdrop(GameMenuFrame, nil, true, .75) CreateBackdropShadow(GameMenuFrame) - GameMenuFrame:SetWidth(GameMenuFrame:GetWidth() - 30) - GameMenuFrame:SetHeight(GameMenuFrame:GetHeight() + 6) + local menuWidth, menuHeight = GameMenuFrame:GetSize() + GameMenuFrame:SetSize(menuWidth - 30, menuHeight + 6) local title = GetNoNameObject(GameMenuFrame, "FontString", "ARTWORK", MAIN_MENU) title:SetTextColor(1,1,1,1)