Enhanced/ModelFrame: clean up unecessary character frame stuff

This commit is contained in:
andrew6180
2023-08-09 12:07:20 -07:00
parent 7d68f5c0f5
commit 9041d96344
2 changed files with 0 additions and 75 deletions
@@ -14,10 +14,7 @@ local Model_RotateRight = Model_RotateRight
local ROTATIONS_PER_SECOND = ROTATIONS_PER_SECOND
local modelFrames = {
"CharacterModelFrame",
"CompanionModelFrame",
"DressUpModel",
"PetModelFrame",
"PetStableModel"
}
@@ -403,8 +400,6 @@ function MF:ADDON_LOADED(event, addon)
end
function MF:Initialize()
if not E.private.enhanced.character.modelFrames then return end
for i = 1, #modelFrames do
local model = _G[modelFrames[i]]
@@ -417,15 +412,6 @@ function MF:Initialize()
self:ModelWithControls(model)
end
if E.myclass == "HUNTER" then
if E.private.enhanced.character.enable then
PetPaperDollPetInfo:Point("TOPLEFT", PetPaperDollFrame, 24, -81)
else
PetPaperDollPetInfo:Point("TOPLEFT", PetPaperDollFrame, 24, -76)
end
PetStablePetInfo:Point("TOPLEFT", PetStableModel, 5, -5)
end
local modelPanning = CreateFrame("Frame", "ModelPanningFrame", UIParent)
modelPanning:SetFrameStrata("DIALOG")
modelPanning:Hide()
@@ -156,14 +156,6 @@ local addonFixes = {
end)
end,
-- All Stats 1.1
-- https://www.curseforge.com/wow/addons/all-stats/files/430951
["AllStats"] = function()
if E.private.enhanced.character.modelFrames and not E.private.enhanced.character.enable then
CharacterModelFrame:Size(237, 324)
end
end,
-- https://github.com/ElvUI-WotLK/ElvUI_Enhanced/issues/100
["OmniBar"] = function()
hooksecurefunc("OmniBar_CreateIcon", function(self)
@@ -174,59 +166,6 @@ local addonFixes = {
E:RegisterCooldown(icon.cooldown)
end
end,
-- BlizzMove r18
-- https://www.curseforge.com/wow/addons/blizzmove/files/456128
-- https://github.com/ElvUI-WotLK/ElvUI_Enhanced/issues/96
["BlizzMove"] = function()
if E.private.enhanced.character.enable then
local MouseIsOver = MouseIsOver
local origOnMouseWheel
local function onMouseWheel(self, delta)
if CharacterStatsPane:IsShown() and MouseIsOver(CharacterStatsPane) then
CharacterStatsPane:GetScript("OnMouseWheel")(CharacterStatsPane, delta)
elseif PaperDollTitlesPane:IsShown() and MouseIsOver(PaperDollTitlesPane) then
PaperDollTitlesPane:GetScript("OnMouseWheel")(PaperDollTitlesPane, delta)
elseif PaperDollEquipmentManagerPane:IsShown() and MouseIsOver(PaperDollEquipmentManagerPane) then
PaperDollEquipmentManagerPane:GetScript("OnMouseWheel")(PaperDollEquipmentManagerPane, delta)
else
origOnMouseWheel(self, delta)
end
end
local f = CreateFrame("Frame")
f:RegisterEvent("PLAYER_ENTERING_WORLD")
f:SetScript("OnEvent", function(self)
self:UnregisterEvent("PLAYER_ENTERING_WORLD")
origOnMouseWheel = PaperDollFrame:GetScript("OnMouseWheel")
if PaperDollFrame.frameToMove and PaperDollFrame.frameToMove.EnableMouse then
PaperDollFrame:SetScript("OnMouseWheel", onMouseWheel)
end
hooksecurefunc(BlizzMove, "Toggle", function(self, handler)
if handler == PaperDollFrame then
if not handler:GetScript("OnDragStart") then
PaperDollFrame:SetScript("OnMouseWheel", nil)
else
PaperDollFrame:SetScript("OnMouseWheel", onMouseWheel)
end
end
end)
end)
end
end,
-- InspectEquip 1.7.7
["InspectEquip"] = function()
if E.private.enhanced.character.enable then
PaperDollFrame:HookScript("OnShow", InspectEquip.PaperDollFrame_OnShow)
PaperDollFrame:HookScript("OnHide", InspectEquip.PaperDollFrame_OnHide)
end
end,
}
function AC:AddAddon(addon, func)