diff --git a/WeakAuras/Prototypes.lua b/WeakAuras/Prototypes.lua index 55bf1fa8ce..3d13f1f6bf 100644 --- a/WeakAuras/Prototypes.lua +++ b/WeakAuras/Prototypes.lua @@ -1615,7 +1615,7 @@ Private.load_prototype = { name = "namerealm", display = L["Player Name/Realm"], type = "string", - multilineWhenEnable = true, + multiline = true, test = "nameRealmChecker:Check(player, realm)", preamble = "local nameRealmChecker = Private.ExecEnv.ParseNameCheck(%q)", desc = constants.nameRealmFilterDesc, @@ -1624,7 +1624,7 @@ Private.load_prototype = { name = "ignoreNameRealm", display = L["|cFFFF0000Not|r Player Name/Realm"], type = "string", - multilineWhenEnable = true, + multiline = true, test = "not nameRealmIgnoreChecker:Check(player, realm)", preamble = "local nameRealmIgnoreChecker = Private.ExecEnv.ParseNameCheck(%q)", desc = constants.nameRealmFilterDesc, @@ -1726,7 +1726,7 @@ Private.load_prototype = { name = "zone", display = L["Zone Name"], type = "string", - multilineWhenEnable = true, + multiline = true, init = "arg", preamble = "local checker = Private.ExecEnv.ParseStringCheck(%q)", test = "checker:Check(zone)", @@ -1749,7 +1749,7 @@ Private.load_prototype = { name = "zoneIds", display = L["Zone ID(s)"], type = "string", - multilineWhenEnable = true, + multiline = true, enable = not WeakAuras.IsClassicEra(), hidden = WeakAuras.IsClassicEra(), events = {"ZONE_CHANGED", "ZONE_CHANGED_INDOORS", "ZONE_CHANGED_NEW_AREA", "VEHICLE_UPDATE"}, @@ -1762,7 +1762,7 @@ Private.load_prototype = { display = L["Encounter ID(s)"], type = "string", init = "arg", - multilineWhenEnable = true, + multiline = true, desc = Private.get_encounters_list, test = "WeakAuras.CheckNumericIds(%q, encounterid)", events = {"ENCOUNTER_START", "ENCOUNTER_END"}, @@ -2111,7 +2111,7 @@ Private.event_prototypes = { display = L["Unit Name/Realm"], desc = constants.nameRealmFilterDesc, type = "string", - multilineWhenEnable = true, + multiline = true, preamble = "local nameRealmChecker = Private.ExecEnv.ParseNameCheck(%q)", test = "nameRealmChecker:Check(name, realm)", conditionType = "string", @@ -2259,7 +2259,7 @@ Private.event_prototypes = { name = "npcId", display = L["Npc ID"], type = "string", - multilineWhenEnable = true, + multiline = true, store = true, init = "select(6, strsplit('-', UnitGUID(unit) or ''))", conditionType = "string", @@ -2875,7 +2875,7 @@ Private.event_prototypes = { name = "namerealm", display = L["Unit Name/Realm"], type = "string", - multilineWhenEnable = true, + multiline = true, preamble = "local nameRealmChecker = Private.ExecEnv.ParseNameCheck(%q)", test = "nameRealmChecker:Check(name, realm)", conditionType = "string", @@ -2892,7 +2892,7 @@ Private.event_prototypes = { name = "npcId", display = L["Npc ID"], type = "string", - multilineWhenEnable = true, + multiline = true, store = true, init = "select(6, strsplit('-', UnitGUID(unit) or ''))", conditionType = "string", @@ -3420,7 +3420,7 @@ Private.event_prototypes = { name = "namerealm", display = L["Unit Name/Realm"], type = "string", - multilineWhenEnable = true, + multiline = true, preamble = "local nameRealmChecker = Private.ExecEnv.ParseNameCheck(%q)", test = "nameRealmChecker:Check(name, realm)", conditionType = "string", @@ -3437,7 +3437,7 @@ Private.event_prototypes = { name = "npcId", display = L["Npc ID"], type = "string", - multilineWhenEnable = true, + multiline = true, store = true, init = "select(6, strsplit('-', UnitGUID(unit) or ''))", conditionType = "string", @@ -3737,7 +3737,7 @@ Private.event_prototypes = { name = "namerealm", display = L["Unit Name/Realm"], type = "string", - multilineWhenEnable = true, + multiline = true, preamble = "local nameRealmChecker = Private.ExecEnv.ParseNameCheck(%q)", test = "nameRealmChecker:Check(unitname, unitrealm)", conditionType = "string", @@ -3913,7 +3913,7 @@ Private.event_prototypes = { name = "sourceName", display = L["Source Name"], type = "string", - multilineWhenEnable = true, + multiline = true, init = "arg", store = true, conditionType = "string", @@ -3925,7 +3925,7 @@ Private.event_prototypes = { name = "sourceNpcId", display = L["Source NPC Id"], type = "string", - multilineWhenEnable = true, + multiline = true, init = "select(6, strsplit('-', sourceGUID or ''))", store = true, conditionType = "string", @@ -4034,7 +4034,7 @@ Private.event_prototypes = { name = "destName", display = L["Destination Name"], type = "string", - multilineWhenEnable = true, + multiline = true, init = "arg", store = true, conditionType = "string", @@ -4049,7 +4049,7 @@ Private.event_prototypes = { name = "destNpcId", display = L["Destination NPC Id"], type = "string", - multilineWhenEnable = true, + multiline = true, init = "select(6, strsplit('-', destGUID or ''))", store = true, conditionType = "string", @@ -8458,7 +8458,7 @@ Private.event_prototypes = { name = "npcId", display = L["Npc ID"], type = "string", - multilineWhenEnable = true, + multiline = true, store = true, init = "select(6, strsplit('-', UnitGUID(unit) or ''))", conditionType = "string", @@ -8601,7 +8601,7 @@ Private.event_prototypes = { name = "sourceNameRealm", display = L["Source Unit Name/Realm"], type = "string", - multilineWhenEnable = true, + multiline = true, preamble = "local sourceNameRealmChecker = Private.ExecEnv.ParseNameCheck(%q)", test = "sourceNameRealmChecker:Check(sourceName, sourceRealm)", conditionType = "string", @@ -8650,7 +8650,7 @@ Private.event_prototypes = { name = "destNameRealm", display = L["Name/Realm of Caster's Target"], type = "string", - multilineWhenEnable = true, + multiline = true, preamble = "local destNameRealmChecker = Private.ExecEnv.ParseNameCheck(%q)", test = "destNameRealmChecker:Check(destName, destRealm)", conditionType = "string", diff --git a/WeakAurasOptions/LoadOptions.lua b/WeakAurasOptions/LoadOptions.lua index 499f28dd71..80b3568627 100644 --- a/WeakAurasOptions/LoadOptions.lua +++ b/WeakAurasOptions/LoadOptions.lua @@ -476,7 +476,7 @@ function OptionsPrivate.ConstructOptions(prototype, data, startorder, triggernum order = order + 1; end elseif(arg.type == "string" or arg.type == "tristatestring") then - if not arg.multilineWhenEnable and entryNumber > 1 then + if not arg.multiline and entryNumber > 1 then options["spacer_"..name..suffix].width = WeakAuras.normalWidth end @@ -499,14 +499,14 @@ function OptionsPrivate.ConstructOptions(prototype, data, startorder, triggernum else options[name..suffix] = { type = "input", - width = arg.multilineWhenEnable and WeakAuras.doubleWidth or WeakAuras.normalWidth, + width = arg.multiline and WeakAuras.doubleWidth or WeakAuras.normalWidth, name = arg.display, order = order, hidden = hidden, validate = validate, desc = arg.desc, - multiline = arg.multilineWhenEnable, - control = arg.multilineWhenEnable and "WeakAuras-MultiLineEditBoxWithEnter" or nil, + multiline = arg.multiline, + control = arg.multiline and "WeakAuras-MultiLineEditBoxWithEnter" or nil, get = function() return getValue(trigger, "use_"..realname, realname, multiEntry, entryNumber, arg.type == "tristatestring") end,