Unwanted mass rename of tinsert to table.insert
This commit is contained in:
@@ -143,7 +143,7 @@ function Details:CreateAPI2Frame()
|
||||
end
|
||||
|
||||
for apiIndex, apiDesc in ipairs(api) do
|
||||
tinsert(apiFunctionNames, apiDesc.name)
|
||||
table.insert(apiFunctionNames, apiDesc.name)
|
||||
end
|
||||
|
||||
local api2ScrollMenu = DetailsFramework:CreateScrollBox (Api2Frame, "$parentApi2MenuScroll", apiMenuScrollRefresh, apiFunctionNames, scrollWidth, scrollHeight, lineAmount, lineHeight)
|
||||
@@ -286,7 +286,7 @@ function Details:CreateAPI2Frame()
|
||||
f.required:SetPoint("left", f, "left", space2, 0)
|
||||
f.default:SetPoint("left", f, "left", space3, 0)
|
||||
|
||||
tinsert(parametersLines, f)
|
||||
table.insert(parametersLines, f)
|
||||
end
|
||||
|
||||
--return value box
|
||||
@@ -339,7 +339,7 @@ function Details:CreateAPI2Frame()
|
||||
|
||||
f.desc:SetPoint("topleft", f.name, "bottomleft", 0, -5)
|
||||
|
||||
tinsert(returnLines, f)
|
||||
table.insert(returnLines, f)
|
||||
end
|
||||
|
||||
function Api2Frame.Refresh()
|
||||
|
||||
@@ -93,7 +93,7 @@ function Details:OpenBookmarkConfig()
|
||||
local label = DF:CreateLabel(set, "")
|
||||
label:SetPoint("left", icon, "right", 2, 0)
|
||||
|
||||
tinsert(panel.blocks, {icon = icon, label = label, bg = set.bg, button = set})
|
||||
table.insert(panel.blocks, {icon = icon, label = label, bg = set.bg, button = set})
|
||||
end
|
||||
|
||||
local normal_coords = {0, 1, 0, 1}
|
||||
|
||||
@@ -62,7 +62,7 @@ function Details222.CooldownTracking.GetOrCreateNewCooldownLine(cooldownFrame, l
|
||||
return cooldownLine
|
||||
else
|
||||
cooldownLine = DF:CreateTimeBar(cooldownFrame, [[Interface\AddOns\Details\images\bar_serenity]], Details.ocd_tracker.width-2, Details.ocd_tracker.height-2, 100, nil, cooldownFrame:GetName() .. "CDFrame" .. lineId)
|
||||
tinsert(cooldownFrame.bars, cooldownLine)
|
||||
table.insert(cooldownFrame.bars, cooldownLine)
|
||||
cooldownLine:EnableMouse(false)
|
||||
return cooldownLine
|
||||
end
|
||||
@@ -295,7 +295,7 @@ end
|
||||
Details222.CooldownTracking.SetupCooldownLine(cooldownLine)
|
||||
|
||||
--add the cooldown into the organized by class table
|
||||
tinsert(cooldownsOrganized[classId], cooldownLine)
|
||||
table.insert(cooldownsOrganized[classId], cooldownLine)
|
||||
|
||||
--iterate to the next cooldown line
|
||||
cooldownFrame.nextLineId = cooldownFrame.nextLineId + 1
|
||||
|
||||
@@ -121,7 +121,7 @@ function Details:OpenClassColorsConfig()
|
||||
--all colors
|
||||
local allColors = {}
|
||||
for colorName, colorTable in pairs(DF:GetDefaultColorList()) do
|
||||
tinsert(allColors, {colorTable, colorName, hex(colorTable[1]*255) .. hex(colorTable[2]*255) .. hex(colorTable[3]*255)})
|
||||
table.insert(allColors, {colorTable, colorName, hex(colorTable[1]*255) .. hex(colorTable[2]*255) .. hex(colorTable[3]*255)})
|
||||
end
|
||||
table.sort(allColors, sort_color)
|
||||
|
||||
@@ -130,7 +130,7 @@ function Details:OpenClassColorsConfig()
|
||||
local colortable = colorTable[1]
|
||||
local colorname = colorTable[2]
|
||||
local value = colorname .. "@" .. barType
|
||||
tinsert(result, {label = colorname, value = value, color = colortable, onclick = colorSelected})
|
||||
table.insert(result, {label = colorname, value = value, color = colortable, onclick = colorSelected})
|
||||
end
|
||||
|
||||
return result
|
||||
|
||||
@@ -9,7 +9,7 @@ do
|
||||
|
||||
local panel = CreateFrame("frame", "DetailsCopy", UIParent, "ButtonFrameTemplate")
|
||||
panel:SetSize(512, 148)
|
||||
tinsert(UISpecialFrames, "DetailsCopy")
|
||||
table.insert(UISpecialFrames, "DetailsCopy")
|
||||
panel:SetFrameStrata("TOOLTIP")
|
||||
panel:SetPoint("center", UIParent, "center")
|
||||
panel.locked = false
|
||||
|
||||
@@ -723,8 +723,8 @@ function Details:CreateCurrentDpsFrame(parent, name)
|
||||
local yellowDamageDone = thisTickYellowDamage - f.LastYellowDamage
|
||||
|
||||
--add the damage to buffer
|
||||
tinsert(f.PlayerTeamBuffer, 1, playerTeamDamageDone)
|
||||
tinsert(f.YellowTeamBuffer, 1, yellowDamageDone)
|
||||
table.insert(f.PlayerTeamBuffer, 1, playerTeamDamageDone)
|
||||
table.insert(f.YellowTeamBuffer, 1, yellowDamageDone)
|
||||
|
||||
--save the current damage amount
|
||||
f.LastPlayerTeamDamage = thisTickPlayerTeamDamage
|
||||
@@ -824,7 +824,7 @@ function Details:CreateCurrentDpsFrame(parent, name)
|
||||
local groupDamageDoneOnThisTick = thisTickGroupDamage - f.LastTickGroupDamage
|
||||
|
||||
--add the damage to buffer
|
||||
tinsert(f.GroupBuffer, 1, groupDamageDoneOnThisTick)
|
||||
table.insert(f.GroupBuffer, 1, groupDamageDoneOnThisTick)
|
||||
|
||||
--save the current damage amount
|
||||
f.LastTickGroupDamage = thisTickGroupDamage
|
||||
|
||||
@@ -811,12 +811,12 @@ function Details:CreateEventTrackerFrame(parentObject, name)
|
||||
|
||||
--defensive cooldown
|
||||
if (token == "SPELL_CAST_SUCCESS" and (spellInfo and defensiveCDType[spellInfo.type]) and is_player (caster_flags)) then
|
||||
tinsert(CurrentShowing, 1, {SPELLTYPE_COOLDOWN, spellid, caster_name, target_name, time, false, GetTime(), caster_serial, is_enemy (caster_flags), target_serial})
|
||||
table.insert(CurrentShowing, 1, {SPELLTYPE_COOLDOWN, spellid, caster_name, target_name, time, false, GetTime(), caster_serial, is_enemy (caster_flags), target_serial})
|
||||
added = true
|
||||
|
||||
--offensive cooldown
|
||||
elseif (token == "SPELL_CAST_SUCCESS" and (spellInfo and spellInfo.type == 1 and spellInfo.cooldown and spellInfo.cooldown >= 90) and is_player (caster_flags)) then
|
||||
tinsert(CurrentShowing, 1, {SPELLTYPE_OFFENSIVE, spellid, caster_name, target_name, time, false, GetTime(), caster_serial, is_enemy (caster_flags), target_serial})
|
||||
table.insert(CurrentShowing, 1, {SPELLTYPE_OFFENSIVE, spellid, caster_name, target_name, time, false, GetTime(), caster_serial, is_enemy (caster_flags), target_serial})
|
||||
added = true
|
||||
|
||||
--crowd control
|
||||
@@ -826,14 +826,14 @@ function Details:CreateEventTrackerFrame(parentObject, name)
|
||||
--the target is a player
|
||||
if (Details.event_tracker.show_crowdcontrol_pvp) then
|
||||
if (Details.zone_type == "arena" or Details.zone_type == "pvp" or Details.zone_type == "none") then
|
||||
tinsert(CurrentShowing, 1, {SPELLTYPE_CROWDCONTROL, spellid, caster_name, target_name, time, false, GetTime(), caster_serial, is_enemy (caster_flags), target_serial})
|
||||
table.insert(CurrentShowing, 1, {SPELLTYPE_CROWDCONTROL, spellid, caster_name, target_name, time, false, GetTime(), caster_serial, is_enemy (caster_flags), target_serial})
|
||||
added = true
|
||||
end
|
||||
end
|
||||
|
||||
if (Details.event_tracker.show_crowdcontrol_pvm) then
|
||||
if (Details.zone_type == "party" or Details.zone_type == "raid") then
|
||||
tinsert(CurrentShowing, 1, {SPELLTYPE_CROWDCONTROL, spellid, caster_name, target_name, time, false, GetTime(), caster_serial, is_enemy (caster_flags), target_serial})
|
||||
table.insert(CurrentShowing, 1, {SPELLTYPE_CROWDCONTROL, spellid, caster_name, target_name, time, false, GetTime(), caster_serial, is_enemy (caster_flags), target_serial})
|
||||
added = true
|
||||
end
|
||||
end
|
||||
@@ -842,7 +842,7 @@ function Details:CreateEventTrackerFrame(parentObject, name)
|
||||
--spell interrupt
|
||||
elseif (token == "SPELL_INTERRUPT") then
|
||||
if (caster_flags and is_player (caster_flags)) then
|
||||
tinsert(CurrentShowing, 1, {SPELLTYPE_INTERRUPT, spellid, caster_name, target_name, time, extraSpellID, GetTime(), caster_serial, is_enemy (caster_flags), target_serial})
|
||||
table.insert(CurrentShowing, 1, {SPELLTYPE_INTERRUPT, spellid, caster_name, target_name, time, extraSpellID, GetTime(), caster_serial, is_enemy (caster_flags), target_serial})
|
||||
added = true
|
||||
end
|
||||
end
|
||||
|
||||
@@ -151,7 +151,7 @@ function Details:OpenForge()
|
||||
|
||||
function f:InstallModule (module)
|
||||
if (module and type(module) == "table") then
|
||||
tinsert(all_modules, module)
|
||||
table.insert(all_modules, module)
|
||||
end
|
||||
end
|
||||
|
||||
@@ -479,7 +479,7 @@ function Details:OpenForge()
|
||||
end
|
||||
|
||||
if (can_add) then
|
||||
tinsert(t, {spellID, Details.classid_to_classstring [className] or className})
|
||||
table.insert(t, {spellID, Details.classid_to_classstring [className] or className})
|
||||
end
|
||||
|
||||
end
|
||||
@@ -625,7 +625,7 @@ function Details:OpenForge()
|
||||
end
|
||||
|
||||
if (can_add) then
|
||||
tinsert(t, {spellID, encounterID, enemyName, bossDetails and bossDetails.boss or "--x--x--"})
|
||||
table.insert(t, {spellID, encounterID, enemyName, bossDetails and bossDetails.boss or "--x--x--"})
|
||||
end
|
||||
end
|
||||
end
|
||||
@@ -734,7 +734,7 @@ function Details:OpenForge()
|
||||
end
|
||||
end
|
||||
if (canAdd) then
|
||||
tinsert(t, {npcId, npcName})
|
||||
table.insert(t, {npcId, npcName})
|
||||
end
|
||||
end
|
||||
|
||||
@@ -1136,7 +1136,7 @@ function Details:OpenForge()
|
||||
end
|
||||
|
||||
lastButton = b
|
||||
tinsert(buttons, b)
|
||||
table.insert(buttons, b)
|
||||
end
|
||||
|
||||
select_module (nil, nil, 1)
|
||||
|
||||
@@ -537,7 +537,7 @@ local update_line = function(self, target_frame)
|
||||
ball:SetSize(16, 16)
|
||||
ball:SetAlpha(0.3)
|
||||
ball:SetTexCoord(410/512, 426/512, 2/512, 18/512)
|
||||
tinsert(guide_balls, ball)
|
||||
table.insert(guide_balls, ball)
|
||||
end
|
||||
|
||||
ball:ClearAllPoints()
|
||||
@@ -1165,7 +1165,7 @@ end
|
||||
local check_snap_side = function(instanceid, snap, id, container)
|
||||
local instance = Details:GetInstance(instanceid)
|
||||
if (instance and instance.snap [snap] and instance.snap [snap] == id) then
|
||||
tinsert(container, instance)
|
||||
table.insert(container, instance)
|
||||
return true
|
||||
end
|
||||
end
|
||||
@@ -1260,7 +1260,7 @@ function Details:InstanciasVerticais(instance)
|
||||
end
|
||||
bottom_clamp = bottom_clamp + 20
|
||||
bottom_clamp = bottom_clamp + this_instance.baseframe:GetHeight()
|
||||
tinsert(on_top, this_instance)
|
||||
table.insert(on_top, this_instance)
|
||||
end
|
||||
|
||||
return on_top, bottom_clamp, top_clamp
|
||||
@@ -2286,7 +2286,7 @@ function icon_frame_events:EnterCombat()
|
||||
for anim, _ in pairs(Details.icon_animations.load.in_use) do
|
||||
anim.anim:Stop()
|
||||
anim:Hide()
|
||||
tinsert(Details.icon_animations.load.available, anim)
|
||||
table.insert(Details.icon_animations.load.available, anim)
|
||||
|
||||
anim.icon_frame.icon_animation = nil
|
||||
anim.icon_frame = nil
|
||||
@@ -2318,7 +2318,7 @@ function icon_frame_events:CancelAnim(anim)
|
||||
end
|
||||
|
||||
Details.icon_animations.load.in_use[frame] = nil
|
||||
tinsert(Details.icon_animations.load.available, frame)
|
||||
table.insert(Details.icon_animations.load.available, frame)
|
||||
frame.anim:Stop()
|
||||
frame:Hide()
|
||||
|
||||
@@ -2335,7 +2335,7 @@ local icon_frame_inspect_callback = function(guid, unitid, iconFrame)
|
||||
|
||||
local inUse = Details.icon_animations.load.in_use[iconFrame.icon_animation]
|
||||
if (inUse) then
|
||||
tinsert(Details.icon_animations.load.available, iconFrame.icon_animation)
|
||||
table.insert(Details.icon_animations.load.available, iconFrame.icon_animation)
|
||||
Details.icon_animations.load.in_use[iconFrame.icon_animation] = nil
|
||||
end
|
||||
|
||||
@@ -2363,7 +2363,7 @@ local icon_frame_create_animation = function()
|
||||
t:SetAlpha(0.7)
|
||||
t:SetAllPoints()
|
||||
|
||||
tinsert(Details.icon_animations.load.available, f)
|
||||
table.insert(Details.icon_animations.load.available, f)
|
||||
end
|
||||
|
||||
local icon_frame_on_click_down = function(self)
|
||||
@@ -8385,7 +8385,7 @@ function Details:GetInstanceGroup (instance_id)
|
||||
if (this_instance and this_instance:IsEnabled()) then
|
||||
for side, id in pairs(this_instance.snap) do
|
||||
if (id == last_id) then
|
||||
tinsert(current_group, this_instance)
|
||||
table.insert(current_group, this_instance)
|
||||
got = true
|
||||
last_id = i
|
||||
end
|
||||
@@ -8403,7 +8403,7 @@ function Details:GetInstanceGroup (instance_id)
|
||||
if (this_instance and this_instance:IsEnabled()) then
|
||||
for side, id in pairs(this_instance.snap) do
|
||||
if (id == last_id) then
|
||||
tinsert(current_group, this_instance)
|
||||
table.insert(current_group, this_instance)
|
||||
got = true
|
||||
last_id = i
|
||||
end
|
||||
|
||||
@@ -70,7 +70,7 @@ function Details:CreateOrOpenNewsWindow()
|
||||
|
||||
if (not frame) then
|
||||
frame = DetailsFramework:CreateSimplePanel(UIParent, 480, 560, "Details! Damage Meter " .. Details.version, "DetailsNewsWindow", panel_options, db)
|
||||
tinsert(UISpecialFrames, "DetailsNewsWindow")
|
||||
table.insert(UISpecialFrames, "DetailsNewsWindow")
|
||||
frame:SetPoint("left", UIParent, "left", 10, 0)
|
||||
frame:SetFrameStrata("FULLSCREEN")
|
||||
frame:SetMovable(true)
|
||||
|
||||
@@ -45,7 +45,7 @@ function Details.OpenPlaterIntegrationWindow()
|
||||
local build_anchor_side_table = function(member)
|
||||
local t = {}
|
||||
for i = 1, 13 do
|
||||
tinsert(t, {
|
||||
table.insert(t, {
|
||||
label = anchor_names[i],
|
||||
value = i,
|
||||
onclick = function(_, _, value)
|
||||
|
||||
@@ -121,7 +121,7 @@ local _
|
||||
Details.copypasteframe = CreateFrame("frame", "DetailsCopyPasteFrame2", UIParent, "BackdropTemplate")
|
||||
Details.copypasteframe:SetFrameStrata("TOOLTIP")
|
||||
Details.copypasteframe:SetPoint("CENTER", UIParent, "CENTER", 0, 50)
|
||||
tinsert(UISpecialFrames, "DetailsCopyPasteFrame2")
|
||||
table.insert(UISpecialFrames, "DetailsCopyPasteFrame2")
|
||||
Details.copypasteframe:SetSize(400, 400)
|
||||
Details.copypasteframe:Hide()
|
||||
|
||||
@@ -686,10 +686,10 @@ local createDropdown = function(thisFrame)
|
||||
bg1:SetHorizTile(true)
|
||||
bg1:SetAllPoints()
|
||||
|
||||
tinsert(window.all_widgets, bg1)
|
||||
tinsert(window.widgets, bg1)
|
||||
tinsert(window.all_widgets, titlebar)
|
||||
tinsert(window.widgets, titlebar)
|
||||
table.insert(window.all_widgets, bg1)
|
||||
table.insert(window.widgets, bg1)
|
||||
table.insert(window.all_widgets, titlebar)
|
||||
table.insert(window.widgets, titlebar)
|
||||
end
|
||||
|
||||
window.title:ClearAllPoints()
|
||||
@@ -747,7 +747,7 @@ local createDropdown = function(thisFrame)
|
||||
function gump:CriaJanelaReport()
|
||||
--window
|
||||
local window = CreateFrame("Frame", "DetailsReportWindow", UIParent, "BackdropTemplate")
|
||||
tinsert(UISpecialFrames, "DetailsReportWindow")
|
||||
table.insert(UISpecialFrames, "DetailsReportWindow")
|
||||
window:SetPoint("CENTER", UIParent, "CENTER")
|
||||
window:SetFrameStrata("DIALOG")
|
||||
window.skins = {}
|
||||
@@ -833,7 +833,7 @@ local createDropdown = function(thisFrame)
|
||||
button.icon = icon
|
||||
button.text = text
|
||||
button:SetScript("OnClick", recentlyButtonOnClick)
|
||||
tinsert(window.recently_report_buttons, button)
|
||||
table.insert(window.recently_report_buttons, button)
|
||||
end
|
||||
|
||||
historyBlockBackground:Hide()
|
||||
|
||||
@@ -238,7 +238,7 @@ function Details:ScrollDamage()
|
||||
if (not DetailsScrollDamage.Data.Started) then
|
||||
DetailsScrollDamage.Data.Started = time()
|
||||
end
|
||||
tinsert(DetailsScrollDamage.Data, 1, {timew, token, hidding, sourceSerial, sourceName, sourceFlag, sourceFlag2, targetSerial, targetName, targetFlag, targetFlag2, spellID, spellName, spellType, amount, overKill or 0, school or 1, resisted or 0, blocked or 0, absorbed or 0, isCritical})
|
||||
table.insert(DetailsScrollDamage.Data, 1, {timew, token, hidding, sourceSerial, sourceName, sourceFlag, sourceFlag2, targetSerial, targetName, targetFlag, targetFlag2, spellID, spellName, spellType, amount, overKill or 0, school or 1, resisted or 0, blocked or 0, absorbed or 0, isCritical})
|
||||
Details:Destroy(DetailsScrollDamage.searchCache)
|
||||
damageScroll:RefreshScroll()
|
||||
|
||||
|
||||
@@ -39,7 +39,7 @@ function Details:OpenRaidHistoryWindow(raidName, bossEncounterId, difficultyId,
|
||||
statisticsFrame:SetMovable(true)
|
||||
statisticsFrame:SetWidth(850)
|
||||
statisticsFrame:SetHeight(500)
|
||||
tinsert(UISpecialFrames, "DetailsRaidHistoryWindow")
|
||||
table.insert(UISpecialFrames, "DetailsRaidHistoryWindow")
|
||||
|
||||
function statisticsFrame.OpenDB()
|
||||
local db = Details.storage:OpenRaidStorage()
|
||||
@@ -245,7 +245,7 @@ function Details:OpenRaidHistoryWindow(raidName, bossEncounterId, difficultyId,
|
||||
playerName = playerName:gsub("%|c%x%x%x%x%x%x%x%x", "")
|
||||
playerName = playerName:gsub("%|r", "")
|
||||
playerName = playerName:gsub(".*%s", "")
|
||||
tinsert(result, {playerName, statisticsFrame.LatestResourceTable[i][2]})
|
||||
table.insert(result, {playerName, statisticsFrame.LatestResourceTable[i][2]})
|
||||
else
|
||||
break
|
||||
end
|
||||
@@ -433,7 +433,7 @@ function Details:OpenRaidHistoryWindow(raidName, bossEncounterId, difficultyId,
|
||||
local roleTable = encounter [role]
|
||||
for playerName, _ in pairs(roleTable) do
|
||||
if (not alreadyListed [playerName]) then
|
||||
tinsert(t, {value = playerName, label = playerName, icon = icon, onclick = onPlayer2Select})
|
||||
table.insert(t, {value = playerName, label = playerName, icon = icon, onclick = onPlayer2Select})
|
||||
alreadyListed [playerName] = true
|
||||
end
|
||||
end
|
||||
@@ -495,7 +495,7 @@ function Details:OpenRaidHistoryWindow(raidName, bossEncounterId, difficultyId,
|
||||
if (encounter) then
|
||||
local instanceId = Details:GetInstanceIdFromEncounterId(dungeonEncounterID)
|
||||
if (raidSelected == instanceId) then
|
||||
tinsert(bossList, {value = dungeonEncounterID, label = encounter.boss, icon = icon, onclick = onSelectBoss})
|
||||
table.insert(bossList, {value = dungeonEncounterID, label = encounter.boss, icon = icon, onclick = onSelectBoss})
|
||||
bossRepeated[dungeonEncounterID] = true
|
||||
end
|
||||
|
||||
@@ -513,7 +513,7 @@ function Details:OpenRaidHistoryWindow(raidName, bossEncounterId, difficultyId,
|
||||
local raidIcon = raidData.raidIcon
|
||||
local raidIconCoords = raidData.raidIconCoords
|
||||
|
||||
tinsert(raidList, {value = instance.id, label = instanceName, icon = raidIcon, texcoord = raidIconCoords, onclick = onRaidSelect})
|
||||
table.insert(raidList, {value = instance.id, label = instanceName, icon = raidIcon, texcoord = raidIconCoords, onclick = onRaidSelect})
|
||||
raidRepeated[instance.name] = true
|
||||
end
|
||||
end
|
||||
@@ -523,14 +523,14 @@ function Details:OpenRaidHistoryWindow(raidName, bossEncounterId, difficultyId,
|
||||
--add guild name to the dropdown
|
||||
if (playerGuildName) then
|
||||
if (not guildRepeated[playerGuildName]) then
|
||||
tinsert(guildList, {value = playerGuildName, label = playerGuildName, icon = icon, onclick = onGuildSelect})
|
||||
table.insert(guildList, {value = playerGuildName, label = playerGuildName, icon = icon, onclick = onGuildSelect})
|
||||
guildRepeated[playerGuildName] = true
|
||||
end
|
||||
else
|
||||
for index, encounter in ipairs(encounterTable) do
|
||||
local guild = encounter.guild
|
||||
if (not guildRepeated[guild]) then
|
||||
tinsert(guildList, {value = guild, label = guild, icon = icon, onclick = onGuildSelect})
|
||||
table.insert(guildList, {value = guild, label = guild, icon = icon, onclick = onGuildSelect})
|
||||
guildRepeated[guild] = true
|
||||
end
|
||||
end
|
||||
@@ -545,7 +545,7 @@ function Details:OpenRaidHistoryWindow(raidName, bossEncounterId, difficultyId,
|
||||
end
|
||||
end
|
||||
if (not alreadyHave) then
|
||||
tinsert(difficultyList, 1, {value = difficulty, label = "Normal", icon = icon, onclick = onDifficultySelect})
|
||||
table.insert(difficultyList, 1, {value = difficulty, label = "Normal", icon = icon, onclick = onDifficultySelect})
|
||||
end
|
||||
|
||||
elseif (difficulty == 15) then
|
||||
@@ -556,7 +556,7 @@ function Details:OpenRaidHistoryWindow(raidName, bossEncounterId, difficultyId,
|
||||
end
|
||||
end
|
||||
if (not alreadyHave) then
|
||||
tinsert(difficultyList, 1, {value = difficulty, label = "Heroic", icon = icon, onclick = onDifficultySelect})
|
||||
table.insert(difficultyList, 1, {value = difficulty, label = "Heroic", icon = icon, onclick = onDifficultySelect})
|
||||
end
|
||||
|
||||
elseif (difficulty == 16) then
|
||||
@@ -567,7 +567,7 @@ function Details:OpenRaidHistoryWindow(raidName, bossEncounterId, difficultyId,
|
||||
end
|
||||
end
|
||||
if (not alreadyHave) then
|
||||
tinsert(difficultyList, {value = difficulty, label = "Mythic", icon = icon, onclick = onDifficultySelect})
|
||||
table.insert(difficultyList, {value = difficulty, label = "Mythic", icon = icon, onclick = onDifficultySelect})
|
||||
end
|
||||
end
|
||||
end
|
||||
@@ -631,7 +631,7 @@ function Details:OpenRaidHistoryWindow(raidName, bossEncounterId, difficultyId,
|
||||
if (encounter) then
|
||||
local instanceId = Details:GetInstanceIdFromEncounterId(dungeonEncounterID)
|
||||
if (raidSelected == instanceId) then
|
||||
tinsert(bossList, {value = dungeonEncounterID, label = encounter.boss, icon = icon, onclick = onSelectBoss})
|
||||
table.insert(bossList, {value = dungeonEncounterID, label = encounter.boss, icon = icon, onclick = onSelectBoss})
|
||||
bossRepeated[dungeonEncounterID] = true
|
||||
end
|
||||
end
|
||||
@@ -646,7 +646,7 @@ function Details:OpenRaidHistoryWindow(raidName, bossEncounterId, difficultyId,
|
||||
end
|
||||
end
|
||||
if (not alreadyHave) then
|
||||
tinsert(difficultyList, 1, {value = difficulty, label = "Normal", icon = icon, onclick = onDifficultySelect})
|
||||
table.insert(difficultyList, 1, {value = difficulty, label = "Normal", icon = icon, onclick = onDifficultySelect})
|
||||
end
|
||||
|
||||
elseif (difficulty == 15) then
|
||||
@@ -657,7 +657,7 @@ function Details:OpenRaidHistoryWindow(raidName, bossEncounterId, difficultyId,
|
||||
end
|
||||
end
|
||||
if (not alreadyHave) then
|
||||
tinsert(difficultyList, 1, {value = difficulty, label = "Heroic", icon = icon, onclick = onDifficultySelect})
|
||||
table.insert(difficultyList, 1, {value = difficulty, label = "Heroic", icon = icon, onclick = onDifficultySelect})
|
||||
end
|
||||
|
||||
elseif (difficulty == 16) then
|
||||
@@ -668,7 +668,7 @@ function Details:OpenRaidHistoryWindow(raidName, bossEncounterId, difficultyId,
|
||||
end
|
||||
end
|
||||
if (not alreadyHave) then
|
||||
tinsert(difficultyList, {value = difficulty, label = "Mythic", icon = icon, onclick = onDifficultySelect})
|
||||
table.insert(difficultyList, {value = difficulty, label = "Mythic", icon = icon, onclick = onDifficultySelect})
|
||||
end
|
||||
end
|
||||
end
|
||||
@@ -725,7 +725,7 @@ function Details:OpenRaidHistoryWindow(raidName, bossEncounterId, difficultyId,
|
||||
if (player) then
|
||||
|
||||
--tinsert(data, {text = date, value = player[1], data = player, fulldate = encounter.date, elapsed = encounter.elapsed})
|
||||
tinsert(data, {text = date, value = player[1]/encounter.elapsed, utext = Details:ToK2 (player[1]/encounter.elapsed), data = player, fulldate = encounter.date, elapsed = encounter.elapsed})
|
||||
table.insert(data, {text = date, value = player[1]/encounter.elapsed, utext = Details:ToK2 (player[1]/encounter.elapsed), data = player, fulldate = encounter.date, elapsed = encounter.elapsed})
|
||||
end
|
||||
end
|
||||
end
|
||||
@@ -816,7 +816,7 @@ function Details:OpenRaidHistoryWindow(raidName, bossEncounterId, difficultyId,
|
||||
end
|
||||
|
||||
local playerNameFormated = Details:GetOnlyName(playerName)
|
||||
tinsert(sortTable, {
|
||||
table.insert(sortTable, {
|
||||
"|c" .. classColor .. playerNameFormated .. "|r",
|
||||
Details:comma_value (t.ps),
|
||||
Details:ToK2 (t.total),
|
||||
@@ -865,7 +865,7 @@ function Details:OpenRaidHistoryWindow(raidName, bossEncounterId, difficultyId,
|
||||
date = date:sub (1, -4)
|
||||
amt_encounters = amt_encounters + 1
|
||||
|
||||
tinsert(header, {name = date, type = "text"})
|
||||
table.insert(header, {name = date, type = "text"})
|
||||
|
||||
for playerName, playerTable in pairs(roleTable) do
|
||||
local index = players_index [playerName]
|
||||
@@ -875,19 +875,19 @@ function Details:OpenRaidHistoryWindow(raidName, bossEncounterId, difficultyId,
|
||||
player = {playerName}
|
||||
player_class [playerName] = playerTable [3]
|
||||
for i = 1, amt_encounters-1 do
|
||||
tinsert(player, "")
|
||||
table.insert(player, "")
|
||||
end
|
||||
tinsert(player, Details:ToK2 (playerTable [1] / encounter.elapsed))
|
||||
tinsert(players, player)
|
||||
table.insert(player, Details:ToK2 (playerTable [1] / encounter.elapsed))
|
||||
table.insert(players, player)
|
||||
players_index [playerName] = #players
|
||||
|
||||
--print("not index", playerName, amt_encounters, date, 2, amt_encounters-1)
|
||||
else
|
||||
player = players [index]
|
||||
for i = #player+1, amt_encounters-1 do
|
||||
tinsert(player, "")
|
||||
table.insert(player, "")
|
||||
end
|
||||
tinsert(player, Details:ToK2 (playerTable [1] / encounter.elapsed))
|
||||
table.insert(player, Details:ToK2 (playerTable [1] / encounter.elapsed))
|
||||
end
|
||||
|
||||
end
|
||||
@@ -899,7 +899,7 @@ function Details:OpenRaidHistoryWindow(raidName, bossEncounterId, difficultyId,
|
||||
|
||||
for index, playerTable in ipairs(players) do
|
||||
for i = #playerTable, amt_encounters do
|
||||
tinsert(playerTable, "")
|
||||
table.insert(playerTable, "")
|
||||
end
|
||||
|
||||
local className = select(2, GetClassInfo (player_class [playerTable [1]] or 0))
|
||||
|
||||
@@ -244,7 +244,7 @@ do
|
||||
allDisplaysFrame.check_text_size (button.text)
|
||||
button.texture:SetTexture(Details.sub_atributos [attribute].icones [i] [1])
|
||||
button.texture:SetTexCoord(unpack(Details.sub_atributos [attribute].icones [i] [2]))
|
||||
tinsert(allDisplaysFrame.buttons [attribute], button)
|
||||
table.insert(allDisplaysFrame.buttons [attribute], button)
|
||||
y = y - 17
|
||||
end
|
||||
|
||||
@@ -302,7 +302,7 @@ do
|
||||
local button = allDisplaysFrame.buttons [custom_index] [button_index]
|
||||
if (not button) then
|
||||
button = create_all_switch_button (custom_index, i, allDisplaysFrame.x, allDisplaysFrame.y)
|
||||
tinsert(allDisplaysFrame.buttons [custom_index], button)
|
||||
table.insert(allDisplaysFrame.buttons [custom_index], button)
|
||||
allDisplaysFrame.y = allDisplaysFrame.y - 17
|
||||
end
|
||||
|
||||
@@ -342,7 +342,7 @@ do
|
||||
local button = allDisplaysFrame.buttons [script_index] [button_index]
|
||||
if (not button) then
|
||||
button = create_all_switch_button(script_index, button_index, allDisplaysFrame.x, allDisplaysFrame.y)
|
||||
tinsert(allDisplaysFrame.buttons [script_index], button)
|
||||
table.insert(allDisplaysFrame.buttons [script_index], button)
|
||||
allDisplaysFrame.y = allDisplaysFrame.y - 17
|
||||
end
|
||||
|
||||
@@ -561,7 +561,7 @@ function Details.switch:ShowMe(instancia)
|
||||
s.HideMe = hide_label
|
||||
s.ShowMe = show_label
|
||||
|
||||
tinsert(Details.switch.segments_blocks, s)
|
||||
table.insert(Details.switch.segments_blocks, s)
|
||||
return s
|
||||
end
|
||||
|
||||
|
||||
@@ -1779,7 +1779,7 @@ function _detalhes:CreateWeakAura (aura_type, spellid, use_spellid, spellname, n
|
||||
else
|
||||
new_aura.trigger.spellId = tostring(spellid)
|
||||
new_aura.trigger.name = spellname
|
||||
tinsert(new_aura.trigger.spellIds, spellid)
|
||||
table.insert(new_aura.trigger.spellIds, spellid)
|
||||
end
|
||||
|
||||
--if is a regular aura without using spells ids
|
||||
@@ -1902,7 +1902,7 @@ function _detalhes:CreateWeakAura (aura_type, spellid, use_spellid, spellname, n
|
||||
end
|
||||
end
|
||||
|
||||
tinsert(WeakAurasSaved.displays [group].controlledChildren, new_aura.id)
|
||||
table.insert(WeakAurasSaved.displays [group].controlledChildren, new_aura.id)
|
||||
else
|
||||
new_aura.parent = nil
|
||||
end
|
||||
@@ -2387,11 +2387,11 @@ function _detalhes:OpenAuraPanel (spellid, spellname, spellicon, encounterid, tr
|
||||
|
||||
for _, sound in ipairs(sounds) do
|
||||
if (sound.name:find("D_")) then --details sound
|
||||
tinsert(t, {color = "orange", label = sound.name, value = sound.file, icon = [[Interface\Buttons\UI-GuildButton-MOTD-Up]], onclick = play_sound, iconsize = iconsize})
|
||||
table.insert(t, {color = "orange", label = sound.name, value = sound.file, icon = [[Interface\Buttons\UI-GuildButton-MOTD-Up]], onclick = play_sound, iconsize = iconsize})
|
||||
elseif (sound.gamesound) then --game sound
|
||||
tinsert(t, {color = "yellow", label = sound.name, value = {sound_path = sound.file}, icon = [[Interface\Buttons\UI-GuildButton-MOTD-Up]], onclick = play_sound, iconsize = iconsize})
|
||||
table.insert(t, {color = "yellow", label = sound.name, value = {sound_path = sound.file}, icon = [[Interface\Buttons\UI-GuildButton-MOTD-Up]], onclick = play_sound, iconsize = iconsize})
|
||||
else
|
||||
tinsert(t, {label = sound.name, value = sound.file, icon = [[Interface\Buttons\UI-GuildButton-MOTD-Up]], onclick = play_sound, iconsize = iconsize})
|
||||
table.insert(t, {label = sound.name, value = sound.file, icon = [[Interface\Buttons\UI-GuildButton-MOTD-Up]], onclick = play_sound, iconsize = iconsize})
|
||||
end
|
||||
end
|
||||
return t
|
||||
@@ -2458,7 +2458,7 @@ function _detalhes:OpenAuraPanel (spellid, spellname, spellicon, encounterid, tr
|
||||
local addon_options = function()
|
||||
local t = {}
|
||||
if (WeakAuras) then
|
||||
tinsert(t, {label = "Weak Auras 2", value = "WA", icon = [[Interface\AddOns\WeakAuras\Media\Textures\icon]]})
|
||||
table.insert(t, {label = "Weak Auras 2", value = "WA", icon = [[Interface\AddOns\WeakAuras\Media\Textures\icon]]})
|
||||
end
|
||||
return t
|
||||
end
|
||||
@@ -2480,12 +2480,12 @@ function _detalhes:OpenAuraPanel (spellid, spellname, spellicon, encounterid, tr
|
||||
if (WeakAuras and WeakAurasSaved) then
|
||||
for display_name, aura_table in pairs(WeakAurasSaved.displays) do
|
||||
if (aura_table.regionType == "dynamicgroup" or aura_table.regionType == "group") then
|
||||
tinsert(t, {label = display_name, value = display_name, icon = folder_icon, texcoord = folder_texcoord, iconsize = folder_iconsize})
|
||||
table.insert(t, {label = display_name, value = display_name, icon = folder_icon, texcoord = folder_texcoord, iconsize = folder_iconsize})
|
||||
end
|
||||
end
|
||||
end
|
||||
table.sort (t, sort_func)
|
||||
tinsert(t, 1, {label = "No Group", value = false, icon = folder_icon, texcoord = folder_texcoord, iconcolor = {0.8, 0.2, 0.2}, iconsize = folder_iconsize})
|
||||
table.insert(t, 1, {label = "No Group", value = false, icon = folder_icon, texcoord = folder_texcoord, iconcolor = {0.8, 0.2, 0.2}, iconsize = folder_iconsize})
|
||||
return t
|
||||
end
|
||||
|
||||
|
||||
+12
-12
@@ -406,8 +406,8 @@ local window_openned_at = time()
|
||||
window.LatinAlphabetCheckBox.OnSwitch = onSelectAlphabet
|
||||
window.LatinAlphabetLabel:SetPoint("left", window.LatinAlphabetCheckBox, "right", 2, 0)
|
||||
|
||||
tinsert(allAlphabetCheckBoxes, window.LatinAlphabetCheckBox)
|
||||
tinsert(allAlphabetLabels, window.LatinAlphabetLabel)
|
||||
table.insert(allAlphabetCheckBoxes, window.LatinAlphabetCheckBox)
|
||||
table.insert(allAlphabetLabels, window.LatinAlphabetLabel)
|
||||
|
||||
--Russian
|
||||
g:NewLabel(window, _, "$parentCyrillicAlphabetLabel", "CyrillicAlphabetLabel", Loc["STRING_WELCOME_75"], "GameFontHighlightLeft")
|
||||
@@ -417,8 +417,8 @@ local window_openned_at = time()
|
||||
window.CyrillicAlphabetCheckBox:SetTemplate(g:GetTemplate("switch", "OPTIONS_CHECKBOX_TEMPLATE"))
|
||||
window.CyrillicAlphabetCheckBox.OnSwitch = onSelectAlphabet
|
||||
window.CyrillicAlphabetLabel:SetPoint("left", window.CyrillicAlphabetCheckBox, "right", 2, 0)
|
||||
tinsert(allAlphabetCheckBoxes, window.CyrillicAlphabetCheckBox)
|
||||
tinsert(allAlphabetLabels, window.CyrillicAlphabetLabel)
|
||||
table.insert(allAlphabetCheckBoxes, window.CyrillicAlphabetCheckBox)
|
||||
table.insert(allAlphabetLabels, window.CyrillicAlphabetLabel)
|
||||
|
||||
--Chinese
|
||||
g:NewLabel(window, _, "$parentChinaAlphabetLabel", "ChinaAlphabetLabel", Loc["STRING_WELCOME_76"], "GameFontHighlightLeft")
|
||||
@@ -428,8 +428,8 @@ local window_openned_at = time()
|
||||
window.ChinaCheckBox:SetTemplate(g:GetTemplate("switch", "OPTIONS_CHECKBOX_TEMPLATE"))
|
||||
window.ChinaCheckBox.OnSwitch = onSelectAlphabet
|
||||
window.ChinaAlphabetLabel:SetPoint("left", window.ChinaCheckBox, "right", 2, 0)
|
||||
tinsert(allAlphabetCheckBoxes, window.ChinaCheckBox)
|
||||
tinsert(allAlphabetLabels, window.ChinaAlphabetLabel)
|
||||
table.insert(allAlphabetCheckBoxes, window.ChinaCheckBox)
|
||||
table.insert(allAlphabetLabels, window.ChinaAlphabetLabel)
|
||||
|
||||
--Korea
|
||||
g:NewLabel(window, _, "$parentKoreanAlphabetLabel", "KoreanAlphabetLabel", Loc["STRING_WELCOME_77"], "GameFontHighlightLeft")
|
||||
@@ -439,8 +439,8 @@ local window_openned_at = time()
|
||||
window.KoreanCheckBox:SetTemplate(g:GetTemplate("switch", "OPTIONS_CHECKBOX_TEMPLATE"))
|
||||
window.KoreanCheckBox.OnSwitch = onSelectAlphabet
|
||||
window.KoreanAlphabetLabel:SetPoint("left", window.KoreanCheckBox, "right", 2, 0)
|
||||
tinsert(allAlphabetCheckBoxes, window.KoreanCheckBox)
|
||||
tinsert(allAlphabetLabels, window.KoreanAlphabetLabel)
|
||||
table.insert(allAlphabetCheckBoxes, window.KoreanCheckBox)
|
||||
table.insert(allAlphabetLabels, window.KoreanAlphabetLabel)
|
||||
|
||||
--Taiwan
|
||||
g:NewLabel(window, _, "$parentTaiwanAlphabetLabel", "TaiwanAlphabetLabel", Loc["STRING_WELCOME_78"], "GameFontHighlightLeft")
|
||||
@@ -450,8 +450,8 @@ local window_openned_at = time()
|
||||
window.TaiwanCheckBox:SetTemplate(g:GetTemplate("switch", "OPTIONS_CHECKBOX_TEMPLATE"))
|
||||
window.TaiwanCheckBox.OnSwitch = onSelectAlphabet
|
||||
window.TaiwanAlphabetLabel:SetPoint("left", window.TaiwanCheckBox, "right", 2, 0)
|
||||
tinsert(allAlphabetCheckBoxes, window.TaiwanCheckBox)
|
||||
tinsert(allAlphabetLabels, window.TaiwanAlphabetLabel)
|
||||
table.insert(allAlphabetCheckBoxes, window.TaiwanCheckBox)
|
||||
table.insert(allAlphabetLabels, window.TaiwanAlphabetLabel)
|
||||
|
||||
window.LatinAlphabetCheckBox:SetPoint("topleft", texto_alphabet, "bottomleft", 0, -10)
|
||||
window.CyrillicAlphabetCheckBox:SetPoint("topleft", window.LatinAlphabetCheckBox, "bottomleft", 0, -2)
|
||||
@@ -653,10 +653,10 @@ local window_openned_at = time()
|
||||
|
||||
pages [#pages+1] = {skins_frame_alert, bg55, texto55, texto_alphabet, texto555, skins_image, changemind, texto_appearance, font_label, font_dropdown, skin_dropdown, skin_label, create_window_button, window_color, window.BarHeightLabel, window.BarHeightSlider, window.TextSizeLabel, window.TextSizeSlider, window.ShowPercentLabel, window.ShowPercentCheckBox}
|
||||
for i, widget in ipairs(allAlphabetCheckBoxes) do
|
||||
tinsert(pages [#pages], widget)
|
||||
table.insert(pages [#pages], widget)
|
||||
end
|
||||
for i, widget in ipairs(allAlphabetLabels) do
|
||||
tinsert(pages [#pages], widget)
|
||||
table.insert(pages [#pages], widget)
|
||||
end
|
||||
|
||||
for _, widget in ipairs(pages[#pages]) do
|
||||
|
||||
Reference in New Issue
Block a user