diff --git a/ElvUI_LocPlus/CHANGELOG.txt b/ElvUI_LocPlus/CHANGELOG.txt index e2d98a5..26a36ef 100644 --- a/ElvUI_LocPlus/CHANGELOG.txt +++ b/ElvUI_LocPlus/CHANGELOG.txt @@ -1,3 +1,6 @@ +[b]2.75[/b] (Feb 9, 2023) +*Fixed the Datatexts error after ElvUI v13.25. Credit: Azilroka + [b]2.74[/b] (Jan 29, 2023) *LibTourist update *Added Storm Sigil currency diff --git a/ElvUI_LocPlus/ElvUI_LocPlus.toc b/ElvUI_LocPlus/ElvUI_LocPlus.toc index 4a8ba72..5be3eaa 100644 --- a/ElvUI_LocPlus/ElvUI_LocPlus.toc +++ b/ElvUI_LocPlus/ElvUI_LocPlus.toc @@ -1,6 +1,6 @@ ## Interface: 100005 ## Author: Benik -## Version: 2.74 +## Version: 2.75 ## Title: |cff1784d1ElvUI|r Location Plus ## Notes: a plugin for ElvUI 13+, that adds location, coords, 2 Datatexts and a tooltip full of info. ## RequiredDeps: ElvUI diff --git a/ElvUI_LocPlus/ElvUI_LocPlus_Classic.toc b/ElvUI_LocPlus/ElvUI_LocPlus_Classic.toc index 1a0edf4..bc4bee5 100644 --- a/ElvUI_LocPlus/ElvUI_LocPlus_Classic.toc +++ b/ElvUI_LocPlus/ElvUI_LocPlus_Classic.toc @@ -1,6 +1,6 @@ ## Interface: 11403 ## Author: Benik -## Version: 2.74 +## Version: 2.75 ## Title: |cff1784d1ElvUI|r Location Plus |cfd9b9b9bClassic|r ## Notes: a plugin for ElvUI 13+, that adds location, coords, 2 Datatexts and a tooltip full of info. ## RequiredDeps: ElvUI diff --git a/ElvUI_LocPlus/ElvUI_LocPlus_Wrath.toc b/ElvUI_LocPlus/ElvUI_LocPlus_Wrath.toc index ab84bad..d1b6923 100644 --- a/ElvUI_LocPlus/ElvUI_LocPlus_Wrath.toc +++ b/ElvUI_LocPlus/ElvUI_LocPlus_Wrath.toc @@ -1,6 +1,6 @@ ## Interface: 30401 ## Author: Benik -## Version: 2.74 +## Version: 2.75 ## Title: |cff1784d1ElvUI|r Location Plus |cfd9b9b9bWrath|r ## Notes: a plugin for ElvUI 13+, that adds location, coords, 2 Datatexts and a tooltip full of info. ## RequiredDeps: ElvUI diff --git a/ElvUI_LocPlus/core.lua b/ElvUI_LocPlus/core.lua index 3756c76..076ef31 100644 --- a/ElvUI_LocPlus/core.lua +++ b/ElvUI_LocPlus/core.lua @@ -490,7 +490,6 @@ local function CreateDatatextPanels() left_dtp:SetParent(LocationPlusPanel) DT:RegisterPanel(LocPlusLeftDT, 1, 'ANCHOR_BOTTOM', 0, -4) - DT:UpdatePanelInfo('LocPlusLeftDT') -- Right coords Datatext panel local right_dtp = CreateFrame('Frame', 'LocPlusRightDT', E.UIParent, 'BackdropTemplate') @@ -500,7 +499,6 @@ local function CreateDatatextPanels() right_dtp:SetParent(LocationPlusPanel) DT:RegisterPanel(LocPlusRightDT, 1, 'ANCHOR_BOTTOM', 0, -4) - DT:UpdatePanelInfo('LocPlusRightDT') end -- Update changes @@ -536,17 +534,22 @@ function LP:AddOptions() end local function InjectDatatextOptions() - E.Options.args.datatexts.args.panels.args.LocPlusLeftDT.name = L['LocationPlus Left Panel'] - E.Options.args.datatexts.args.panels.args.LocPlusLeftDT.order = 1101 + local options = E.Options.args.datatexts.args.panels.args + + options.LocPlusLeftDT.name = L['LocationPlus Left Panel'] + options.LocPlusLeftDT.order = 1101 - E.Options.args.datatexts.args.panels.args.LocPlusRightDT.name = L['LocationPlus Right Panel'] - E.Options.args.datatexts.args.panels.args.LocPlusRightDT.order = 1102 + options.LocPlusRightDT.name = L['LocationPlus Right Panel'] + options.LocPlusRightDT.order = 1102 end function LP:PLAYER_ENTERING_WORLD(...) self:ChangeFont() self:UpdateCoords() self:HideCoords() +end + +function LP:LoadDataTexts(...) DT:UpdatePanelInfo('LocPlusRightDT') DT:UpdatePanelInfo('LocPlusLeftDT') end @@ -555,14 +558,15 @@ function LP:Initialize() CreateLocationPanel() CreateDatatextPanels() CreateCoordPanels() - self:Update() - self:TimerUpdate() - self:ToggleBlizZoneText() - self:ScheduleRepeatingTimer('UpdateLocation', 0.5) - self:RegisterEvent('PLAYER_ENTERING_WORLD') + LP:Update() + LP:TimerUpdate() + LP:ToggleBlizZoneText() + LP:ScheduleRepeatingTimer('UpdateLocation', 0.5) + LP:RegisterEvent('PLAYER_ENTERING_WORLD') hooksecurefunc(DT, 'UpdatePanelInfo', LP.Update) hooksecurefunc(DT, 'UpdatePanelAttributes', LP.Update) hooksecurefunc(DT, 'UpdatePanelAttributes', LP.ChangeFont) + hooksecurefunc(DT, 'LoadDataTexts', LP.LoadDataTexts) EP:RegisterPlugin(addon, LP.AddOptions) tinsert(LP.Config, InjectDatatextOptions) @@ -576,4 +580,4 @@ local function InitializeCallback() LP:Initialize() end -E:RegisterModule(LP:GetName(), InitializeCallback) +E:RegisterModule(LP:GetName(), InitializeCallback) \ No newline at end of file