This commit is contained in:
Bunny67
2020-09-14 10:12:22 +03:00
parent 6c3f9d925e
commit 0f4f16b6f0
71 changed files with 2302 additions and 2431 deletions
+18 -18
View File
@@ -24,7 +24,7 @@ local function createOptions(id, data)
width = WeakAuras.normalWidth,
name = L["Orientation"],
order = 25,
values = WeakAuras.orientation_types,
values = OptionsPrivate.Private.orientation_types,
set = function(info, v)
if(
(
@@ -58,7 +58,7 @@ local function createOptions(id, data)
data.orientation = v;
WeakAuras.Add(data);
WeakAuras.UpdateThumbnail(data);
WeakAuras.ResetMoverSizer();
OptionsPrivate.ResetMoverSizer();
end
},
inverse = {
@@ -71,7 +71,7 @@ local function createOptions(id, data)
type = "toggle",
width = WeakAuras.normalWidth,
name = L["Tooltip on Mouseover"],
hidden = function() return not WeakAuras.CanHaveTooltip(data) end,
hidden = function() return not OptionsPrivate.Private.CanHaveTooltip(data) end,
order = 38
},
bar_header = {
@@ -120,15 +120,15 @@ local function createOptions(id, data)
name = L["Auto"],
desc = L["Choose whether the displayed icon is automatic or defined manually"],
order = 40.3,
disabled = function() return not WeakAuras.CanHaveAuto(data); end,
get = function() return WeakAuras.CanHaveAuto(data) and data.auto end,
disabled = function() return not OptionsPrivate.Private.CanHaveAuto(data); end,
get = function() return OptionsPrivate.Private.CanHaveAuto(data) and data.auto end,
hidden = function() return not data.icon end,
},
displayIcon = {
type = "input",
width = WeakAuras.normalWidth,
name = L["Display Icon"],
hidden = function() return WeakAuras.CanHaveAuto(data) and data.auto or not data.icon; end,
hidden = function() return OptionsPrivate.Private.CanHaveAuto(data) and data.auto or not data.icon; end,
disabled = function() return not data.icon end,
order = 40.4,
get = function()
@@ -144,16 +144,16 @@ local function createOptions(id, data)
type = "execute",
width = WeakAuras.normalWidth,
name = L["Choose"],
hidden = function() return WeakAuras.CanHaveAuto(data) and data.auto or not data.icon; end,
hidden = function() return OptionsPrivate.Private.CanHaveAuto(data) and data.auto or not data.icon; end,
disabled = function() return not data.icon end,
order = 40.5,
func = function() WeakAuras.OpenIconPicker(data, "displayIcon"); end
func = function() OptionsPrivate.OpenIconPicker(data, "displayIcon"); end
},
icon_side = {
type = "select",
width = WeakAuras.normalWidth,
name = L["Icon Position"],
values = WeakAuras.icon_side_types,
values = OptionsPrivate.Private.icon_side_types,
hidden = function() return data.orientation:find("VERTICAL") or not data.icon end,
order = 40.6,
},
@@ -161,7 +161,7 @@ local function createOptions(id, data)
type = "select",
width = WeakAuras.normalWidth,
name = L["Icon Position"],
values = WeakAuras.rotated_icon_side_types,
values = OptionsPrivate.Private.rotated_icon_side_types,
hidden = function() return data.orientation:find("HORIZONTAL") or not data.icon end,
order = 40.7,
get = function()
@@ -241,7 +241,7 @@ local function createOptions(id, data)
width = WeakAuras.halfWidth,
order = 44.3,
func = function()
WeakAuras.OpenTexturePicker(data, data, "sparkTexture", WeakAuras.texture_types);
OptionsPrivate.OpenTexturePicker(data, data, "sparkTexture", OptionsPrivate.Private.texture_types);
end,
disabled = function() return not data.spark end,
hidden = function() return not data.spark end,
@@ -260,7 +260,7 @@ local function createOptions(id, data)
width = WeakAuras.normalWidth,
name = L["Blend Mode"],
order = 44.5,
values = WeakAuras.blend_types,
values = OptionsPrivate.Private.blend_types,
disabled = function() return not data.spark end,
hidden = function() return not data.spark end,
},
@@ -311,7 +311,7 @@ local function createOptions(id, data)
sparkRotationMode = {
type = "select",
width = WeakAuras.normalWidth,
values = WeakAuras.spark_rotation_types,
values = OptionsPrivate.Private.spark_rotation_types,
name = L["Rotation Mode"],
order = 45,
disabled = function() return not data.spark end,
@@ -339,7 +339,7 @@ local function createOptions(id, data)
sparkHidden = {
type = "select",
width = WeakAuras.normalWidth,
values = WeakAuras.spark_hide_types,
values = OptionsPrivate.Private.spark_hide_types,
name = L["Hide on"],
order = 45.3,
disabled = function() return not data.spark end,
@@ -354,7 +354,7 @@ local function createOptions(id, data)
options = WeakAuras.regionPrototype.AddAdjustedDurationOptions(options, data, 36.5);
local overlayInfo = WeakAuras.GetOverlayInfo(data);
local overlayInfo = OptionsPrivate.Private.GetOverlayInfo(data);
if (overlayInfo and next(overlayInfo)) then
options["overlayheader"] = {
type = "header",
@@ -397,7 +397,7 @@ local function createOptions(id, data)
return {
aurabar = options,
position = WeakAuras.commonOptions.PositionOptions(id, data),
position = OptionsPrivate.commonOptions.PositionOptions(id, data),
};
end
@@ -734,12 +734,12 @@ local function subCreateOptions(parentData, data, index, subIndex)
__title = L["Foreground"],
__order = 1,
__up = function()
if (WeakAuras.ApplyToDataOrChildData(parentData, WeakAuras.MoveSubRegionUp, index, "aurabar_bar")) then
if (OptionsPrivate.Private.ApplyToDataOrChildData(parentData, OptionsPrivate.MoveSubRegionUp, index, "aurabar_bar")) then
WeakAuras.ClearAndUpdateOptions(parentData.id)
end
end,
__down = function()
if (WeakAuras.ApplyToDataOrChildData(parentData, WeakAuras.MoveSubRegionDown, index, "aurabar_bar")) then
if (OptionsPrivate.Private.ApplyToDataOrChildData(parentData, OptionsPrivate.MoveSubRegionDown, index, "aurabar_bar")) then
WeakAuras.ClearAndUpdateOptions(parentData.id, parentData)
end
end,