from retail

This commit is contained in:
NoM0Re
2025-01-16 02:47:58 +01:00
parent ccb4d4af95
commit 24196cd7ce
11 changed files with 164 additions and 52 deletions
@@ -5,7 +5,7 @@ local L = WeakAuras.L
local pairs, next, type, unpack = pairs, next, type, unpack
local Type, Version = "WeakAurasPendingUpdateButton", 3
local Type, Version = "WeakAurasPendingUpdateButton", 5
local AceGUI = LibStub and LibStub("AceGUI-3.0", true)
if not AceGUI or (AceGUI:GetWidgetVersion(Type) or 0) >= Version then
@@ -100,7 +100,7 @@ local methods = {
local auraData = WeakAuras.GetData(auraId)
if auraData then
local success, error = WeakAuras.Import(self.companionData.encoded, auraData)
if not success then
if not success and error ~= nil then
WeakAuras.prettyPrint(error)
end
end
+1 -1
View File
@@ -587,7 +587,7 @@ local function GetBuffTriggerOptions(data, triggernum)
fetchTooltip = {
type = "toggle",
name = L["Fetch Tooltip Information"],
desc = L["This adds %tooltip, %tooltip1, %tooltip2, %tooltip3 as text replacements and also allows filtering based on the tooltip content/values."],
desc = L["This adds %tooltip, %tooltip1, %tooltip2, %tooltip3 and %tooltip4 as text replacements and also allows filtering based on the tooltip content/values."],
order = 64.5,
width = WeakAuras.doubleWidth,
hidden = function() return not (trigger.type == "aura2" and trigger.unit ~= "multi" and not IsSingleMissing(trigger)) end
+29
View File
@@ -91,6 +91,35 @@ function OptionsPrivate.GetInformationOptions(data)
}
order = order + 1
end
if OptionsPrivate.HasWagoUrl(data.id) then
args.ignoreWagoUpdate = {
type = "toggle",
name = L["Ignore Wago updates"],
desc = OptionsPrivate.IsWagoUpdateIgnored(data.id) and L["Do you want to enable updates for this aura"] or L["Do you want to ignore updates for this aura"],
width = WeakAuras.doubleWidth,
get = function() return OptionsPrivate.IsWagoUpdateIgnored(data.id) end,
set = function(info, v)
local auraData = WeakAuras.GetData(data.id)
if auraData then
local ignoreUpdate
if OptionsPrivate.IsWagoUpdateIgnored(data.id) then
ignoreUpdate = nil
else
ignoreUpdate = true
end
for child in OptionsPrivate.Private.TraverseAll(auraData) do
child.ignoreWagoUpdate = ignoreUpdate
OptionsPrivate.ClearOptions(child.id)
end
WeakAuras.ClearAndUpdateOptions(data.id)
end
OptionsPrivate.SortDisplayButtons(nil, true)
end,
order = order
}
order = order + 1
end
-- Description
@@ -765,6 +765,7 @@ local function ConstructTextEditor(frame)
editor.editBox:SetScript("OnTextChanged", self.oldOnTextChanged)
editor:ClearFocus()
frame.window = "default"
frame:UpdateFrameVisible()
WeakAuras.FillOptions()
+20 -16
View File
@@ -479,25 +479,29 @@ StaticPopupDialogs["WEAKAURAS_CONFIRM_DELETE"] = {
preferredindex = STATICPOPUP_NUMDIALOGS,
}
StaticPopupDialogs["WEAKAURAS_CONFIRM_IGNORE_UPDATES"] = {
text = L["Do you want to ignore all future updates for this aura"],
button1 = L["Yes"],
button2 = L["Cancel"],
OnAccept = function(self)
if self.data then
local auraData = WeakAuras.GetData(self.data)
if auraData then
for child in OptionsPrivate.Private.TraverseAll(auraData) do
child.ignoreWagoUpdate = true
function OptionsPrivate.IsWagoUpdateIgnored(auraId)
local auraData = WeakAuras.GetData(auraId)
if auraData then
for child in OptionsPrivate.Private.TraverseAll(auraData) do
if child.ignoreWagoUpdate then
return true
end
end
OptionsPrivate.SortDisplayButtons(nil, true)
end
end,
OnCancel = function(self) end,
whileDead = true,
preferredindex = STATICPOPUP_NUMDIALOGS,
}
return false
end
function OptionsPrivate.HasWagoUrl(auraId)
local auraData = WeakAuras.GetData(auraId)
if auraData then
for child in OptionsPrivate.Private.TraverseAll(auraData) do
if child.url and child.url ~= "" then
return true
end
end
end
return false
end
function OptionsPrivate.ConfirmDelete(toDelete, parents)
if toDelete then