from retail
This commit is contained in:
@@ -1,11 +1,11 @@
|
||||
<Bindings>
|
||||
<Binding name="WEAKAURASTOGGLE" header="WEAKAURAS" Category="ADDONS">
|
||||
<Binding name="WEAKAURASTOGGLE" Category="BINDING_HEADER_WEAKAURAS">
|
||||
WeakAuras.OpenOptions()
|
||||
</Binding>
|
||||
<Binding name="WEAKAURASPROFILINGTOGGLE" Category="ADDONS">
|
||||
<Binding name="WEAKAURASPROFILINGTOGGLE" Category="BINDING_HEADER_WEAKAURAS">
|
||||
WeakAuras.RealTimeProfilingWindow:Toggle()
|
||||
</Binding>
|
||||
<Binding name="WEAKAURASPRINTPROFILING" Category="ADDONS">
|
||||
<Binding name="WEAKAURASPRINTPROFILING" Category="BINDING_HEADER_WEAKAURAS">
|
||||
WeakAuras.PrintProfile()
|
||||
</Binding>
|
||||
</Bindings>
|
||||
|
||||
@@ -2381,9 +2381,11 @@ do
|
||||
|
||||
if (showgcd) then
|
||||
if ((gcdStart or 0) + (gcdDuration or 0) > startTime + duration) then
|
||||
if startTime == 0 then
|
||||
gcdCooldown = true
|
||||
end
|
||||
startTime = gcdStart;
|
||||
duration = gcdDuration;
|
||||
gcdCooldown = true;
|
||||
end
|
||||
end
|
||||
|
||||
@@ -2403,9 +2405,11 @@ do
|
||||
end
|
||||
if (showgcd) then
|
||||
if ((gcdStart or 0) + (gcdDuration or 0) > startTime + duration) then
|
||||
if startTime == 0 then
|
||||
gcdCooldown = true
|
||||
end
|
||||
startTime = gcdStart;
|
||||
duration = gcdDuration;
|
||||
gcdCooldown = true;
|
||||
end
|
||||
end
|
||||
return startTime, duration, enabled, gcdCooldown;
|
||||
@@ -2437,9 +2441,11 @@ do
|
||||
|
||||
if (showgcd) then
|
||||
if ((gcdStart or 0) + (gcdDuration or 0) > startTime + duration) then
|
||||
if startTime == 0 then
|
||||
gcdCooldown = true
|
||||
end
|
||||
startTime = gcdStart;
|
||||
duration = gcdDuration;
|
||||
gcdCooldown = true;
|
||||
end
|
||||
end
|
||||
return startTime, duration, enabled, gcdCooldown;
|
||||
|
||||
@@ -1256,9 +1256,6 @@ function Private.Modernize(data)
|
||||
end
|
||||
end
|
||||
|
||||
if data.internalVersion < 67 or data.internalVersion > WeakAuras.InternalVersion() then
|
||||
local castMigrationNeeded = data.internalVersion < 67
|
||||
data.internalVersion = WeakAuras.InternalVersion()
|
||||
local function migrateToTable(tab, field)
|
||||
local value = tab[field]
|
||||
if value ~= nil and type(value) ~= "table" then
|
||||
@@ -1266,6 +1263,10 @@ function Private.Modernize(data)
|
||||
end
|
||||
end
|
||||
|
||||
if data.internalVersion < 67 or data.internalVersion > WeakAuras.InternalVersion() then
|
||||
local castMigrationNeeded = data.internalVersion < 67
|
||||
data.internalVersion = WeakAuras.InternalVersion()
|
||||
|
||||
do
|
||||
local trigger_migration = {
|
||||
["Cast"] = {
|
||||
|
||||
@@ -1040,6 +1040,17 @@ Private.load_prototype = {
|
||||
events = {"PARTY_MEMBERS_CHANGED", "RAID_ROSTER_UPDATE"},
|
||||
optional = true,
|
||||
},
|
||||
{
|
||||
name = "groupSize",
|
||||
display = L["Group Size"],
|
||||
type = "number",
|
||||
init = "arg",
|
||||
events = {"PARTY_MEMBERS_CHANGED", "RAID_ROSTER_UPDATE"},
|
||||
multiEntry = {
|
||||
operator = "and",
|
||||
limit = 2
|
||||
},
|
||||
},
|
||||
{
|
||||
name = "group_leader",
|
||||
display = WeakAuras.newFeatureString .. L["Group Leader/Assist"],
|
||||
@@ -3098,7 +3109,7 @@ Private.event_prototypes = {
|
||||
force_events = "SPELL_COOLDOWN_FORCE",
|
||||
name = L["Cooldown/Charges/Count"],
|
||||
loadFunc = function(trigger)
|
||||
trigger.spellName = trigger.spellName or 0;
|
||||
trigger.spellName = type(trigger.spellName) ~= "table" and trigger.spellName or 0;
|
||||
local spellName;
|
||||
if (trigger.use_exact_spellName) then
|
||||
spellName = trigger.spellName;
|
||||
@@ -3111,7 +3122,7 @@ Private.event_prototypes = {
|
||||
end
|
||||
end,
|
||||
init = function(trigger)
|
||||
trigger.spellName = trigger.spellName or 0;
|
||||
trigger.spellName = type(trigger.spellName) ~= "table" and trigger.spellName or 0;
|
||||
local spellName;
|
||||
if (trigger.use_exact_spellName) then
|
||||
spellName = trigger.spellName;
|
||||
|
||||
@@ -28,6 +28,7 @@ local default = {
|
||||
yOffset = 0,
|
||||
radius = 200,
|
||||
rotation = 0,
|
||||
stepAngle = 15,
|
||||
fullCircle = true,
|
||||
arcLength = 360,
|
||||
constantFactor = "RADIUS",
|
||||
@@ -719,6 +720,7 @@ local growers = {
|
||||
local constantFactor = data.constantFactor
|
||||
local space = data.space or 0
|
||||
local radius = data.radius or 0
|
||||
local stepAngle = (data.stepAngle or 0) * math.pi / 180
|
||||
local limit = data.useLimit and data.limit or math.huge
|
||||
local sAngle = (data.rotation or 0) * math.pi / 180
|
||||
local arc = (data.fullCircle and 360 or data.arcLength or 0) * math.pi / 180
|
||||
@@ -736,7 +738,7 @@ local growers = {
|
||||
for frame, regionDatas in pairs(frames) do
|
||||
local numVisible = min(limit, #regionDatas)
|
||||
local r
|
||||
if constantFactor == "RADIUS" then
|
||||
if constantFactor == "RADIUS" or constantFactor == "ANGLE" then
|
||||
r = radius
|
||||
else
|
||||
if numVisible <= 1 then
|
||||
@@ -749,6 +751,8 @@ local growers = {
|
||||
local dAngle
|
||||
if numVisible == 1 then
|
||||
dAngle = 0
|
||||
elseif constantFactor == "ANGLE" then
|
||||
dAngle = stepAngle
|
||||
elseif not data.fullCircle then
|
||||
dAngle = arc / (numVisible - 1)
|
||||
else
|
||||
@@ -770,6 +774,7 @@ local growers = {
|
||||
local constantFactor = data.constantFactor
|
||||
local space = data.space or 0
|
||||
local radius = data.radius or 0
|
||||
local stepAngle = (data.stepAngle or 0) * math.pi / 180
|
||||
local limit = data.useLimit and data.limit or math.huge
|
||||
local sAngle = (data.rotation or 0) * math.pi / 180
|
||||
local arc = (data.fullCircle and 360 or data.arcLength or 0) * math.pi / 180
|
||||
@@ -787,7 +792,7 @@ local growers = {
|
||||
for frame, regionDatas in pairs(frames) do
|
||||
local numVisible = min(limit, #regionDatas)
|
||||
local r
|
||||
if constantFactor == "RADIUS" then
|
||||
if constantFactor == "RADIUS" or constantFactor == "ANGLE" then
|
||||
r = radius
|
||||
else
|
||||
if numVisible <= 1 then
|
||||
@@ -800,6 +805,8 @@ local growers = {
|
||||
local dAngle
|
||||
if numVisible == 1 then
|
||||
dAngle = 0
|
||||
elseif constantFactor == "ANGLE" then
|
||||
dAngle = -stepAngle
|
||||
elseif not data.fullCircle then
|
||||
dAngle = arc / (1 - numVisible)
|
||||
else
|
||||
@@ -1374,7 +1381,19 @@ local function modify(parent, region, data)
|
||||
or data.anchorFrameType == "MOUSE")
|
||||
))
|
||||
then
|
||||
controlPoint:SetParent(frame == "" and self.relativeTo or frame)
|
||||
local parent
|
||||
if frame == "" then
|
||||
parent = self.relativeTo
|
||||
else
|
||||
if type(frame) == "string" then
|
||||
parent = _G[frame]
|
||||
else
|
||||
parent = frame
|
||||
end
|
||||
end
|
||||
if parent and parent.IsObjectType and parent:IsObjectType("Frame") then
|
||||
controlPoint:SetParent(parent)
|
||||
end
|
||||
else
|
||||
controlPoint:SetParent(self)
|
||||
end
|
||||
|
||||
@@ -81,6 +81,12 @@ local function modify(parent, region, data)
|
||||
local text = region.text;
|
||||
|
||||
local fontPath = SharedMedia:Fetch("font", data.font);
|
||||
if not text:GetFont() and fontPath then -- workaround font not loading correctly
|
||||
local objectName = "WeakAuras-Font-" .. data.font
|
||||
local fontObject = _G[objectName] or CreateFont(objectName)
|
||||
fontObject:SetFont(fontPath, data.fontSize < 33 and data.fontSize or 33, data.outline)
|
||||
text:SetFontObject(fontObject)
|
||||
end
|
||||
text:SetFont(fontPath, data.fontSize < 33 and data.fontSize or 33, data.outline);
|
||||
if not text:GetFont() then -- Font invalid, set the font but keep the setting
|
||||
text:SetFont(STANDARD_TEXT_FONT, data.fontSize <= 33 and data.fontSize or 33, data.outline);
|
||||
|
||||
@@ -139,6 +139,12 @@ local function modify(parent, region, parentData, data, first)
|
||||
|
||||
local fontPath = SharedMedia:Fetch("font", data.text_font);
|
||||
text:SetFont(fontPath, data.text_fontSize < 33 and data.text_fontSize or 33, data.text_fontType);
|
||||
if not text:GetFont() and fontPath then -- workaround font not loading correctly
|
||||
local objectName = "WeakAuras-Font-" .. data.text_font
|
||||
local fontObject = _G[objectName] or CreateFont(objectName)
|
||||
fontObject:SetFont(fontPath, data.text_fontSize < 33 and data.text_fontSize or 33, data.text_fontType)
|
||||
text:SetFontObject(fontObject)
|
||||
end
|
||||
if not text:GetFont() then -- Font invalid, set the font but keep the setting
|
||||
text:SetFont(STANDARD_TEXT_FONT, data.text_fontSize < 33 and data.text_fontSize or 33, data.text_fontType);
|
||||
end
|
||||
|
||||
@@ -32,6 +32,7 @@ if WeakAuras.isAwesomeEnabled() then
|
||||
end
|
||||
|
||||
Private.circular_group_constant_factor_types = {
|
||||
ANGLE = L["Angle and Radius"],
|
||||
RADIUS = L["Radius"],
|
||||
SPACING = L["Spacing"]
|
||||
}
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
local AddonName, Private = ...
|
||||
|
||||
local internalVersion = 68
|
||||
local internalVersion = 69
|
||||
|
||||
-- Lua APIs
|
||||
local insert = table.insert
|
||||
@@ -1404,6 +1404,7 @@ local function scanForLoadsImpl(toCheck, event, arg1, ...)
|
||||
|
||||
local size, difficulty, instanceType = GetInstanceTypeAndSize()
|
||||
local group = Private.ExecEnv.GroupType()
|
||||
local groupSize = GetNumGroupMembers()
|
||||
|
||||
local changed = 0;
|
||||
local shouldBeLoaded, couldBeLoaded;
|
||||
@@ -1416,8 +1417,8 @@ local function scanForLoadsImpl(toCheck, event, arg1, ...)
|
||||
if (data and not data.controlledChildren) then
|
||||
local loadFunc = loadFuncs[id];
|
||||
local loadOpt = loadFuncsForOptions[id];
|
||||
shouldBeLoaded = loadFunc and loadFunc("ScanForLoads_Auras", inCombat, alive, pvp, vehicle, vehicleUi, player, realm, class, race, faction, playerLevel, raidRole, group, raidMemberType, zone, zoneId, subzone, size, difficulty);
|
||||
couldBeLoaded = loadOpt and loadOpt("ScanForLoads_Auras", inCombat, alive, pvp, vehicle, vehicleUi, player, realm, class, race, faction, playerLevel, raidRole, group, raidMemberType, zone, zoneId, subzone, size, difficulty);
|
||||
shouldBeLoaded = loadFunc and loadFunc("ScanForLoads_Auras", inCombat, alive, pvp, vehicle, vehicleUi, player, realm, class, race, faction, playerLevel, raidRole, group, groupSize, raidMemberType, zone, zoneId, subzone, size, difficulty);
|
||||
couldBeLoaded = loadOpt and loadOpt("ScanForLoads_Auras", inCombat, alive, pvp, vehicle, vehicleUi, player, realm, class, race, faction, playerLevel, raidRole, group, groupSize, raidMemberType, zone, zoneId, subzone, size, difficulty);
|
||||
|
||||
if(shouldBeLoaded and not loaded[id]) then
|
||||
changed = changed + 1;
|
||||
|
||||
@@ -263,7 +263,7 @@ local function createOptions(id, data)
|
||||
name = L["Constant Factor"],
|
||||
order = 4,
|
||||
values = OptionsPrivate.Private.circular_group_constant_factor_types,
|
||||
hidden = function() return data.grow ~= "CIRCLE" and data.grow ~= "COUNTERCIRCLE" end
|
||||
hidden = function() return not(data.grow == "CIRCLE" or data.grow == "COUNTERCIRCLE") end
|
||||
},
|
||||
rotation = {
|
||||
type = "range",
|
||||
@@ -274,14 +274,31 @@ local function createOptions(id, data)
|
||||
min = 0,
|
||||
max = 360,
|
||||
bigStep = 3,
|
||||
hidden = function() return data.grow ~= "CIRCLE" and data.grow ~= "COUNTERCIRCLE" end
|
||||
hidden = function() return not(data.grow == "CIRCLE" or data.grow == "COUNTERCIRCLE") end
|
||||
},
|
||||
fullCircle = {
|
||||
type = "toggle",
|
||||
width = WeakAuras.normalWidth,
|
||||
name = L["Full Circle"],
|
||||
order = 7,
|
||||
hidden = function() return data.grow ~= "CIRCLE" and data.grow ~= "COUNTERCIRCLE" end
|
||||
hidden = function()
|
||||
return not(
|
||||
(data.grow == "CIRCLE" or data.grow == "COUNTERCIRCLE")
|
||||
and (data.constantFactor == "RADIUS" or data.constantFactor == "SPACING"))
|
||||
end
|
||||
},
|
||||
stepAngle = {
|
||||
type = "range",
|
||||
control = "WeakAurasSpinBox",
|
||||
width = WeakAuras.normalWidth,
|
||||
name = L["Angle Between Auras"],
|
||||
order = 12,
|
||||
min = 0,
|
||||
max = 180,
|
||||
bigStep = 1,
|
||||
hidden = function()
|
||||
return not((data.grow == "CIRCLE" or data.grow == "COUNTERCIRCLE") and data.constantFactor == "ANGLE")
|
||||
end
|
||||
},
|
||||
arcLength = {
|
||||
type = "range",
|
||||
@@ -293,7 +310,11 @@ local function createOptions(id, data)
|
||||
max = 360,
|
||||
bigStep = 3,
|
||||
disabled = function() return data.fullCircle end,
|
||||
hidden = function() return data.grow ~= "CIRCLE" and data.grow ~= "COUNTERCIRCLE" end
|
||||
hidden = function()
|
||||
return not(
|
||||
(data.grow == "CIRCLE" or data.grow == "COUNTERCIRCLE")
|
||||
and (data.constantFactor == "RADIUS" or data.constantFactor == "SPACING"))
|
||||
end
|
||||
},
|
||||
radius = {
|
||||
type = "range",
|
||||
@@ -304,7 +325,11 @@ local function createOptions(id, data)
|
||||
softMin = 0,
|
||||
softMax = 500,
|
||||
bigStep = 1,
|
||||
hidden = function() return data.grow == "CUSTOM" or not((data.grow == "CIRCLE" or data.grow == "COUNTERCIRCLE") and data.constantFactor == "RADIUS") end
|
||||
hidden = function()
|
||||
return not(
|
||||
(data.grow == "CIRCLE" or data.grow == "COUNTERCIRCLE")
|
||||
and (data.constantFactor == "RADIUS" or data.constantFactor == "ANGLE"))
|
||||
end
|
||||
},
|
||||
-- grid grow options
|
||||
gridType = {
|
||||
@@ -372,9 +397,12 @@ local function createOptions(id, data)
|
||||
softMax = 300,
|
||||
bigStep = 1,
|
||||
hidden = function()
|
||||
return data.grow == "CUSTOM"
|
||||
or data.grow == "GRID"
|
||||
or ((data.grow == "CIRCLE" or data.grow == "COUNTERCIRCLE") and data.constantFactor == "RADIUS")
|
||||
return not(
|
||||
data.grow == "LEFT" or data.grow == "RIGHT"
|
||||
or data.grow == "UP" or data.grow == "DOWN"
|
||||
or data.grow == "HORIZONTAL" or data.grow == "VERTICAL"
|
||||
or ((data.grow == "CIRCLE" or data.grow == "COUNTERCIRCLE")
|
||||
and (data.constantFactor == "SPACING")))
|
||||
end
|
||||
},
|
||||
stagger = {
|
||||
|
||||
Reference in New Issue
Block a user