from retail

This commit is contained in:
NoM0Re
2025-01-10 16:16:47 +01:00
parent b89c221c34
commit a747346a9d
15 changed files with 240 additions and 42 deletions
@@ -5,7 +5,7 @@ local tinsert, tremove, wipe = table.insert, table.remove, wipe
local select, pairs, type, unpack = select, pairs, type, unpack
local error = error
local Type, Version = "WeakAurasDisplayButton", 59
local Type, Version = "WeakAurasDisplayButton", 60
local AceGUI = LibStub and LibStub("AceGUI-3.0", true)
if not AceGUI or (AceGUI:GetWidgetVersion(Type) or 0) >= Version then return end
+9 -4
View File
@@ -143,7 +143,9 @@ local function addCollapsibleHeader(options, key, input, order, isGroupTab)
if notcollapsable then
return "Interface\\AddOns\\WeakAuras\\Media\\Textures\\bullet1", 18, 18
else
return isCollapsed() and "Interface\\AddOns\\WeakAuras\\Media\\Textures\\expand" or "Interface\\AddOns\\WeakAuras\\Media\\Textures\\collapse", 18, 18
return isCollapsed() and "Interface\\AddOns\\WeakAuras\\Media\\Textures\\expand"
or "Interface\\AddOns\\WeakAuras\\Media\\Textures\\collapse",
18, 18
end
end,
control = "WeakAurasExpand",
@@ -1248,8 +1250,10 @@ local function PositionOptions(id, data, _, hideWidthHeight, disableSelfPoint, g
},
};
OptionsPrivate.commonOptions.AddCodeOption(positionOptions, data, L["Custom Anchor"], "custom_anchor", "https://github.com/WeakAuras/WeakAuras2/wiki/Custom-Code-Blocks#custom-anchor-function",
71.5, function() return not(data.anchorFrameType == "CUSTOM" and not IsParentDynamicGroup()) end, {"customAnchor"}, false, { setOnParent = group })
OptionsPrivate.commonOptions.AddCodeOption(positionOptions, data, L["Custom Anchor"], "custom_anchor",
"https://github.com/WeakAuras/WeakAuras2/wiki/Custom-Code-Blocks#custom-anchor-function",
71.5, function() return not(data.anchorFrameType == "CUSTOM" and not IsParentDynamicGroup()) end,
{"customAnchor"}, false, { setOnParent = group })
return positionOptions;
end
@@ -1380,7 +1384,8 @@ local function AddCodeOption(args, data, name, prefix, url, order, hiddenFunc, p
tinsert(options.extraFunctions, 1, {
buttonLabel = L["Expand"],
func = function()
OptionsPrivate.OpenTextEditor(OptionsPrivate.GetPickedDisplay(), path, encloseInFunction, options.multipath, options.reloadOptions, options.setOnParent, url, options.validator)
OptionsPrivate.OpenTextEditor(OptionsPrivate.GetPickedDisplay(), path, encloseInFunction, options.multipath,
options.reloadOptions, options.setOnParent, url, options.validator)
end
});
@@ -206,6 +206,20 @@ local function createOptions(id, data)
OptionsPrivate.ResetMoverSizer()
end,
},
centerType = {
type = "select",
width = WeakAuras.normalWidth,
name = L["Aura Order"],
order = 3,
values = function()
if data.grow == "HORIZONTAL" then
return OptionsPrivate.Private.centered_types_h
else
return OptionsPrivate.Private.centered_types_v
end
end,
hidden = function() return data.grow ~= "HORIZONTAL" and data.grow ~= "VERTICAL" end,
},
-- circle grow options
constantFactor = {
type = "select",
+2 -1
View File
@@ -704,4 +704,5 @@ local function createIcon()
end
-- Register new region type options with WeakAuras
WeakAuras.RegisterRegionOptions("group", createOptions, createIcon, L["Group"], createThumbnail, modifyThumbnail, L["Controls the positioning and configuration of multiple displays at the same time"]);
WeakAuras.RegisterRegionOptions("group", createOptions, createIcon, L["Group"], createThumbnail, modifyThumbnail,
L["Controls the positioning and configuration of multiple displays at the same time"])
+52 -2
View File
@@ -94,6 +94,12 @@ local function createOptions(id, data)
line = L["%s Keep Aspect Ratio"]:format(line)
changed = true
end
if data.texXOffset and data.texXOffset ~= 0 then
line = L["%s X offset by %d"]:format(line, data.texXOffset)
end
if data.texYOffset and data.texYOffset ~= 0 then
line = L["%s Y offset by %d"]:format(line, data.texYOffset)
end
if not changed then
line = L["%s Default Alpha, Zoom, Icon Inset, Aspect Ratio"]:format(line)
end
@@ -153,12 +159,41 @@ local function createOptions(id, data)
order = 7.05,
hidden = hiddenIconExtra,
},
texXOffset = {
type = "range",
control = "WeakAurasSpinBox",
width = WeakAuras.normalWidth - indentWidth,
name = L["Texture X Offset"],
order = 7.06,
min = -1,
max = 1,
bigStep = 0.1,
hidden = hiddenIconExtra,
},
texYOffset = {
type = "range",
control = "WeakAurasSpinBox",
width = WeakAuras.normalWidth,
name = L["Texture Y Offset"],
order = 7.07,
min = -1,
max = 1,
bigStep = 0.1,
hidden = hiddenIconExtra,
},
iconExtra_space3 = {
type = "description",
name = "",
width = indentWidth,
order = 7.08,
hidden = hiddenIconExtra,
},
iconInset = {
type = "range",
control = "WeakAurasSpinBox",
width = WeakAuras.normalWidth - indentWidth,
name = L["Icon Inset"],
order = 7.06,
order = 7.09,
min = 0,
max = 1,
bigStep = 0.01,
@@ -171,7 +206,7 @@ local function createOptions(id, data)
type = "toggle",
width = WeakAuras.normalWidth,
name = L["Keep Aspect Ratio"],
order = 7.07,
order = 7.10,
hidden = hiddenIconExtra,
},
iconExtraAnchor = {
@@ -222,6 +257,21 @@ local function createOptions(id, data)
order = 100,
name = "",
},
ccWarning = {
type = "description",
width = WeakAuras.doubleWidth,
name = function()
if OmniCC then
return L["The addon OmniCC is enabled. It might add cooldown numbers to the swipe. You can configure these in the OmniCC settings"]
elseif ElvUI then
return L["The addon ElvUI is enabled. It might add cooldown numbers to the swipe. You can configure these in the ElvUI settings"]
else
return L["Cooldown Numbers might be added by WoW. You can configure these in the game settings."]
end
end,
order = 11.7,
hidden = function() return data.cooldownTextDisabled end
},
};
return {
+2 -1
View File
@@ -297,4 +297,5 @@ local templates = {
},
}
WeakAuras.RegisterRegionOptions("model", createOptions, createIcon, L["Model"], createThumbnail, modifyThumbnail, L["Shows a 3D model from the game files"], templates);
WeakAuras.RegisterRegionOptions("model", createOptions, createIcon, L["Model"], createThumbnail, modifyThumbnail,
L["Shows a 3D model from the game files"], templates)