Fixed an error while trying to move the window by clicking and holding on a window line
This commit is contained in:
+7
-7
@@ -190,7 +190,7 @@ function gump:NewDetailsButton (parent, container, instancia, func, param1, para
|
||||
GameCooltip:SetType ("tooltip")
|
||||
GameCooltip:SetColor ("main", "transparent")
|
||||
GameCooltip:AddLine (new_button.tooltip)
|
||||
GameCooltip:SetOwner (new_button)
|
||||
GameCooltip:SetOwner(new_button)
|
||||
GameCooltip:ShowCooltip()
|
||||
end
|
||||
|
||||
@@ -208,7 +208,7 @@ function gump:NewDetailsButton (parent, container, instancia, func, param1, para
|
||||
new_button.enter = false
|
||||
|
||||
if (new_button.tooltip) then
|
||||
_detalhes.popup:ShowMe (false)
|
||||
_detalhes.popup:ShowMe(false)
|
||||
end
|
||||
|
||||
if (new_button.texture) then
|
||||
@@ -375,7 +375,7 @@ function gump:NewTextBox (parent, container, member, func, param1, param2, w, h,
|
||||
GameCooltip:SetType ("tooltip")
|
||||
GameCooltip:SetColor ("main", "transparent")
|
||||
GameCooltip:AddLine (editbox.tooltip)
|
||||
GameCooltip:SetOwner (editbox)
|
||||
GameCooltip:SetOwner(editbox)
|
||||
GameCooltip:ShowCooltip()
|
||||
end
|
||||
|
||||
@@ -398,7 +398,7 @@ function gump:NewTextBox (parent, container, member, func, param1, param2, w, h,
|
||||
|
||||
if (editbox.tooltip) then
|
||||
if (not editbox.HaveMenu) then
|
||||
_detalhes.popup:ShowMe (false)
|
||||
_detalhes.popup:ShowMe(false)
|
||||
end
|
||||
end
|
||||
|
||||
@@ -684,7 +684,7 @@ function gump:NewScrollBar2 (master, slave, x, y)
|
||||
slider_gump:Disable()
|
||||
slider_gump:SetValue(0)
|
||||
slider_gump.ativo = false
|
||||
master:EnableMouseWheel (false)
|
||||
master:EnableMouseWheel(false)
|
||||
return
|
||||
end
|
||||
|
||||
@@ -694,13 +694,13 @@ function gump:NewScrollBar2 (master, slave, x, y)
|
||||
if (not slider_gump.ativo) then
|
||||
slider_gump:Enable()
|
||||
slider_gump.ativo = true
|
||||
master:EnableMouseWheel (true)
|
||||
master:EnableMouseWheel(true)
|
||||
end
|
||||
else
|
||||
slider_gump:Disable()
|
||||
slider_gump:SetValue(0)
|
||||
slider_gump.ativo = false
|
||||
master:EnableMouseWheel (false)
|
||||
master:EnableMouseWheel(false)
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
@@ -27,7 +27,7 @@ function Details:CreateAPI2Frame()
|
||||
--local Api2Frame = DetailsFramework:CreateSimplePanel (UIParent, panelWidth, panelHeight, "Details! API 2.0", "DetailsAPI2Frame")
|
||||
local Api2Frame = _G.DetailsAPI2Frame
|
||||
|
||||
Api2Frame:SetFrameStrata ("FULLSCREEN")
|
||||
Api2Frame:SetFrameStrata("FULLSCREEN")
|
||||
Api2Frame:SetPoint("center")
|
||||
DetailsFramework:ApplyStandardBackdrop (Api2Frame, false, 1.2)
|
||||
|
||||
@@ -143,7 +143,7 @@ function Details:CreateAPI2Frame()
|
||||
end
|
||||
|
||||
for apiIndex, apiDesc in ipairs(api) do
|
||||
tinsert (apiFunctionNames, apiDesc.name)
|
||||
tinsert(apiFunctionNames, apiDesc.name)
|
||||
end
|
||||
|
||||
local api2ScrollMenu = DetailsFramework:CreateScrollBox (Api2Frame, "$parentApi2MenuScroll", apiMenuScrollRefresh, apiFunctionNames, scrollWidth, scrollHeight, lineAmount, lineHeight)
|
||||
@@ -166,7 +166,7 @@ function Details:CreateAPI2Frame()
|
||||
end
|
||||
|
||||
GameCooltip2:Preset(2)
|
||||
GameCooltip2:SetOwner (self, "left", "right", 2, 0)
|
||||
GameCooltip2:SetOwner(self, "left", "right", 2, 0)
|
||||
GameCooltip2:AddLine (apiInfo.desc)
|
||||
GameCooltip2:ShowCooltip()
|
||||
end
|
||||
@@ -247,7 +247,7 @@ function Details:CreateAPI2Frame()
|
||||
|
||||
local parameterOnEnter = function(self)
|
||||
GameCooltip2:Preset(2)
|
||||
GameCooltip2:SetOwner (self)
|
||||
GameCooltip2:SetOwner(self)
|
||||
|
||||
--fill the box in the right with information about the API
|
||||
local apiInfo = api [currentSelected]
|
||||
@@ -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)
|
||||
tinsert(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)
|
||||
tinsert(returnLines, f)
|
||||
end
|
||||
|
||||
function Api2Frame.Refresh()
|
||||
|
||||
@@ -19,7 +19,7 @@ local libwindow = LibStub("LibWindow-1.1")
|
||||
local f = CreateFrame("frame", "DetailsBenchmark", UIParent,"BackdropTemplate")
|
||||
f:SetSize(800, 600)
|
||||
f:SetPoint("left", UIParent, "left")
|
||||
f:SetFrameStrata ("LOW")
|
||||
f:SetFrameStrata("LOW")
|
||||
f:EnableMouse (true)
|
||||
f:SetMovable (true)
|
||||
f:SetBackdrop({edgeFile = [[Interface\Buttons\WHITE8X8]], edgeSize = 1, bgFile = [[Interface\Tooltips\UI-Tooltip-Background]], tileSize = 64, tile = true})
|
||||
|
||||
@@ -38,7 +38,7 @@ function Details:OpenBookmarkConfig()
|
||||
panel.selecting_slot = id
|
||||
GameCooltip:Reset()
|
||||
GameCooltip:SetType (3)
|
||||
GameCooltip:SetOwner (self)
|
||||
GameCooltip:SetOwner(self)
|
||||
Details:MontaAtributosOption (Details:GetInstance(1), select_attribute)
|
||||
GameCooltip:SetColor (1, cooltip_color)
|
||||
GameCooltip:SetColor (2, cooltip_color)
|
||||
@@ -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})
|
||||
tinsert(panel.blocks, {icon = icon, label = label, bg = set.bg, button = set})
|
||||
end
|
||||
|
||||
local normal_coords = {0, 1, 0, 1}
|
||||
|
||||
@@ -60,7 +60,7 @@ function Details:OpenBrokerTextEditor()
|
||||
|
||||
local optiontable = {"{dmg}", "{dps}", "{dpos}", "{ddiff}", "{heal}", "{hps}", "{hpos}", "{hdiff}", "{time}"}
|
||||
|
||||
local add_button = DF:NewButton (panel, nil, "$parentAddButton", nil, 20, 20, function()
|
||||
local add_button = DF:NewButton(panel, nil, "$parentAddButton", nil, 20, 20, function()
|
||||
textentry.editbox:Insert (optiontable [option_selected])
|
||||
end,
|
||||
nil, nil, nil, "<-")
|
||||
@@ -194,17 +194,17 @@ function Details:OpenBrokerTextEditor()
|
||||
panel:Hide()
|
||||
end
|
||||
|
||||
local ok_button = DF:NewButton (panel, nil, "$parentButtonOk", nil, 80, 20, done, nil, nil, nil, Loc ["STRING_OPTIONS_TEXTEDITOR_DONE"], 1)
|
||||
local ok_button = DF:NewButton(panel, nil, "$parentButtonOk", nil, 80, 20, done, nil, nil, nil, Loc ["STRING_OPTIONS_TEXTEDITOR_DONE"], 1)
|
||||
ok_button.tooltip = Loc ["STRING_OPTIONS_TEXTEDITOR_DONE_TOOLTIP"]
|
||||
ok_button:SetPoint("topright", panel, "topright", -12, -174)
|
||||
ok_button:SetTemplate(DF:GetTemplate ("button", "OPTIONS_BUTTON_TEMPLATE"))
|
||||
|
||||
local reset_button = DF:NewButton (panel, nil, "$parentDefaultOk", nil, 80, 20, function() textentry.editbox:SetText("") end, nil, nil, nil, "Reset", 1)
|
||||
local reset_button = DF:NewButton(panel, nil, "$parentDefaultOk", nil, 80, 20, function() textentry.editbox:SetText("") end, nil, nil, nil, "Reset", 1)
|
||||
reset_button.tooltip = Loc ["STRING_OPTIONS_TEXTEDITOR_RESET_TOOLTIP"]
|
||||
reset_button:SetPoint("topright", panel, "topright", -100, -152)
|
||||
reset_button:SetTemplate(DF:GetTemplate ("button", "OPTIONS_BUTTON_TEMPLATE"))
|
||||
|
||||
local cancel_button = DF:NewButton (panel, nil, "$parentDefaultCancel", nil, 80, 20, function() textentry.editbox:SetText(panel.default_text); done(); end, nil, nil, nil, Loc ["STRING_OPTIONS_TEXTEDITOR_CANCEL"], 1)
|
||||
local cancel_button = DF:NewButton(panel, nil, "$parentDefaultCancel", nil, 80, 20, function() textentry.editbox:SetText(panel.default_text); done(); end, nil, nil, nil, Loc ["STRING_OPTIONS_TEXTEDITOR_CANCEL"], 1)
|
||||
cancel_button.tooltip = Loc ["STRING_OPTIONS_TEXTEDITOR_CANCEL_TOOLTIP"]
|
||||
cancel_button:SetPoint("topright", panel, "topright", -100, -174)
|
||||
cancel_button:SetTemplate(DF:GetTemplate ("button", "OPTIONS_BUTTON_TEMPLATE"))
|
||||
|
||||
@@ -44,7 +44,7 @@ function Details:OpenClassColorsConfig()
|
||||
end
|
||||
|
||||
local on_enter = function(self, capsule)
|
||||
--Details:CooltipPreset (1)
|
||||
--Details:CooltipPreset(1)
|
||||
--GameCooltip:AddLine ("right click to reset")
|
||||
--GameCooltip:Show (self)
|
||||
end
|
||||
@@ -88,7 +88,7 @@ function Details:OpenClassColorsConfig()
|
||||
button.my_class = className
|
||||
button:SetHook("OnEnter", on_enter)
|
||||
button:SetHook("OnLeave", on_leave)
|
||||
button:SetClickFunction (reset_color, nil, nil, "RightClick")
|
||||
button:SetClickFunction(reset_color, nil, nil, "RightClick")
|
||||
panel.buttons [className] = button
|
||||
end
|
||||
|
||||
@@ -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})
|
||||
tinsert(result, {label = colorname, value = value, color = colortable, onclick = colorSelected})
|
||||
end
|
||||
|
||||
return result
|
||||
@@ -197,7 +197,7 @@ function Details:OpenClassColorsConfig()
|
||||
deathLogColorsLabel:SetPoint("topleft", panel, "topleft", 5, -265)
|
||||
end
|
||||
|
||||
for class, button in pairs (_G.DetailsClassColorManager.buttons) do
|
||||
for class, button in pairs(_G.DetailsClassColorManager.buttons) do
|
||||
button.my_texture:SetVertexColor (unpack (Details.class_colors [class]))
|
||||
end
|
||||
|
||||
|
||||
@@ -9,8 +9,8 @@ do
|
||||
|
||||
local panel = CreateFrame("frame", "DetailsCopy", UIParent, "ButtonFrameTemplate")
|
||||
panel:SetSize(512, 148)
|
||||
tinsert (UISpecialFrames, "DetailsCopy")
|
||||
panel:SetFrameStrata ("TOOLTIP")
|
||||
tinsert(UISpecialFrames, "DetailsCopy")
|
||||
panel:SetFrameStrata("TOOLTIP")
|
||||
panel:SetPoint("center", UIParent, "center")
|
||||
panel.locked = false
|
||||
panel:SetToplevel (true)
|
||||
|
||||
@@ -658,7 +658,7 @@ function Details:CreateCurrentDpsFrame(parent, name)
|
||||
end
|
||||
|
||||
--frame strata
|
||||
f:SetFrameStrata (_detalhes.realtime_dps_meter.frame_settings.strata)
|
||||
f:SetFrameStrata(_detalhes.realtime_dps_meter.frame_settings.strata)
|
||||
|
||||
--calcule buffer size
|
||||
f.MaxBufferIndex = f.SampleSize * time_fraction * 100 --sample size in seconds * fraction * tick milliseconds
|
||||
@@ -713,8 +713,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)
|
||||
tinsert(f.PlayerTeamBuffer, 1, playerTeamDamageDone)
|
||||
tinsert(f.YellowTeamBuffer, 1, yellowDamageDone)
|
||||
|
||||
--save the current damage amount
|
||||
f.LastPlayerTeamDamage = thisTickPlayerTeamDamage
|
||||
@@ -811,7 +811,7 @@ function Details:CreateCurrentDpsFrame(parent, name)
|
||||
local groupDamageDoneOnThisTick = thisTickGroupDamage - f.LastTickGroupDamage
|
||||
|
||||
--add the damage to buffer
|
||||
tinsert (f.GroupBuffer, 1, groupDamageDoneOnThisTick)
|
||||
tinsert(f.GroupBuffer, 1, groupDamageDoneOnThisTick)
|
||||
|
||||
--save the current damage amount
|
||||
f.LastTickGroupDamage = thisTickGroupDamage
|
||||
|
||||
+53
-53
@@ -193,7 +193,7 @@
|
||||
GameCooltip:Hide()
|
||||
end)
|
||||
|
||||
tinsert (UISpecialFrames, "DetailsCustomPanel")
|
||||
tinsert(UISpecialFrames, "DetailsCustomPanel")
|
||||
|
||||
|
||||
--menu title bar
|
||||
@@ -285,7 +285,7 @@
|
||||
|
||||
DetailsCustomPanel.code4_default = [[
|
||||
local value, top, total, combat, instance = ...
|
||||
return string.format ("%.1f", value/total*100)
|
||||
return string.format("%.1f", value/total*100)
|
||||
]]
|
||||
DetailsCustomPanel.code4 = DetailsCustomPanel.code4_default
|
||||
|
||||
@@ -303,10 +303,10 @@
|
||||
self.author_field:SetText(UnitName ("player") .. "-" .. GetRealmName())
|
||||
self.author_field:Enable()
|
||||
|
||||
self.source_dropdown:Select (1, true)
|
||||
self.source_dropdown:Select(1, true)
|
||||
self.source_field:SetText("")
|
||||
|
||||
self.target_dropdown:Select (1, true)
|
||||
self.target_dropdown:Select(1, true)
|
||||
self.target_field:SetText("")
|
||||
|
||||
self.spellid_entry:SetText("")
|
||||
@@ -377,19 +377,19 @@
|
||||
|
||||
local source = custom_object:GetSource()
|
||||
if (source == "[all]") then
|
||||
self.source_dropdown:Select (1, true)
|
||||
self.source_dropdown:Select(1, true)
|
||||
self.source_field:SetText("")
|
||||
self.source_field:Disable()
|
||||
elseif (source == "[raid]") then
|
||||
self.source_dropdown:Select (2, true)
|
||||
self.source_dropdown:Select(2, true)
|
||||
self.source_field:SetText("")
|
||||
self.source_field:Disable()
|
||||
elseif (source == "[player]") then
|
||||
self.source_dropdown:Select (3, true)
|
||||
self.source_dropdown:Select(3, true)
|
||||
self.source_field:SetText("")
|
||||
self.source_field:Disable()
|
||||
else
|
||||
self.source_dropdown:Select (4, true)
|
||||
self.source_dropdown:Select(4, true)
|
||||
self.source_field:SetText(source)
|
||||
self.source_field:Enable()
|
||||
end
|
||||
@@ -397,23 +397,23 @@
|
||||
local target = custom_object:GetTarget()
|
||||
|
||||
if (not target) then
|
||||
self.target_dropdown:Select (5, true)
|
||||
self.target_dropdown:Select(5, true)
|
||||
self.target_field:SetText("")
|
||||
self.target_field:Disable()
|
||||
elseif (target == "[all]") then
|
||||
self.target_dropdown:Select (1, true)
|
||||
self.target_dropdown:Select(1, true)
|
||||
self.target_field:SetText("")
|
||||
self.target_field:Disable()
|
||||
elseif (target == "[raid]") then
|
||||
self.target_dropdown:Select (2, true)
|
||||
self.target_dropdown:Select(2, true)
|
||||
self.target_field:SetText("")
|
||||
self.target_field:Disable()
|
||||
elseif (target == "[player]") then
|
||||
self.target_dropdown:Select (3, true)
|
||||
self.target_dropdown:Select(3, true)
|
||||
self.target_field:SetText("")
|
||||
self.target_field:Disable()
|
||||
else
|
||||
self.target_dropdown:Select (4, true)
|
||||
self.target_dropdown:Select(4, true)
|
||||
self.target_field:SetText(target)
|
||||
self.target_field:Enable()
|
||||
end
|
||||
@@ -486,7 +486,7 @@
|
||||
end
|
||||
|
||||
if (DetailsCustomPanel.IsImporting) then
|
||||
tinsert (_detalhes.custom, object)
|
||||
tinsert(_detalhes.custom, object)
|
||||
end
|
||||
|
||||
DetailsCustomPanel.IsEditing = false
|
||||
@@ -507,7 +507,7 @@
|
||||
["tooltip"] = false,
|
||||
}
|
||||
|
||||
tinsert (_detalhes.custom, new_custom_object)
|
||||
tinsert(_detalhes.custom, new_custom_object)
|
||||
_setmetatable (new_custom_object, _detalhes.atributo_custom)
|
||||
new_custom_object.__index = _detalhes.atributo_custom
|
||||
_detalhes:Msg (Loc ["STRING_CUSTOM_CREATED"])
|
||||
@@ -554,7 +554,7 @@
|
||||
end
|
||||
|
||||
if (DetailsCustomPanel.IsImporting) then
|
||||
tinsert (_detalhes.custom, object)
|
||||
tinsert(_detalhes.custom, object)
|
||||
end
|
||||
|
||||
DetailsCustomPanel.IsEditing = false
|
||||
@@ -590,7 +590,7 @@
|
||||
new_custom_object.percent_script = false
|
||||
end
|
||||
|
||||
tinsert (_detalhes.custom, new_custom_object)
|
||||
tinsert(_detalhes.custom, new_custom_object)
|
||||
_setmetatable (new_custom_object, _detalhes.atributo_custom)
|
||||
new_custom_object.__index = _detalhes.atributo_custom
|
||||
_detalhes:Msg (Loc ["STRING_CUSTOM_CREATED"])
|
||||
@@ -752,7 +752,7 @@
|
||||
function custom_window:CreateMenuButton (label, icon, clickfunc, param1, param2, tooltip, name, coords)
|
||||
local index = #custom_window.menu+1
|
||||
|
||||
local button = gump:NewButton (self, nil, "$parent" .. name, nil, CONST_MENU_WIDTH, CONST_MENU_HEIGHT, clickfunc, param1, param2, nil, label)
|
||||
local button = gump:NewButton(self, nil, "$parent" .. name, nil, CONST_MENU_WIDTH, CONST_MENU_HEIGHT, clickfunc, param1, param2, nil, label)
|
||||
button:SetPoint("topleft", self, "topleft", CONST_MENU_X_POSITION, CONST_MENU_Y_POSITION + ((index-1)*-23))
|
||||
|
||||
--button:SetTemplate (CONST_BUTTON_TEMPLATE)
|
||||
@@ -811,7 +811,7 @@
|
||||
|
||||
local export_object = {}
|
||||
|
||||
for key, value in pairs (custom_object) do
|
||||
for key, value in pairs(custom_object) do
|
||||
if (object_keys [key]) then
|
||||
if (type(value) == "table") then
|
||||
export_object [key] = Details.CopyTable (value)
|
||||
@@ -906,7 +906,7 @@
|
||||
custom_window.ImportConfirm:Hide()
|
||||
end
|
||||
|
||||
local okey_button = gump:NewButton (custom_window, nil, "$parentImportConfirm", "ImportConfirm", CONST_EDITBOX_BUTTON_WIDTH, CONST_EDITBOX_BUTTON_HEIGHT, import, nil, nil, nil, Loc ["STRING_CUSTOM_IMPORT_BUTTON"])
|
||||
local okey_button = gump:NewButton(custom_window, nil, "$parentImportConfirm", "ImportConfirm", CONST_EDITBOX_BUTTON_WIDTH, CONST_EDITBOX_BUTTON_HEIGHT, import, nil, nil, nil, Loc ["STRING_CUSTOM_IMPORT_BUTTON"])
|
||||
okey_button:SetTemplate (CONST_BUTTON_TEMPLATE)
|
||||
okey_button:SetPoint("left", editbox, "right", 2, 0)
|
||||
end
|
||||
@@ -1072,20 +1072,20 @@
|
||||
gump:IconPick (pickicon_callback, true)
|
||||
end
|
||||
local icon_image = gump:NewImage (box0, [[Interface\ICONS\TEMP]], 20, 20, nil, nil, "icontexture", "$parentIconTexture")
|
||||
local icon_button = gump:NewButton (box0, nil, "$parentIconButton", "IconButton", 20, 20, pickicon)
|
||||
local icon_button = gump:NewButton(box0, nil, "$parentIconButton", "IconButton", 20, 20, pickicon)
|
||||
icon_button:InstallCustomTexture()
|
||||
icon_button:SetPoint("left", icon_label, "left", 64, 0)
|
||||
icon_image:SetPoint("left", icon_label, "left", 64, 0)
|
||||
custom_window.icon_image = icon_image
|
||||
|
||||
--cancel
|
||||
local cancel_button = gump:NewButton (box0, nil, "$parentCancelButton", "cancelbutton", 130, 20, DetailsCustomPanel.CancelFunc, nil, nil, nil, Loc ["STRING_CUSTOM_CANCEL"])
|
||||
local cancel_button = gump:NewButton(box0, nil, "$parentCancelButton", "cancelbutton", 130, 20, DetailsCustomPanel.CancelFunc, nil, nil, nil, Loc ["STRING_CUSTOM_CANCEL"])
|
||||
--cancel_button:SetPoint("bottomleft", attribute_box, "bottomleft", 2, 0)
|
||||
cancel_button:SetPoint("topleft", icon_label, "bottomleft", 0, -10)
|
||||
cancel_button:SetTemplate (CONST_REGULAR_BUTTON_TEMPLATE)
|
||||
|
||||
--accept
|
||||
local accept_button = gump:NewButton (box0, nil, "$parentAcceptButton", "acceptbutton", 130, 20, DetailsCustomPanel.AcceptFunc, nil, nil, nil, Loc ["STRING_CUSTOM_CREATE"])
|
||||
local accept_button = gump:NewButton(box0, nil, "$parentAcceptButton", "acceptbutton", 130, 20, DetailsCustomPanel.AcceptFunc, nil, nil, nil, Loc ["STRING_CUSTOM_CREATE"])
|
||||
accept_button:SetPoint("left", cancel_button, "right", 2, 0)
|
||||
accept_button:SetTemplate (CONST_REGULAR_BUTTON_TEMPLATE)
|
||||
|
||||
@@ -1168,7 +1168,7 @@
|
||||
|
||||
local selectedEncounterActor = function(actorName, model)
|
||||
source_field:SetText(actorName)
|
||||
source_dropdown:Select (4, true)
|
||||
source_dropdown:Select(4, true)
|
||||
box1.sourceentry:Enable()
|
||||
actorsFrame:Hide()
|
||||
GameCooltip:Hide()
|
||||
@@ -1180,7 +1180,7 @@
|
||||
button.MyObject.image:SetBlendMode("ADD")
|
||||
button.MyObject.line:SetBlendMode("ADD")
|
||||
button.MyObject.label:SetTextColor (1, 1, 1, 1)
|
||||
GameTooltip:SetOwner (button, "ANCHOR_TOPLEFT")
|
||||
GameTooltip:SetOwner(button, "ANCHOR_TOPLEFT")
|
||||
GameTooltip:AddLine (button.MyObject.actor)
|
||||
GameTooltip:Show()
|
||||
|
||||
@@ -1216,12 +1216,12 @@
|
||||
local y = 10
|
||||
local i = 1
|
||||
|
||||
for actor, actorTable in pairs (actors) do
|
||||
for actor, actorTable in pairs(actors) do
|
||||
|
||||
local thisButton = actorsFrameButtons [i]
|
||||
|
||||
if (not thisButton) then
|
||||
thisButton = gump:NewButton (actorsFrame.frame, actorsFrame.frame, "DetailsCustomActorsFrame2Button"..i, "button"..i, 130, 20, selectedEncounterSpell)
|
||||
thisButton = gump:NewButton(actorsFrame.frame, actorsFrame.frame, "DetailsCustomActorsFrame2Button"..i, "button"..i, 130, 20, selectedEncounterSpell)
|
||||
thisButton:SetPoint("topleft", "DetailsCustomActorsFrame2", "topleft", x, -y)
|
||||
thisButton:SetHook("OnEnter", buttonMouseOver)
|
||||
thisButton:SetHook("OnLeave", buttonMouseOut)
|
||||
@@ -1258,7 +1258,7 @@
|
||||
end
|
||||
|
||||
thisButton.label:SetText(actor)
|
||||
thisButton:SetClickFunction (selectedEncounterActor, actor, actorTable.model)
|
||||
thisButton:SetClickFunction(selectedEncounterActor, actor, actorTable.model)
|
||||
thisButton.actor = actor
|
||||
thisButton.ej_id = ej_id
|
||||
thisButton.model = actorTable.model
|
||||
@@ -1280,9 +1280,9 @@
|
||||
|
||||
GameCooltip:Reset()
|
||||
GameCooltip:SetType ("menu")
|
||||
GameCooltip:SetOwner (adds_boss)
|
||||
GameCooltip:SetOwner(adds_boss)
|
||||
|
||||
for instanceId, instanceTable in pairs (_detalhes.EncounterInformation) do
|
||||
for instanceId, instanceTable in pairs(_detalhes.EncounterInformation) do
|
||||
|
||||
if (_detalhes:InstanceIsRaid (instanceId)) then
|
||||
|
||||
@@ -1376,7 +1376,7 @@
|
||||
|
||||
local selectedEncounterActor = function(actorName)
|
||||
target_field:SetText(actorName)
|
||||
target_dropdown:Select (4, true)
|
||||
target_dropdown:Select(4, true)
|
||||
box1.targetentry:Enable()
|
||||
actorsFrame:Hide()
|
||||
GameCooltip:Hide()
|
||||
@@ -1388,7 +1388,7 @@
|
||||
button.MyObject.image:SetBlendMode("ADD")
|
||||
button.MyObject.line:SetBlendMode("ADD")
|
||||
button.MyObject.label:SetTextColor (1, 1, 1, 1)
|
||||
GameTooltip:SetOwner (button, "ANCHOR_TOPLEFT")
|
||||
GameTooltip:SetOwner(button, "ANCHOR_TOPLEFT")
|
||||
GameTooltip:AddLine (button.MyObject.actor)
|
||||
GameTooltip:Show()
|
||||
|
||||
@@ -1424,12 +1424,12 @@
|
||||
local y = 10
|
||||
local i = 1
|
||||
|
||||
for actor, actorTable in pairs (actors) do
|
||||
for actor, actorTable in pairs(actors) do
|
||||
|
||||
local thisButton = actorsFrameButtons [i]
|
||||
|
||||
if (not thisButton) then
|
||||
thisButton = gump:NewButton (actorsFrame.frame, actorsFrame.frame, "DetailsCustomActorsFrameButton"..i, "button"..i, 130, 20, selectedEncounterSpell)
|
||||
thisButton = gump:NewButton(actorsFrame.frame, actorsFrame.frame, "DetailsCustomActorsFrameButton"..i, "button"..i, 130, 20, selectedEncounterSpell)
|
||||
thisButton:SetPoint("topleft", "DetailsCustomActorsFrame", "topleft", x, -y)
|
||||
thisButton:SetHook("OnEnter", buttonMouseOver)
|
||||
thisButton:SetHook("OnLeave", buttonMouseOut)
|
||||
@@ -1466,7 +1466,7 @@
|
||||
end
|
||||
|
||||
thisButton.label:SetText(actor)
|
||||
thisButton:SetClickFunction (selectedEncounterActor, actor)
|
||||
thisButton:SetClickFunction(selectedEncounterActor, actor)
|
||||
thisButton.actor = actor
|
||||
thisButton.ej_id = ej_id
|
||||
thisButton.model = actorTable.model
|
||||
@@ -1488,9 +1488,9 @@
|
||||
|
||||
GameCooltip:Reset()
|
||||
GameCooltip:SetType ("menu")
|
||||
GameCooltip:SetOwner (adds_boss)
|
||||
GameCooltip:SetOwner(adds_boss)
|
||||
|
||||
for instanceId, instanceTable in pairs (_detalhes.EncounterInformation) do
|
||||
for instanceId, instanceTable in pairs(_detalhes.EncounterInformation) do
|
||||
|
||||
if (_detalhes:InstanceIsRaid (instanceId)) then
|
||||
|
||||
@@ -1564,7 +1564,7 @@
|
||||
button.MyObject.line:SetBlendMode("ADD")
|
||||
button.MyObject.label:SetTextColor (1, 1, 1, 1)
|
||||
|
||||
GameTooltip:SetOwner (button, "ANCHOR_TOPLEFT")
|
||||
GameTooltip:SetOwner(button, "ANCHOR_TOPLEFT")
|
||||
_detalhes:GameTooltipSetSpellByID (button.MyObject.spellid)
|
||||
GameTooltip:Show()
|
||||
end
|
||||
@@ -1589,12 +1589,12 @@
|
||||
local y = 10
|
||||
local i = 1
|
||||
|
||||
for spell, _ in pairs (spells) do
|
||||
for spell, _ in pairs(spells) do
|
||||
|
||||
local thisButton = spellsFrameButtons [i]
|
||||
|
||||
if (not thisButton) then
|
||||
thisButton = gump:NewButton (spellsFrame.frame, spellsFrame.frame, "DetailsCustomSpellsFrameButton"..i, "button"..i, 80, 20, selectedEncounterSpell)
|
||||
thisButton = gump:NewButton(spellsFrame.frame, spellsFrame.frame, "DetailsCustomSpellsFrameButton"..i, "button"..i, 80, 20, selectedEncounterSpell)
|
||||
thisButton:SetPoint("topleft", "DetailsCustomSpellsFrame", "topleft", x, -y)
|
||||
thisButton:SetHook("OnEnter", buttonMouseOver)
|
||||
thisButton:SetHook("OnLeave", buttonMouseOut)
|
||||
@@ -1629,7 +1629,7 @@
|
||||
local nome_magia, _, icone_magia = _GetSpellInfo(spell)
|
||||
thisButton.image:SetTexture(icone_magia)
|
||||
thisButton.label:SetText(nome_magia)
|
||||
thisButton:SetClickFunction (selectedEncounterSpell, spell)
|
||||
thisButton:SetClickFunction(selectedEncounterSpell, spell)
|
||||
thisButton.spellid = spell
|
||||
thisButton:Show()
|
||||
i = i + 1
|
||||
@@ -1648,9 +1648,9 @@
|
||||
|
||||
GameCooltip:Reset()
|
||||
GameCooltip:SetType ("menu")
|
||||
GameCooltip:SetOwner (spell_id_boss)
|
||||
GameCooltip:SetOwner(spell_id_boss)
|
||||
|
||||
for instanceId, instanceTable in pairs (_detalhes.EncounterInformation) do
|
||||
for instanceId, instanceTable in pairs(_detalhes.EncounterInformation) do
|
||||
|
||||
if (_detalhes:InstanceisRaid (instanceId)) then
|
||||
|
||||
@@ -1699,25 +1699,25 @@
|
||||
box2:SetFrameLevel (box0:GetFrameLevel()+1)
|
||||
|
||||
--edit main code
|
||||
local maincode_button = gump:NewButton (box2, nil, "$parentMainCodeButton", "maiccodebutton", 160, 20, DetailsCustomPanel.StartEditCode, 1, nil, nil, Loc ["STRING_CUSTOM_EDIT_SEARCH_CODE"])
|
||||
local maincode_button = gump:NewButton(box2, nil, "$parentMainCodeButton", "maiccodebutton", 160, 20, DetailsCustomPanel.StartEditCode, 1, nil, nil, Loc ["STRING_CUSTOM_EDIT_SEARCH_CODE"])
|
||||
maincode_button:SetPoint("topleft", custom_window, "topleft", CONST_EDITBUTTONS_X_POSITION, CONST_MENU_Y_POSITION)
|
||||
maincode_button.tooltip = Loc ["STRING_CUSTOM_EDITCODE_DESC"]
|
||||
maincode_button:SetTemplate (CONST_CODETEXTENTRY_OPENCODEBUTTONS_TEMPLATE)
|
||||
|
||||
--edit tooltip code
|
||||
local tooltipcode_button = gump:NewButton (box2, nil, "$parentTooltipCodeButton", "tooltipcodebutton", 160, 20, DetailsCustomPanel.StartEditCode, 2, nil, nil, Loc ["STRING_CUSTOM_EDIT_TOOLTIP_CODE"])
|
||||
local tooltipcode_button = gump:NewButton(box2, nil, "$parentTooltipCodeButton", "tooltipcodebutton", 160, 20, DetailsCustomPanel.StartEditCode, 2, nil, nil, Loc ["STRING_CUSTOM_EDIT_TOOLTIP_CODE"])
|
||||
tooltipcode_button:SetPoint("topleft", maincode_button, "bottomleft", 0, -8)
|
||||
tooltipcode_button.tooltip = Loc ["STRING_CUSTOM_EDITTOOLTIP_DESC"]
|
||||
tooltipcode_button:SetTemplate (CONST_CODETEXTENTRY_OPENCODEBUTTONS_TEMPLATE)
|
||||
|
||||
--edit total code
|
||||
local totalcode_button = gump:NewButton (box2, nil, "$parentTotalCodeButton", "totalcodebutton", 160, 20, DetailsCustomPanel.StartEditCode, 3, nil, nil, "Edit Total Code")
|
||||
local totalcode_button = gump:NewButton(box2, nil, "$parentTotalCodeButton", "totalcodebutton", 160, 20, DetailsCustomPanel.StartEditCode, 3, nil, nil, "Edit Total Code")
|
||||
totalcode_button:SetPoint("topleft", tooltipcode_button, "bottomleft", 0, -8)
|
||||
totalcode_button.tooltip = "This code is responsible for edit the total number shown in the player bar.\n\nThis is not necessary if you want show exactly the value gotten in the search code."
|
||||
totalcode_button:SetTemplate (CONST_CODETEXTENTRY_OPENCODEBUTTONS_TEMPLATE)
|
||||
|
||||
--edit percent code
|
||||
local percentcode_button = gump:NewButton (box2, nil, "$parentPercentCodeButton", "percentcodebutton", 160, 20, DetailsCustomPanel.StartEditCode, 4, nil, nil, "Edit Percent Code")
|
||||
local percentcode_button = gump:NewButton(box2, nil, "$parentPercentCodeButton", "percentcodebutton", 160, 20, DetailsCustomPanel.StartEditCode, 4, nil, nil, "Edit Percent Code")
|
||||
percentcode_button:SetPoint("topleft", totalcode_button, "bottomleft", 0, -8)
|
||||
percentcode_button.tooltip = "Edit the code responsible for the percent number in the player bar.\n\nThis is not required if you want to use simple percentage (comparing with total)."
|
||||
percentcode_button:SetTemplate (CONST_CODETEXTENTRY_OPENCODEBUTTONS_TEMPLATE)
|
||||
@@ -1746,7 +1746,7 @@
|
||||
end)
|
||||
|
||||
--create a background area where the code editor is
|
||||
local codeEditorBackground = gump:NewButton (custom_window, nil, nil, nil, 1, 1, function()end)
|
||||
local codeEditorBackground = gump:NewButton(custom_window, nil, nil, nil, 1, 1, function()end)
|
||||
codeEditorBackground:SetAllPoints(code_editor)
|
||||
codeEditorBackground:SetTemplate (CONST_CODETEXTENTRY_TEMPLATE)
|
||||
|
||||
@@ -1832,23 +1832,23 @@
|
||||
local supportFrame = CreateFrame("frame", "$parentSupportFrame", custom_window)
|
||||
supportFrame:SetFrameLevel (500)
|
||||
|
||||
local expand = gump:NewButton (supportFrame, nil, "$parentExpand", "expandbutton", CONST_EDITBOX_BUTTON_WIDTH, CONST_EDITBOX_BUTTON_HEIGHT, expand_func, 4, nil, nil, "Expand")
|
||||
local expand = gump:NewButton(supportFrame, nil, "$parentExpand", "expandbutton", CONST_EDITBOX_BUTTON_WIDTH, CONST_EDITBOX_BUTTON_HEIGHT, expand_func, 4, nil, nil, "Expand")
|
||||
expand:SetPoint("bottomleft", code_editor, "topleft", 0, 1)
|
||||
expand:SetTemplate (CONST_CODETEXTENTRYBUTTON_TEMPLATE)
|
||||
|
||||
local font_size1 = gump:NewButton (supportFrame, nil, "$parentFont1", "font1button", CONST_EDITBOX_BUTTON_WIDTH, CONST_EDITBOX_BUTTON_HEIGHT, font_change, nil, nil, nil, "Aa")
|
||||
local font_size1 = gump:NewButton(supportFrame, nil, "$parentFont1", "font1button", CONST_EDITBOX_BUTTON_WIDTH, CONST_EDITBOX_BUTTON_HEIGHT, font_change, nil, nil, nil, "Aa")
|
||||
font_size1:SetPoint("left", expand, "right", 2, 0)
|
||||
font_size1:SetTemplate (CONST_CODETEXTENTRYBUTTON_TEMPLATE)
|
||||
|
||||
local font_size2 = gump:NewButton (supportFrame, nil, "$parentFont2", "font2button", CONST_EDITBOX_BUTTON_WIDTH, CONST_EDITBOX_BUTTON_HEIGHT, font_change, true, nil, nil, "aA")
|
||||
local font_size2 = gump:NewButton(supportFrame, nil, "$parentFont2", "font2button", CONST_EDITBOX_BUTTON_WIDTH, CONST_EDITBOX_BUTTON_HEIGHT, font_change, true, nil, nil, "aA")
|
||||
font_size2:SetPoint("left", font_size1, "right", 2, 0)
|
||||
font_size2:SetTemplate (CONST_CODETEXTENTRYBUTTON_TEMPLATE)
|
||||
|
||||
local apply1 = gump:NewButton (supportFrame, nil, "$parentApply", "applybutton", CONST_EDITBOX_BUTTON_WIDTH, CONST_EDITBOX_BUTTON_HEIGHT, apply_code, nil, nil, nil, "Apply")
|
||||
local apply1 = gump:NewButton(supportFrame, nil, "$parentApply", "applybutton", CONST_EDITBOX_BUTTON_WIDTH, CONST_EDITBOX_BUTTON_HEIGHT, apply_code, nil, nil, nil, "Apply")
|
||||
apply1:SetPoint("left", font_size2, "right", 2, 0)
|
||||
apply1:SetTemplate (CONST_CODETEXTENTRYBUTTON_TEMPLATE)
|
||||
|
||||
local open_API = gump:NewButton (supportFrame, nil, "$parentOpenAPI", "openAPIbutton", CONST_EDITBOX_BUTTON_WIDTH, CONST_EDITBOX_BUTTON_HEIGHT, function()end, nil, nil, nil, "API") --_detalhes.OpenAPI - opening the api was cancelling the editing process
|
||||
local open_API = gump:NewButton(supportFrame, nil, "$parentOpenAPI", "openAPIbutton", CONST_EDITBOX_BUTTON_WIDTH, CONST_EDITBOX_BUTTON_HEIGHT, function()end, nil, nil, nil, "API") --_detalhes.OpenAPI - opening the api was cancelling the editing process
|
||||
open_API:SetPoint("left", apply1, "right", 2, 0)
|
||||
open_API:SetTemplate (CONST_CODETEXTENTRYBUTTON_TEMPLATE)
|
||||
|
||||
|
||||
@@ -81,7 +81,7 @@ end
|
||||
function _detalhes:ShowImportWindow (defaultText, confirmFunc, titleText)
|
||||
if (not _G.DetailsExportWindow) then
|
||||
local importWindow = DetailsFramework:CreateSimplePanel (_G.UIParent, 800, 610, "Details! Dump String", "DetailsExportWindow")
|
||||
importWindow:SetFrameStrata ("FULLSCREEN")
|
||||
importWindow:SetFrameStrata("FULLSCREEN")
|
||||
importWindow:SetPoint("center")
|
||||
DetailsFramework:ApplyStandardBackdrop (importWindow, false, 1.2)
|
||||
|
||||
|
||||
@@ -61,7 +61,7 @@ function Details:OpenEventTrackerOptions (from_options_panel)
|
||||
local SharedMedia = _G.LibStub:GetLibrary ("LibSharedMedia-3.0")
|
||||
local textures = SharedMedia:HashTable ("statusbar")
|
||||
local texTable = {}
|
||||
for name, texturePath in pairs (textures) do
|
||||
for name, texturePath in pairs(textures) do
|
||||
texTable [#texTable + 1] = {value = name, label = name, statusbar = texturePath, onclick = set_bar_texture}
|
||||
end
|
||||
table.sort (texTable, function(t1, t2) return t1.label < t2.label end)
|
||||
@@ -267,7 +267,7 @@ function Details:CreateEventTrackerFrame(parent, name)
|
||||
left_resize:SetScript("OnMouseDown", function(self)
|
||||
if (not f.resizing and not _detalhes.event_tracker.frame.locked) then
|
||||
f.resizing = true
|
||||
f:StartSizing ("bottomleft")
|
||||
f:StartSizing("bottomleft")
|
||||
end
|
||||
end)
|
||||
left_resize:SetScript("OnMouseUp", function(self)
|
||||
@@ -281,7 +281,7 @@ function Details:CreateEventTrackerFrame(parent, name)
|
||||
right_resize:SetScript("OnMouseDown", function(self)
|
||||
if (not f.resizing and not _detalhes.event_tracker.frame.locked) then
|
||||
f.resizing = true
|
||||
f:StartSizing ("bottomright")
|
||||
f:StartSizing("bottomright")
|
||||
end
|
||||
end)
|
||||
right_resize:SetScript("OnMouseUp", function(self)
|
||||
@@ -705,7 +705,7 @@ function Details:CreateEventTrackerFrame(parent, name)
|
||||
f:SetBackdropColor(unpack (_detalhes.event_tracker.frame.backdrop_color))
|
||||
scrollframe.__background:SetVertexColor (unpack (_detalhes.event_tracker.frame.backdrop_color))
|
||||
|
||||
f:SetFrameStrata (_detalhes.event_tracker.frame.strata)
|
||||
f:SetFrameStrata(_detalhes.event_tracker.frame.strata)
|
||||
|
||||
_detalhes:UpdateWorldTrackerLines()
|
||||
scrollframe:Refresh()
|
||||
@@ -750,25 +750,25 @@ function Details:CreateEventTrackerFrame(parent, name)
|
||||
|
||||
--defensive cooldown
|
||||
if (token == "SPELL_CAST_SUCCESS" and (cooldownListFromFramework [spellid]) 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})
|
||||
tinsert(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 (attackCooldownsFromFramework [spellid]) 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})
|
||||
tinsert(CurrentShowing, 1, {SPELLTYPE_OFFENSIVE, spellid, caster_name, target_name, time, false, GetTime(), caster_serial, is_enemy (caster_flags), target_serial})
|
||||
added = true
|
||||
|
||||
--crowd control
|
||||
elseif (token == "SPELL_AURA_APPLIED" and (crowdControlFromFramework [spellid])) then
|
||||
--check if isnt a pet
|
||||
if (target_flags and is_player (target_flags)) then
|
||||
tinsert (CurrentShowing, 1, {SPELLTYPE_CROWDCONTROL, spellid, caster_name, target_name, time, false, GetTime(), caster_serial, is_enemy (caster_flags), target_serial})
|
||||
tinsert(CurrentShowing, 1, {SPELLTYPE_CROWDCONTROL, spellid, caster_name, target_name, time, false, GetTime(), caster_serial, is_enemy (caster_flags), target_serial})
|
||||
added = true
|
||||
end
|
||||
|
||||
--spell interrupt
|
||||
elseif (token == "SPELL_INTERRUPT") then
|
||||
tinsert (CurrentShowing, 1, {SPELLTYPE_INTERRUPT, spellid, caster_name, target_name, time, extraSpellID, GetTime(), caster_serial, is_enemy (caster_flags), target_serial})
|
||||
tinsert(CurrentShowing, 1, {SPELLTYPE_INTERRUPT, spellid, caster_name, target_name, time, extraSpellID, GetTime(), caster_serial, is_enemy (caster_flags), target_serial})
|
||||
added = true
|
||||
|
||||
end
|
||||
|
||||
+18
-18
@@ -46,14 +46,14 @@ function Details:OpenForge()
|
||||
--main frame
|
||||
local f = DetailsForgePanel or Details.gump:CreateSimplePanel (UIParent, 960, 600, "Details! " .. L["STRING_SPELLLIST"], "DetailsForgePanel")
|
||||
f:SetPoint("center", UIParent, "center")
|
||||
f:SetFrameStrata ("HIGH")
|
||||
f:SetFrameStrata("HIGH")
|
||||
f:SetToplevel (true)
|
||||
f:SetMovable (true)
|
||||
f.Title:SetTextColor (1, .8, .2)
|
||||
|
||||
local have_plugins_enabled
|
||||
|
||||
for id, instanceTable in pairs (Details.EncounterInformation) do
|
||||
for id, instanceTable in pairs(Details.EncounterInformation) do
|
||||
if (Details.InstancesToStoreData [id]) then
|
||||
have_plugins_enabled = true
|
||||
break
|
||||
@@ -70,10 +70,10 @@ function Details:OpenForge()
|
||||
nopluginLabel:SetText(L["STRING_FORGE_ENABLEPLUGINS"])
|
||||
end
|
||||
|
||||
if (not Details:GetTutorialCVar ("FORGE_TUTORIAL") and false) then
|
||||
if (not Details:GetTutorialCVar("FORGE_TUTORIAL") and false) then
|
||||
local tutorialFrame = CreateFrame("frame", "$parentTutorialFrame", f,"BackdropTemplate")
|
||||
tutorialFrame:SetPoint("center", f, "center")
|
||||
tutorialFrame:SetFrameStrata ("DIALOG")
|
||||
tutorialFrame:SetFrameStrata("DIALOG")
|
||||
tutorialFrame:SetSize(400, 300)
|
||||
tutorialFrame:SetBackdrop({bgFile = [[Interface\AddOns\Details\images\background]], tile = true, tileSize = 16,
|
||||
insets = {left = 0, right = 0, top = 0, bottom = 0}, edgeFile = [[Interface\Buttons\WHITE8X8]], edgeSize=1})
|
||||
@@ -151,7 +151,7 @@ function Details:OpenForge()
|
||||
|
||||
function f:InstallModule (module)
|
||||
if (module and type (module) == "table") then
|
||||
tinsert (all_modules, module)
|
||||
tinsert(all_modules, module)
|
||||
end
|
||||
end
|
||||
|
||||
@@ -439,7 +439,7 @@ function Details:OpenForge()
|
||||
wipe (spell_already_added)
|
||||
|
||||
local SpellPoll = Details.spell_pool
|
||||
for spellID, className in pairs (SpellPoll) do
|
||||
for spellID, className in pairs(SpellPoll) do
|
||||
|
||||
if (type(spellID) == "number" and spellID > 12) then
|
||||
|
||||
@@ -477,7 +477,7 @@ function Details:OpenForge()
|
||||
end
|
||||
|
||||
if (can_add) then
|
||||
tinsert (t, {spellID, Details.classid_to_classstring [className] or className})
|
||||
tinsert(t, {spellID, Details.classid_to_classstring [className] or className})
|
||||
end
|
||||
|
||||
end
|
||||
@@ -488,7 +488,7 @@ function Details:OpenForge()
|
||||
header = {
|
||||
{name = L["STRING_FORGE_HEADER_INDEX"], width = 40, type = "text", func = no_func},
|
||||
{name = L["STRING_FORGE_HEADER_ICON"], width = 40, type = "texture"},
|
||||
{name = L["STRING_FORGE_HEADER_NAME"], width = 150, type = "entry", func = no_func, onenter = function(self) GameTooltip:SetOwner (self.widget, "ANCHOR_TOPLEFT"); Details:GameTooltipSetSpellByID (self.id); GameTooltip:Show() end, onleave = function(self) GameTooltip:Hide() end},
|
||||
{name = L["STRING_FORGE_HEADER_NAME"], width = 150, type = "entry", func = no_func, onenter = function(self) GameTooltip:SetOwner(self.widget, "ANCHOR_TOPLEFT"); Details:GameTooltipSetSpellByID (self.id); GameTooltip:Show() end, onleave = function(self) GameTooltip:Hide() end},
|
||||
{name = L["STRING_FORGE_HEADER_SPELLID"], width = 60, type = "entry", func = no_func},
|
||||
{name = L["STRING_FORGE_HEADER_SCHOOL"], width = 60, type = "entry", func = no_func},
|
||||
{name = L["STRING_FORGE_HEADER_CASTER"], width = 100, type = "entry", func = no_func},
|
||||
@@ -503,7 +503,7 @@ function Details:OpenForge()
|
||||
if (data) then
|
||||
local events = ""
|
||||
if (EncounterSpellEvents and EncounterSpellEvents [data[1]]) then
|
||||
for token, _ in pairs (EncounterSpellEvents [data[1]].token) do
|
||||
for token, _ in pairs(EncounterSpellEvents [data[1]].token) do
|
||||
token = token:gsub ("SPELL_", "")
|
||||
events = events .. token .. ", "
|
||||
end
|
||||
@@ -582,7 +582,7 @@ function Details:OpenForge()
|
||||
wipe (spell_already_added)
|
||||
|
||||
local SpellPoll = Details.encounter_spell_pool
|
||||
for spellID, spellTable in pairs (SpellPoll) do
|
||||
for spellID, spellTable in pairs(SpellPoll) do
|
||||
if (spellID > 12) then
|
||||
|
||||
local encounterID = spellTable [1]
|
||||
@@ -622,7 +622,7 @@ function Details:OpenForge()
|
||||
end
|
||||
|
||||
if (can_add) then
|
||||
tinsert (t, {spellID, encounterID, enemyName, bossDetails and bossDetails.boss or "--x--x--"})
|
||||
tinsert(t, {spellID, encounterID, enemyName, bossDetails and bossDetails.boss or "--x--x--"})
|
||||
end
|
||||
end
|
||||
end
|
||||
@@ -633,7 +633,7 @@ function Details:OpenForge()
|
||||
header = {
|
||||
{name = L["STRING_FORGE_HEADER_INDEX"], width = 40, type = "text", func = no_func},
|
||||
{name = L["STRING_FORGE_HEADER_ICON"], width = 40, type = "texture"},
|
||||
{name = L["STRING_FORGE_HEADER_NAME"], width = 151, type = "entry", func = no_func, onenter = function(self) GameTooltip:SetOwner (self.widget, "ANCHOR_TOPLEFT"); Details:GameTooltipSetSpellByID (self.id); GameTooltip:Show() end, onleave = function(self) GameTooltip:Hide() end},
|
||||
{name = L["STRING_FORGE_HEADER_NAME"], width = 151, type = "entry", func = no_func, onenter = function(self) GameTooltip:SetOwner(self.widget, "ANCHOR_TOPLEFT"); Details:GameTooltipSetSpellByID (self.id); GameTooltip:Show() end, onleave = function(self) GameTooltip:Hide() end},
|
||||
{name = L["STRING_FORGE_HEADER_SPELLID"], width = 55, type = "entry", func = no_func},
|
||||
{name = L["STRING_FORGE_HEADER_SCHOOL"], width = 60, type = "entry", func = no_func},
|
||||
{name = L["STRING_FORGE_HEADER_CASTER"], width = 80, type = "entry", func = no_func},
|
||||
@@ -650,7 +650,7 @@ function Details:OpenForge()
|
||||
|
||||
local events = ""
|
||||
if (EncounterSpellEvents and EncounterSpellEvents [data[1]]) then
|
||||
for token, _ in pairs (EncounterSpellEvents [data[1]].token) do
|
||||
for token, _ in pairs(EncounterSpellEvents [data[1]].token) do
|
||||
token = token:gsub ("SPELL_", "")
|
||||
events = events .. token .. ", "
|
||||
end
|
||||
@@ -825,7 +825,7 @@ function Details:OpenForge()
|
||||
|
||||
local source = Details.boss_mods_timers.encounter_timers_dbm or {}
|
||||
|
||||
for key, timer in pairs (source) do
|
||||
for key, timer in pairs(source) do
|
||||
local can_add = true
|
||||
if (lower_FilterBarName ~= "") then
|
||||
if (not lower (timer [3]):find (lower_FilterBarName)) then
|
||||
@@ -852,7 +852,7 @@ function Details:OpenForge()
|
||||
header = {
|
||||
{name = L["STRING_FORGE_HEADER_INDEX"], width = 40, type = "text", func = no_func},
|
||||
{name = L["STRING_FORGE_HEADER_ICON"], width = 40, type = "texture"},
|
||||
{name = L["STRING_FORGE_HEADER_BARTEXT"], width = 150, type = "entry", func = no_func, onenter = function(self) GameTooltip:SetOwner (self.widget, "ANCHOR_TOPLEFT"); Details:GameTooltipSetSpellByID (self.id); GameTooltip:Show() end, onleave = function(self) GameTooltip:Hide() end},
|
||||
{name = L["STRING_FORGE_HEADER_BARTEXT"], width = 150, type = "entry", func = no_func, onenter = function(self) GameTooltip:SetOwner(self.widget, "ANCHOR_TOPLEFT"); Details:GameTooltipSetSpellByID (self.id); GameTooltip:Show() end, onleave = function(self) GameTooltip:Hide() end},
|
||||
{name = L["STRING_FORGE_HEADER_ID"], width = 130, type = "entry", func = no_func},
|
||||
{name = L["STRING_FORGE_HEADER_SPELLID"], width = 50, type = "entry", func = no_func},
|
||||
{name = L["STRING_FORGE_HEADER_TIMER"], width = 40, type = "entry", func = no_func},
|
||||
@@ -958,7 +958,7 @@ function Details:OpenForge()
|
||||
|
||||
|
||||
local source = Details.boss_mods_timers.encounter_timers_bw or {}
|
||||
for key, timer in pairs (source) do
|
||||
for key, timer in pairs(source) do
|
||||
local can_add = true
|
||||
if (lower_FilterBarName ~= "") then
|
||||
if (not lower (timer [3]):find (lower_FilterBarName)) then
|
||||
@@ -985,7 +985,7 @@ function Details:OpenForge()
|
||||
header = {
|
||||
{name = L["STRING_FORGE_HEADER_INDEX"], width = 40, type = "text", func = no_func},
|
||||
{name = L["STRING_FORGE_HEADER_ICON"], width = 40, type = "texture"},
|
||||
{name = L["STRING_FORGE_HEADER_BARTEXT"], width = 200, type = "entry", func = no_func, onenter = function(self) GameTooltip:SetOwner (self.widget, "ANCHOR_TOPLEFT"); Details:GameTooltipSetSpellByID (self.id); GameTooltip:Show() end, onleave = function(self) GameTooltip:Hide() end},
|
||||
{name = L["STRING_FORGE_HEADER_BARTEXT"], width = 200, type = "entry", func = no_func, onenter = function(self) GameTooltip:SetOwner(self.widget, "ANCHOR_TOPLEFT"); Details:GameTooltipSetSpellByID (self.id); GameTooltip:Show() end, onleave = function(self) GameTooltip:Hide() end},
|
||||
{name = L["STRING_FORGE_HEADER_SPELLID"], width = 50, type = "entry", func = no_func},
|
||||
{name = L["STRING_FORGE_HEADER_TIMER"], width = 40, type = "entry", func = no_func},
|
||||
{name = L["STRING_FORGE_HEADER_ENCOUNTERID"], width = 80, type = "entry", func = no_func},
|
||||
@@ -1127,7 +1127,7 @@ function Details:OpenForge()
|
||||
end
|
||||
|
||||
lastButton = b
|
||||
tinsert (buttons, b)
|
||||
tinsert(buttons, b)
|
||||
end
|
||||
|
||||
select_module (nil, nil, 1)
|
||||
|
||||
+235
-267
File diff suppressed because it is too large
Load Diff
@@ -124,7 +124,7 @@ function Details:CreateOrOpenNewsWindow()
|
||||
frameUpper:SetVerticalScroll (self:GetValue())
|
||||
end)
|
||||
|
||||
frameUpper:EnableMouseWheel (true)
|
||||
frameUpper:EnableMouseWheel(true)
|
||||
frameUpper:SetScript("OnMouseWheel", function(self, delta)
|
||||
local current = slider:GetValue()
|
||||
if (IsShiftKeyDown() and (delta > 0)) then
|
||||
|
||||
@@ -754,7 +754,7 @@ do
|
||||
|
||||
local buildSkinMenu = function()
|
||||
local skinOptions = {}
|
||||
for skin_name, skin_table in pairs (_detalhes.skins) do
|
||||
for skin_name, skin_table in pairs(_detalhes.skins) do
|
||||
local file = skin_table.file:gsub ([[Interface\AddOns\Details\images\skins\]], "")
|
||||
local desc = "Author: |cFFFFFFFF" .. skin_table.author .. "|r\nVersion: |cFFFFFFFF" .. skin_table.version .. "|r\nSite: |cFFFFFFFF" .. skin_table.site .. "|r\n\nDesc: |cFFFFFFFF" .. skin_table.desc .. "|r\n\nFile: |cFFFFFFFF" .. file .. ".tga|r"
|
||||
skinOptions [#skinOptions+1] = {value = skin_name, label = skin_name, onclick = onSelectSkin, icon = "Interface\\GossipFrame\\TabardGossipIcon", desc = desc}
|
||||
@@ -775,7 +775,7 @@ do
|
||||
name = skinName,
|
||||
}
|
||||
|
||||
for key, value in pairs (currentInstance) do
|
||||
for key, value in pairs(currentInstance) do
|
||||
if (_detalhes.instance_defaults[key] ~= nil) then
|
||||
if (type(value) == "table") then
|
||||
savedObject[key] = Details.CopyTable(value)
|
||||
@@ -802,7 +802,7 @@ do
|
||||
instance:ChangeSkin(skin)
|
||||
|
||||
--overwrite all instance parameters with saved ones
|
||||
for key, value in pairs (skinObject) do
|
||||
for key, value in pairs(skinObject) do
|
||||
if (key ~= "skin" and not _detalhes.instance_skin_ignored_values[key]) then
|
||||
if (type(value) == "table") then
|
||||
instance[key] = Details.CopyTable (value)
|
||||
@@ -937,7 +937,7 @@ do
|
||||
values = function()
|
||||
local loadtable = {}
|
||||
for index, _table in ipairs(_detalhes.savedStyles) do
|
||||
tinsert (loadtable, {value = index, label = _table.name, onclick = function() loadSkin(currentInstance, _table) end,
|
||||
tinsert(loadtable, {value = index, label = _table.name, onclick = function() loadSkin(currentInstance, _table) end,
|
||||
icon = "Interface\\GossipFrame\\TabardGossipIcon", iconcolor = {.7, .7, .5, 1}})
|
||||
end
|
||||
return loadtable
|
||||
@@ -954,7 +954,7 @@ do
|
||||
values = function()
|
||||
local loadtable = {}
|
||||
for index, _table in ipairs(_detalhes.savedStyles) do
|
||||
tinsert (loadtable, {value = index, label = _table.name, onclick = function(_, _, index)
|
||||
tinsert(loadtable, {value = index, label = _table.name, onclick = function(_, _, index)
|
||||
table.remove (_detalhes.savedStyles, index)
|
||||
Details.options.SetCurrentInstanceAndRefresh(currentInstance)
|
||||
afterUpdate()
|
||||
@@ -976,7 +976,7 @@ do
|
||||
values = function()
|
||||
local loadtable = {}
|
||||
for index, _table in ipairs(_detalhes.savedStyles) do
|
||||
tinsert (loadtable, {value = index, label = _table.name, onclick = function(_, _, index)
|
||||
tinsert(loadtable, {value = index, label = _table.name, onclick = function(_, _, index)
|
||||
local compressedData = Details:CompressData(_detalhes.savedStyles[index], "print")
|
||||
if (compressedData) then
|
||||
_detalhes:ShowImportWindow(compressedData, nil, "Details! Export Skin")
|
||||
@@ -1148,7 +1148,7 @@ do
|
||||
local buildTextureMenu = function()
|
||||
local textures = SharedMedia:HashTable("statusbar")
|
||||
local texTable = {}
|
||||
for name, texturePath in pairs (textures) do
|
||||
for name, texturePath in pairs(textures) do
|
||||
texTable[#texTable+1] = {value = name, label = name, iconsize = texture_icon_size, statusbar = texturePath, onclick = onSelectTexture, icon = texture_icon, texcoord = texture_texcoord}
|
||||
end
|
||||
table.sort (texTable, function(t1, t2) return t1.label < t2.label end)
|
||||
@@ -1164,7 +1164,7 @@ do
|
||||
local buildTextureMenu2 = function()
|
||||
local textures2 = SharedMedia:HashTable ("statusbar")
|
||||
local texTable2 = {}
|
||||
for name, texturePath in pairs (textures2) do
|
||||
for name, texturePath in pairs(textures2) do
|
||||
texTable2[#texTable2+1] = {value = name, label = name, iconsize = texture_icon_size, statusbar = texturePath, onclick = onSelectTextureBackground, icon = texture_icon, texcoord = texture_texcoord}
|
||||
end
|
||||
table.sort (texTable2, function(t1, t2) return t1.label < t2.label end)
|
||||
@@ -1192,7 +1192,7 @@ do
|
||||
local buildTextureOverlayMenu = function()
|
||||
local textures2 = SharedMedia:HashTable("statusbar")
|
||||
local texTable2 = {}
|
||||
for name, texturePath in pairs (textures2) do
|
||||
for name, texturePath in pairs(textures2) do
|
||||
texTable2[#texTable2+1] = {value = name, label = name, iconsize = texture_icon_size, statusbar = texturePath, onclick = onSelectBarTextureOverlay, icon = texture_icon, texcoord = texture_texcoord}
|
||||
end
|
||||
table.sort(texTable2, function(t1, t2) return t1.label < t2.label end)
|
||||
@@ -1812,7 +1812,7 @@ do
|
||||
local buildFontMenu = function()
|
||||
local fontObjects = SharedMedia:HashTable("font")
|
||||
local fontTable = {}
|
||||
for name, fontPath in pairs (fontObjects) do
|
||||
for name, fontPath in pairs(fontObjects) do
|
||||
fontTable[#fontTable+1] = {value = name, label = name, icon = font_select_icon, texcoord = font_select_texcoord, onclick = onSelectFont, font = fontPath, descfont = name, desc = Loc ["STRING_MUSIC_DETAILS_ROBERTOCARLOS"]}
|
||||
end
|
||||
table.sort (fontTable, function(t1, t2) return t1.label < t2.label end)
|
||||
@@ -2196,7 +2196,7 @@ do
|
||||
local buildFontMenu = function()
|
||||
local fontObjects = SharedMedia:HashTable ("font")
|
||||
local fontTable = {}
|
||||
for name, fontPath in pairs (fontObjects) do
|
||||
for name, fontPath in pairs(fontObjects) do
|
||||
fontTable[#fontTable+1] = {value = name, label = name, icon = font_select_icon, texcoord = font_select_texcoord, onclick = onSelectFont, font = fontPath, descfont = name, desc = Loc ["STRING_MUSIC_DETAILS_ROBERTOCARLOS"]}
|
||||
end
|
||||
table.sort (fontTable, function(t1, t2) return t1.label < t2.label end)
|
||||
@@ -2211,7 +2211,7 @@ do
|
||||
|
||||
local build_font_menu = function()
|
||||
local fonts = {}
|
||||
for name, fontPath in pairs (SharedMedia:HashTable ("font")) do
|
||||
for name, fontPath in pairs(SharedMedia:HashTable ("font")) do
|
||||
fonts [#fonts+1] = {value = name, label = name, icon = font_select_icon, texcoord = font_select_texcoord, onclick = on_select_attribute_font, font = fontPath, descfont = name, desc = "Our thoughts strayed constantly\nAnd without boundary\nThe ringing of the division bell had began."}
|
||||
end
|
||||
table.sort (fonts, function(t1, t2) return t1.label < t2.label end)
|
||||
@@ -2234,7 +2234,7 @@ do
|
||||
local buildTextureCustomTitleBar = function()
|
||||
local textures = SharedMedia:HashTable("statusbar")
|
||||
local texTable = {}
|
||||
for name, texturePath in pairs (textures) do
|
||||
for name, texturePath in pairs(textures) do
|
||||
texTable[#texTable+1] = {value = name, label = name, statusbar = texturePath, onclick = onSelectCustomTitleBarTexture}
|
||||
end
|
||||
table.sort(texTable, function(t1, t2) return t1.label < t2.label end)
|
||||
@@ -2751,7 +2751,7 @@ do
|
||||
|
||||
local buildBackdropMenu = function()
|
||||
local backdropTable = {}
|
||||
for name, backdropPath in pairs (SharedMedia:HashTable ("background")) do
|
||||
for name, backdropPath in pairs(SharedMedia:HashTable ("background")) do
|
||||
backdropTable[#backdropTable+1] = {value = name, label = name, onclick = onBackdropSelect, icon = [[Interface\ITEMSOCKETINGFRAME\UI-EMPTYSOCKET]], iconsize = backdrop_icon_size, iconcolor = backdrop_icon_color}
|
||||
end
|
||||
return backdropTable
|
||||
@@ -3132,9 +3132,9 @@ do
|
||||
local center = instance.StatusBar ["center"].__name
|
||||
local right = instance.StatusBar ["right"].__name
|
||||
|
||||
_G[sectionFrame:GetName() .. "MicroDisplayLeftDropdown"].MyObject:Select (left)
|
||||
_G[sectionFrame:GetName() .. "MicroDisplayCenterDropdown"].MyObject:Select (center)
|
||||
_G[sectionFrame:GetName() .. "MicroDisplayRightDropdown"].MyObject:Select (right)
|
||||
_G[sectionFrame:GetName() .. "MicroDisplayLeftDropdown"].MyObject:Select(left)
|
||||
_G[sectionFrame:GetName() .. "MicroDisplayCenterDropdown"].MyObject:Select(center)
|
||||
_G[sectionFrame:GetName() .. "MicroDisplayRightDropdown"].MyObject:Select(right)
|
||||
|
||||
if (not instance.show_statusbar and instance.micro_displays_side == 2) then
|
||||
sectionFrame.MicroDisplayWarningLabel:Show()
|
||||
@@ -3273,7 +3273,7 @@ do
|
||||
sectionFrame.MicroDisplayRightDropdown.tooltip = Loc ["STRING_OPTIONS_MICRODISPLAYS_DROPDOWN_TOOLTIP"]
|
||||
|
||||
|
||||
local hideLeftMicroFrameButton = DF:NewButton (sectionFrame.MicroDisplayLeftDropdown, _, "$parenthideLeftMicroFrameButton", "hideLeftMicroFrameButton", 22, 22, function(self, button)
|
||||
local hideLeftMicroFrameButton = DF:NewButton(sectionFrame.MicroDisplayLeftDropdown, _, "$parenthideLeftMicroFrameButton", "hideLeftMicroFrameButton", 22, 22, function(self, button)
|
||||
if (currentInstance.StatusBar ["left"].options.isHidden) then
|
||||
_detalhes.StatusBar:SetPlugin (currentInstance, currentInstance.StatusBar ["left"].real_name, "left")
|
||||
else
|
||||
@@ -3298,7 +3298,7 @@ do
|
||||
self:GetNormalTexture():SetBlendMode("BLEND")
|
||||
end)
|
||||
|
||||
local HideCenterMicroFrameButton = DF:NewButton (sectionFrame.MicroDisplayCenterDropdown, _, "$parentHideCenterMicroFrameButton", "HideCenterMicroFrameButton", 22, 22, function(self)
|
||||
local HideCenterMicroFrameButton = DF:NewButton(sectionFrame.MicroDisplayCenterDropdown, _, "$parentHideCenterMicroFrameButton", "HideCenterMicroFrameButton", 22, 22, function(self)
|
||||
if (currentInstance.StatusBar ["center"].options.isHidden) then
|
||||
_detalhes.StatusBar:SetPlugin (currentInstance, currentInstance.StatusBar ["center"].real_name, "center")
|
||||
else
|
||||
@@ -3323,7 +3323,7 @@ do
|
||||
self:GetNormalTexture():SetBlendMode("BLEND")
|
||||
end)
|
||||
|
||||
local HideRightMicroFrameButton = DF:NewButton (sectionFrame.MicroDisplayRightDropdown, _, "$parentHideRightMicroFrameButton", "HideRightMicroFrameButton", 20, 20, function(self)
|
||||
local HideRightMicroFrameButton = DF:NewButton(sectionFrame.MicroDisplayRightDropdown, _, "$parentHideRightMicroFrameButton", "HideRightMicroFrameButton", 20, 20, function(self)
|
||||
if (currentInstance.StatusBar ["right"].options.isHidden) then
|
||||
_detalhes.StatusBar:SetPlugin (currentInstance, currentInstance.StatusBar ["right"].real_name, "right")
|
||||
else
|
||||
@@ -3347,7 +3347,7 @@ do
|
||||
self:GetNormalTexture():SetBlendMode("BLEND")
|
||||
end)
|
||||
|
||||
local configRightMicroFrameButton = DF:NewButton (sectionFrame.MicroDisplayRightDropdown, _, "$parentconfigRightMicroFrameButton", "configRightMicroFrameButton", 18, 18, function(self)
|
||||
local configRightMicroFrameButton = DF:NewButton(sectionFrame.MicroDisplayRightDropdown, _, "$parentconfigRightMicroFrameButton", "configRightMicroFrameButton", 18, 18, function(self)
|
||||
currentInstance.StatusBar ["right"]:Setup()
|
||||
currentInstance.StatusBar ["right"]:Setup()
|
||||
end)
|
||||
@@ -3356,7 +3356,7 @@ do
|
||||
configRightMicroFrameButton:SetHighlightTexture([[Interface\Buttons\UI-OptionsButton]])
|
||||
configRightMicroFrameButton.tooltip = Loc ["STRING_OPTIONS_MICRODISPLAYS_OPTION_TOOLTIP"]
|
||||
|
||||
local configCenterMicroFrameButton = DF:NewButton (sectionFrame.MicroDisplayCenterDropdown, _, "$parentconfigCenterMicroFrameButton", "configCenterMicroFrameButton", 18, 18, function(self)
|
||||
local configCenterMicroFrameButton = DF:NewButton(sectionFrame.MicroDisplayCenterDropdown, _, "$parentconfigCenterMicroFrameButton", "configCenterMicroFrameButton", 18, 18, function(self)
|
||||
currentInstance.StatusBar ["center"]:Setup()
|
||||
currentInstance.StatusBar ["center"]:Setup()
|
||||
end)
|
||||
@@ -3365,7 +3365,7 @@ do
|
||||
configCenterMicroFrameButton:SetHighlightTexture([[Interface\Buttons\UI-OptionsButton]])
|
||||
configCenterMicroFrameButton.tooltip = Loc ["STRING_OPTIONS_MICRODISPLAYS_OPTION_TOOLTIP"]
|
||||
|
||||
local configLeftMicroFrameButton = DF:NewButton (sectionFrame.MicroDisplayLeftDropdown, _, "$parentconfigLeftMicroFrameButton", "configLeftMicroFrameButton", 18, 18, function(self)
|
||||
local configLeftMicroFrameButton = DF:NewButton(sectionFrame.MicroDisplayLeftDropdown, _, "$parentconfigLeftMicroFrameButton", "configLeftMicroFrameButton", 18, 18, function(self)
|
||||
currentInstance.StatusBar ["left"]:Setup()
|
||||
currentInstance.StatusBar ["left"]:Setup()
|
||||
end)
|
||||
@@ -3427,7 +3427,7 @@ do
|
||||
GameCooltip:Preset (2)
|
||||
GameCooltip:AddLine (desc)
|
||||
GameCooltip:SetType ("tooltip")
|
||||
GameCooltip:SetOwner (self, "bottomleft", "topleft", 150, -2)
|
||||
GameCooltip:SetOwner(self, "bottomleft", "topleft", 150, -2)
|
||||
GameCooltip:Show()
|
||||
end
|
||||
end
|
||||
@@ -3436,7 +3436,7 @@ do
|
||||
GameCooltip:Preset (2)
|
||||
GameCooltip:AddLine (self.hasDesc)
|
||||
GameCooltip:SetType ("tooltip")
|
||||
GameCooltip:SetOwner (self, "bottomleft", "topleft", 150, -2)
|
||||
GameCooltip:SetOwner(self, "bottomleft", "topleft", 150, -2)
|
||||
GameCooltip:Show()
|
||||
end
|
||||
end
|
||||
@@ -3508,7 +3508,7 @@ do
|
||||
local installedToolbarPlugins = {}
|
||||
local installedRaidPlugins = {}
|
||||
|
||||
for absName, pluginObject in pairs (allplugins_toolbar) do
|
||||
for absName, pluginObject in pairs(allplugins_toolbar) do
|
||||
|
||||
local bframe = CreateFrame("frame", "OptionsPluginToolbarBG", anchorFrame, "BackdropTemplate")
|
||||
bframe:SetSize(640, 20)
|
||||
@@ -3536,7 +3536,7 @@ do
|
||||
local plugin = _detalhes:GetPlugin (absName)
|
||||
DF:NewSwitch (bframe, _, "$parentToolbarSlider"..i, "toolbarPluginsSlider"..i, 60, 20, _, _, plugin_stable.enabled, nil, nil, nil, nil, options_switch_template)
|
||||
bframe ["toolbarPluginsSlider"..i].PluginName = absName
|
||||
tinsert (anchorFrame.plugin_widgets, bframe ["toolbarPluginsSlider"..i])
|
||||
tinsert(anchorFrame.plugin_widgets, bframe ["toolbarPluginsSlider"..i])
|
||||
bframe ["toolbarPluginsSlider"..i]:SetPoint("topleft", anchorFrame, "topleft", 415, y)
|
||||
bframe ["toolbarPluginsSlider"..i]:SetAsCheckBox()
|
||||
bframe ["toolbarPluginsSlider"..i].OnSwitch = function(self, _, value)
|
||||
@@ -3550,7 +3550,7 @@ do
|
||||
end
|
||||
|
||||
if (pluginObject.OpenOptionsPanel) then
|
||||
DF:NewButton (bframe, nil, "$parentOptionsButton"..i, "OptionsButton"..i, 120, 20, pluginObject.OpenOptionsPanel, nil, nil, nil, Loc ["STRING_OPTIONS_PLUGINS_OPTIONS"], nil, options_button_template)
|
||||
DF:NewButton(bframe, nil, "$parentOptionsButton"..i, "OptionsButton"..i, 120, 20, pluginObject.OpenOptionsPanel, nil, nil, nil, Loc ["STRING_OPTIONS_PLUGINS_OPTIONS"], nil, options_button_template)
|
||||
bframe ["OptionsButton"..i]:SetPoint("topleft", anchorFrame, "topleft", 510, y-0)
|
||||
bframe ["OptionsButton"..i]:SetTextColor (button_color_rgb)
|
||||
bframe ["OptionsButton"..i]:SetIcon ([[Interface\Buttons\UI-OptionsButton]], 14, 14, nil, {0, 1, 0, 1}, nil, 3)
|
||||
@@ -3643,7 +3643,7 @@ do
|
||||
|
||||
local i = 1
|
||||
local allplugins_raid = _detalhes.RaidTables.NameTable
|
||||
for absName, pluginObject in pairs (allplugins_raid) do
|
||||
for absName, pluginObject in pairs(allplugins_raid) do
|
||||
|
||||
local bframe = CreateFrame("frame", "OptionsPluginRaidBG", anchorFrame, "BackdropTemplate")
|
||||
bframe:SetSize(640, 20)
|
||||
@@ -3670,7 +3670,7 @@ do
|
||||
local plugin_stable = _detalhes:GetPluginSavedTable (absName)
|
||||
local plugin = _detalhes:GetPlugin (absName)
|
||||
DF:NewSwitch (bframe, _, "$parentRaidSlider"..i, "raidPluginsSlider"..i, 60, 20, _, _, plugin_stable.enabled, nil, nil, nil, nil, options_switch_template)
|
||||
tinsert (anchorFrame.plugin_widgets, bframe ["raidPluginsSlider"..i])
|
||||
tinsert(anchorFrame.plugin_widgets, bframe ["raidPluginsSlider"..i])
|
||||
bframe ["raidPluginsSlider"..i].PluginName = absName
|
||||
bframe ["raidPluginsSlider"..i]:SetPoint("topleft", anchorFrame, "topleft", 415, y+1)
|
||||
bframe ["raidPluginsSlider"..i]:SetAsCheckBox()
|
||||
@@ -3681,7 +3681,7 @@ do
|
||||
for index, instancia in ipairs(_detalhes.tabela_instancias) do
|
||||
if (instancia.modo == 4) then -- 4 = raid
|
||||
if (instancia:IsEnabled()) then
|
||||
_detalhes:TrocaTabela (instancia, 0, 1, 1, nil, 2)
|
||||
_detalhes:TrocaTabela(instancia, 0, 1, 1, nil, 2)
|
||||
else
|
||||
instancia.modo = 2 -- group mode
|
||||
end
|
||||
@@ -3691,7 +3691,7 @@ do
|
||||
end
|
||||
|
||||
if (pluginObject.OpenOptionsPanel) then
|
||||
DF:NewButton (bframe, nil, "$parentOptionsButton"..i, "OptionsButton"..i, 86, 18, pluginObject.OpenOptionsPanel, nil, nil, nil, Loc ["STRING_OPTIONS_PLUGINS_OPTIONS"], nil, options_button_template)
|
||||
DF:NewButton(bframe, nil, "$parentOptionsButton"..i, "OptionsButton"..i, 86, 18, pluginObject.OpenOptionsPanel, nil, nil, nil, Loc ["STRING_OPTIONS_PLUGINS_OPTIONS"], nil, options_button_template)
|
||||
bframe ["OptionsButton"..i]:SetPoint("topleft", anchorFrame, "topleft", 510, y-0)
|
||||
bframe ["OptionsButton"..i]:SetTextColor (button_color_rgb)
|
||||
bframe ["OptionsButton"..i]:SetIcon ([[Interface\Buttons\UI-OptionsButton]], 14, 14, nil, {0, 1, 0, 1}, nil, 3)
|
||||
@@ -3781,7 +3781,7 @@ do
|
||||
|
||||
local i = 1
|
||||
local allplugins_solo = _detalhes.SoloTables.NameTable
|
||||
for absName, pluginObject in pairs (allplugins_solo) do
|
||||
for absName, pluginObject in pairs(allplugins_solo) do
|
||||
|
||||
local bframe = CreateFrame("frame", "OptionsPluginSoloBG", anchorFrame,"BackdropTemplate")
|
||||
bframe:SetSize(640, 20)
|
||||
@@ -3808,7 +3808,7 @@ do
|
||||
local plugin_stable = _detalhes:GetPluginSavedTable (absName)
|
||||
local plugin = _detalhes:GetPlugin (absName)
|
||||
DF:NewSwitch (bframe, _, "$parentSoloSlider"..i, "soloPluginsSlider"..i, 60, 20, _, _, plugin_stable.enabled, nil, nil, nil, nil, options_switch_template)
|
||||
tinsert (anchorFrame.plugin_widgets, bframe ["soloPluginsSlider"..i])
|
||||
tinsert(anchorFrame.plugin_widgets, bframe ["soloPluginsSlider"..i])
|
||||
bframe ["soloPluginsSlider"..i].PluginName = absName
|
||||
bframe ["soloPluginsSlider"..i]:SetPoint("topleft", anchorFrame, "topleft", 415, y+1)
|
||||
bframe ["soloPluginsSlider"..i]:SetAsCheckBox()
|
||||
@@ -3818,14 +3818,14 @@ do
|
||||
if (not value) then
|
||||
for index, instancia in ipairs(_detalhes.tabela_instancias) do
|
||||
if (instancia.modo == 1 and instancia.baseframe) then -- 1 = solo
|
||||
_detalhes:TrocaTabela (instancia, 0, 1, 1, nil, 2)
|
||||
_detalhes:TrocaTabela(instancia, 0, 1, 1, nil, 2)
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
if (pluginObject.OpenOptionsPanel) then
|
||||
DF:NewButton (bframe, nil, "$parentOptionsButton"..i, "OptionsButton"..i, 86, 18, pluginObject.OpenOptionsPanel, nil, nil, nil, Loc ["STRING_OPTIONS_PLUGINS_OPTIONS"], nil, options_button_template)
|
||||
DF:NewButton(bframe, nil, "$parentOptionsButton"..i, "OptionsButton"..i, 86, 18, pluginObject.OpenOptionsPanel, nil, nil, nil, Loc ["STRING_OPTIONS_PLUGINS_OPTIONS"], nil, options_button_template)
|
||||
bframe ["OptionsButton"..i]:SetPoint("topleft", anchorFrame, "topleft", 510, y-0)
|
||||
bframe ["OptionsButton"..i]:SetTextColor (button_color_rgb)
|
||||
bframe ["OptionsButton"..i]:SetIcon ([[Interface\Buttons\UI-OptionsButton]], 14, 14, nil, {0, 1, 0, 1}, nil, 3)
|
||||
@@ -4111,7 +4111,7 @@ do
|
||||
|
||||
local buildTooltipFontOptions = function()
|
||||
local fonts = {}
|
||||
for name, fontPath in pairs (SharedMedia:HashTable ("font")) do
|
||||
for name, fontPath in pairs(SharedMedia:HashTable ("font")) do
|
||||
|
||||
fonts [#fonts+1] = {value = name, icon = font_select_icon, texcoord = font_select_texcoord, label = name, onclick = on_select_tooltip_font, font = fontPath, descfont = name, desc = "Our thoughts strayed constantly\nAnd without boundary\nThe ringing of the division bell had began."}
|
||||
end
|
||||
@@ -4862,7 +4862,7 @@ do
|
||||
|
||||
local f = CreateFrame("frame", "DetailsLoadWallpaperImage", UIParent, "BackdropTemplate")
|
||||
f:SetPoint("center", UIParent, "center")
|
||||
f:SetFrameStrata ("FULLSCREEN")
|
||||
f:SetFrameStrata("FULLSCREEN")
|
||||
f:SetSize(550, 170)
|
||||
f:EnableMouse (true)
|
||||
f:SetMovable (true)
|
||||
@@ -4887,7 +4887,7 @@ do
|
||||
DF:ApplyStandardBackdrop(f)
|
||||
DF:CreateTitleBar(f, "Load Your Image") --localize-me
|
||||
|
||||
tinsert (_G.UISpecialFrames, "DetailsLoadWallpaperImage")
|
||||
tinsert(_G.UISpecialFrames, "DetailsLoadWallpaperImage")
|
||||
|
||||
local t = f:CreateFontString (nil, "overlay", "GameFontNormal")
|
||||
t:SetText(Loc ["STRING_OPTIONS_WALLPAPER_LOAD_EXCLAMATION"])
|
||||
@@ -4916,7 +4916,7 @@ do
|
||||
_detalhes:OpenOptionsWindow (instance)
|
||||
sectionFrame:UpdateWallpaperInfo()
|
||||
end
|
||||
local okey = DF:NewButton (f, _, "$parentOkeyButton", nil, 105, 20, okey_func, nil, nil, nil, Loc ["STRING_OPTIONS_WALLPAPER_LOAD_OKEY"], 1, options_button_template)
|
||||
local okey = DF:NewButton(f, _, "$parentOkeyButton", nil, 105, 20, okey_func, nil, nil, nil, Loc ["STRING_OPTIONS_WALLPAPER_LOAD_OKEY"], 1, options_button_template)
|
||||
okey:SetPoint("left", editbox.widget, "right", 2, 0)
|
||||
|
||||
local throubleshoot_func = function()
|
||||
@@ -4926,7 +4926,7 @@ do
|
||||
_G.DetailsLoadWallpaperImage.t:SetText(Loc ["STRING_OPTIONS_WALLPAPER_LOAD_EXCLAMATION"])
|
||||
end
|
||||
end
|
||||
local throubleshoot = DF:NewButton (f, _, "$parentThroubleshootButton", nil, 105, 20, throubleshoot_func, nil, nil, nil, Loc ["STRING_OPTIONS_WALLPAPER_LOAD_TROUBLESHOOT"], 1, options_button_template)
|
||||
local throubleshoot = DF:NewButton(f, _, "$parentThroubleshootButton", nil, 105, 20, throubleshoot_func, nil, nil, nil, Loc ["STRING_OPTIONS_WALLPAPER_LOAD_TROUBLESHOOT"], 1, options_button_template)
|
||||
throubleshoot:SetPoint("left", okey, "right", 2, 0)
|
||||
--throubleshoot:InstallCustomTexture()
|
||||
end
|
||||
@@ -5059,14 +5059,14 @@ do
|
||||
local icones = sub_atributo.icones
|
||||
for index, att_name in ipairs(sub_atributo.lista) do
|
||||
local texture, texcoord = unpack (icones [index])
|
||||
tinsert (t, {value = i, label = att_name, onclick = Current_Switch_Func, icon = texture, texcoord = texcoord})
|
||||
tinsert(t, {value = i, label = att_name, onclick = Current_Switch_Func, icon = texture, texcoord = texcoord})
|
||||
sectionFrame.lastSwitchList [i] = {atributo, index, i}
|
||||
i = i + 1
|
||||
end
|
||||
end
|
||||
|
||||
for index, ptable in ipairs(_detalhes.RaidTables.Menu) do
|
||||
tinsert (t, {value = i, label = ptable [1], onclick = Current_Switch_Func, icon = ptable [2]})
|
||||
tinsert(t, {value = i, label = ptable [1], onclick = Current_Switch_Func, icon = ptable [2]})
|
||||
sectionFrame.lastSwitchList [i] = {"raid", ptable [4], i}
|
||||
i = i + 1
|
||||
end
|
||||
@@ -5467,9 +5467,9 @@ do
|
||||
--[=[]]
|
||||
local spec1Table = {}
|
||||
local playerSpecs = DF.ClassSpecIds [select (2, UnitClass("player"))]
|
||||
for specID, _ in pairs (playerSpecs) do
|
||||
for specID, _ in pairs(playerSpecs) do
|
||||
local spec_id, specName, spec_description, spec_icon = GetSpecializationInfoByID(specID)
|
||||
tinsert (spec1Table, {
|
||||
tinsert(spec1Table, {
|
||||
type = "select",
|
||||
get = function()
|
||||
local specProfile = Details.profile_by_spec[specID]
|
||||
@@ -5477,7 +5477,7 @@ do
|
||||
end,
|
||||
values = function()
|
||||
local t = {}
|
||||
for profileName in pairs (__profiles) do
|
||||
for profileName in pairs(__profiles) do
|
||||
t[#t+1] = profileName
|
||||
end
|
||||
return t
|
||||
@@ -5566,7 +5566,7 @@ do --raid tools
|
||||
DF:ApplyStandardBackdrop(f)
|
||||
DF:CreateTitleBar(f, Loc ["STRING_OPTIONS_RT_IGNORE_TITLE"])
|
||||
|
||||
f:SetFrameStrata ("FULLSCREEN")
|
||||
f:SetFrameStrata("FULLSCREEN")
|
||||
f:EnableMouse()
|
||||
f:SetMovable (true)
|
||||
f:SetScript("OnMouseDown", function(self, button)
|
||||
@@ -5630,7 +5630,7 @@ do --raid tools
|
||||
L.switch:SetFixedParameter(1)
|
||||
L.switch:SetValue(false)
|
||||
|
||||
tinsert (f.labels, L)
|
||||
tinsert(f.labels, L)
|
||||
return L
|
||||
end
|
||||
|
||||
@@ -6304,14 +6304,14 @@ do
|
||||
local icon_button_func = function(texture)
|
||||
addframe.spellIconButton.icon.texture = texture
|
||||
end
|
||||
local icon_button = DF:NewButton (addframe, nil, "$parentSpellIconButton", "spellIconButton", 20, 20, function() DF:IconPick (icon_button_func, true) end)
|
||||
local icon_button = DF:NewButton(addframe, nil, "$parentSpellIconButton", "spellIconButton", 20, 20, function() DF:IconPick (icon_button_func, true) end)
|
||||
local icon_button_icon = DF:NewImage (icon_button, [[Interface\ICONS\TEMP]], 19, 19, "background", nil, "icon", "$parentSpellIcon")
|
||||
icon_button_icon:SetPoint(0, 0)
|
||||
icon_button:InstallCustomTexture()
|
||||
icon_button:SetPoint("left", spellicon, "right", 2, 0)
|
||||
|
||||
--close button
|
||||
local closebutton = DF:NewButton (addframe, nil, "$parentAddCloseButton", "addClosebutton", 120, 20, function() addframe:Hide() end, nil, nil, nil, Loc ["STRING_OPTIONS_SPELL_CLOSE"], nil, options_button_template)
|
||||
local closebutton = DF:NewButton(addframe, nil, "$parentAddCloseButton", "addClosebutton", 120, 20, function() addframe:Hide() end, nil, nil, nil, Loc ["STRING_OPTIONS_SPELL_CLOSE"], nil, options_button_template)
|
||||
|
||||
--confirm add spell
|
||||
local addspell = function()
|
||||
@@ -6344,7 +6344,7 @@ do
|
||||
addframe:Hide()
|
||||
end
|
||||
|
||||
local addspellbutton = DF:NewButton (addframe, nil, "$parentAddSpellButton", "addSpellbutton", 120, 20, addspell, nil, nil, nil, Loc ["STRING_OPTIONS_SPELL_ADD"], nil, options_button_template)
|
||||
local addspellbutton = DF:NewButton(addframe, nil, "$parentAddSpellButton", "addSpellbutton", 120, 20, addspell, nil, nil, nil, Loc ["STRING_OPTIONS_SPELL_ADD"], nil, options_button_template)
|
||||
|
||||
addspellbutton:SetIcon ([[Interface\Buttons\UI-CheckBox-Check]], 18, 18, nil, nil, nil, 4)
|
||||
closebutton:SetIcon ([[Interface\PetBattles\DeadPetIcon]], 14, 14, nil, nil, nil, 4)
|
||||
@@ -6360,7 +6360,7 @@ do
|
||||
local add = function()
|
||||
addframe:Show()
|
||||
end
|
||||
local addbutton = DF:NewButton (sectionFrame, nil, "$parentAddButton", "addbutton", 120, 20, add, nil, nil, nil, Loc ["STRING_OPTIONS_SPELL_ADDSPELL"], nil, options_button_template)
|
||||
local addbutton = DF:NewButton(sectionFrame, nil, "$parentAddButton", "addbutton", 120, 20, add, nil, nil, nil, Loc ["STRING_OPTIONS_SPELL_ADDSPELL"], nil, options_button_template)
|
||||
addbutton:SetPoint("bottomright", panel, "topright", -00, 1)
|
||||
addbutton:SetIcon ([[Interface\PaperDollInfoFrame\Character-Plus]], 12, 12, nil, nil, nil, 4)
|
||||
|
||||
@@ -6439,13 +6439,13 @@ do
|
||||
big_code_editor:Hide()
|
||||
end
|
||||
|
||||
local accept_changes = DF:NewButton (big_code_editor, nil, "$parentAccept", "acceptButton", 120, 20, accept, nil, nil)
|
||||
local accept_changes = DF:NewButton(big_code_editor, nil, "$parentAccept", "acceptButton", 120, 20, accept, nil, nil)
|
||||
accept_changes:SetPoint(0, 20)
|
||||
accept_changes:SetIcon([[Interface\Buttons\UI-CheckBox-Check]])
|
||||
accept_changes:SetTemplate(options_button_template)
|
||||
accept_changes:SetText(Loc ["STRING_OPTIONS_CHART_SAVE"])
|
||||
|
||||
local cancel_changes = DF:NewButton (big_code_editor, nil, "$parentCancel", "CancelButton", 120, 20, cancel, nil, nil)
|
||||
local cancel_changes = DF:NewButton(big_code_editor, nil, "$parentCancel", "CancelButton", 120, 20, cancel, nil, nil)
|
||||
cancel_changes:SetPoint("left", accept_changes, "right", 2, 0)
|
||||
cancel_changes:SetIcon([[Interface\PetBattles\DeadPetIcon]])
|
||||
cancel_changes:SetTemplate(options_button_template)
|
||||
@@ -6502,7 +6502,7 @@ do
|
||||
big_code_editor2:Hide()
|
||||
end
|
||||
|
||||
local close_export = DF:NewButton (big_code_editor2, nil, "$parentClose", "closeButton", 120, 20, close_export_box)
|
||||
local close_export = DF:NewButton(big_code_editor2, nil, "$parentClose", "closeButton", 120, 20, close_export_box)
|
||||
close_export:SetPoint(10, 18)
|
||||
close_export:SetIcon ([[Interface\Buttons\UI-CheckBox-Check]])
|
||||
close_export:SetText(Loc ["STRING_OPTIONS_CHART_CLOSE"])
|
||||
@@ -6620,7 +6620,7 @@ do
|
||||
addframe.iconButton.iconTexture = texture
|
||||
addframe.iconButton:SetIcon(texture)
|
||||
end
|
||||
local capture_icon_button = DF:NewButton (addframe, nil, "$parentIconButton", "iconButton", 20, 20, function() DF:IconPick (icon_button_func, true) end, nil, nil, nil, nil, nil, options_button_template)
|
||||
local capture_icon_button = DF:NewButton(addframe, nil, "$parentIconButton", "iconButton", 20, 20, function() DF:IconPick (icon_button_func, true) end, nil, nil, nil, nil, nil, options_button_template)
|
||||
capture_icon_button:SetIcon([[Interface\ICONS\TEMP]])
|
||||
capture_icon_button:SetTemplate(options_button_template)
|
||||
capture_icon_button:SetPoint("left", capture_icon, "right", 2, 0)
|
||||
@@ -6649,7 +6649,7 @@ do
|
||||
end
|
||||
end
|
||||
|
||||
local addbutton = DF:NewButton (sectionFrame, nil, "$parentAddButton", "addbutton", 120, 20, add, nil, nil, nil, Loc ["STRING_OPTIONS_CHART_ADD"], nil, options_button_template)
|
||||
local addbutton = DF:NewButton(sectionFrame, nil, "$parentAddButton", "addbutton", 120, 20, add, nil, nil, nil, Loc ["STRING_OPTIONS_CHART_ADD"], nil, options_button_template)
|
||||
addbutton:SetPoint("bottomright", panel, "topright", -30, 0)
|
||||
addbutton:SetIcon ([[Interface\PaperDollInfoFrame\Character-Plus]], 12, 12, nil, nil, nil, 4)
|
||||
|
||||
@@ -6696,7 +6696,7 @@ do
|
||||
end
|
||||
end
|
||||
|
||||
local accept_import = DF:NewButton (importframe, nil, "$parentAccept", "acceptButton", 120, 20, doimport)
|
||||
local accept_import = DF:NewButton(importframe, nil, "$parentAccept", "acceptButton", 120, 20, doimport)
|
||||
accept_import:SetIcon ([[Interface\Buttons\UI-CheckBox-Check]])
|
||||
accept_import:SetPoint(10, 18)
|
||||
accept_import:SetText(Loc ["STRING_OPTIONS_CHART_IMPORT"])
|
||||
@@ -6707,7 +6707,7 @@ do
|
||||
importframe:Hide()
|
||||
end
|
||||
|
||||
local cancel_changes = DF:NewButton (importframe, nil, "$parentCancel", "CancelButton", 120, 20, cancelimport)
|
||||
local cancel_changes = DF:NewButton(importframe, nil, "$parentCancel", "CancelButton", 120, 20, cancelimport)
|
||||
cancel_changes:SetIcon ([[Interface\PetBattles\DeadPetIcon]])
|
||||
cancel_changes:SetText(Loc ["STRING_OPTIONS_CHART_CANCEL"])
|
||||
cancel_changes:SetPoint(132, 18)
|
||||
@@ -6727,12 +6727,12 @@ do
|
||||
end
|
||||
end
|
||||
|
||||
local importbutton = DF:NewButton (sectionFrame, nil, "$parentImportButton", "importbutton", 120, 20, import, nil, nil, nil, Loc ["STRING_OPTIONS_CHART_IMPORT"], nil, options_button_template)
|
||||
local importbutton = DF:NewButton(sectionFrame, nil, "$parentImportButton", "importbutton", 120, 20, import, nil, nil, nil, Loc ["STRING_OPTIONS_CHART_IMPORT"], nil, options_button_template)
|
||||
importbutton:SetPoint("right", addbutton, "left", -4, 0)
|
||||
importbutton:SetIcon ([[Interface\Buttons\UI-GuildButton-PublicNote-Up]], 14, 14, nil, nil, nil, 4)
|
||||
|
||||
--close button
|
||||
local closebutton = DF:NewButton (addframe, nil, "$parentAddCloseButton", "addClosebutton", 120, 20, function() addframe:Hide() end, nil, nil, nil, Loc ["STRING_OPTIONS_CHART_CLOSE"], nil, options_button_template)
|
||||
local closebutton = DF:NewButton(addframe, nil, "$parentAddCloseButton", "addClosebutton", 120, 20, function() addframe:Hide() end, nil, nil, nil, Loc ["STRING_OPTIONS_CHART_CLOSE"], nil, options_button_template)
|
||||
--closebutton:InstallCustomTexture()
|
||||
|
||||
--confirm add capture
|
||||
@@ -6776,7 +6776,7 @@ do
|
||||
|
||||
end
|
||||
|
||||
local addcapturebutton = DF:NewButton (addframe, nil, "$parentAddCaptureButton", "addCapturebutton", 120, 21, addcapture, nil, nil, nil, Loc ["STRING_OPTIONS_CHART_ADD2"], nil, options_button_template)
|
||||
local addcapturebutton = DF:NewButton(addframe, nil, "$parentAddCaptureButton", "addCapturebutton", 120, 21, addcapture, nil, nil, nil, Loc ["STRING_OPTIONS_CHART_ADD2"], nil, options_button_template)
|
||||
|
||||
--anchors
|
||||
local start = 25
|
||||
|
||||
@@ -45,7 +45,7 @@ function Details.OpenPlaterIntegrationWindow()
|
||||
local build_anchor_side_table = function(member)
|
||||
local t = {}
|
||||
for i = 1, 13 do
|
||||
tinsert (t, {
|
||||
tinsert(t, {
|
||||
label = anchor_names[i],
|
||||
value = i,
|
||||
onclick = function(_, _, value)
|
||||
|
||||
@@ -1015,7 +1015,7 @@ function _detalhes:ApplyPDWSkin (skin_name)
|
||||
--hide extra frames
|
||||
local window = DetailsPlayerDetailsWindow
|
||||
if (window.extra_frames) then
|
||||
for framename, frame in pairs (window.extra_frames) do
|
||||
for framename, frame in pairs(window.extra_frames) do
|
||||
frame:Hide()
|
||||
end
|
||||
end
|
||||
@@ -1610,13 +1610,13 @@ function gump:CriaJanelaInfo()
|
||||
local este_gump = info
|
||||
este_gump.Loaded = true
|
||||
|
||||
este_gump:SetFrameStrata ("HIGH")
|
||||
este_gump:SetFrameStrata("HIGH")
|
||||
este_gump:SetToplevel (true)
|
||||
|
||||
este_gump.extra_frames = {}
|
||||
|
||||
--fehcar com o esc
|
||||
tinsert (UISpecialFrames, este_gump:GetName())
|
||||
tinsert(UISpecialFrames, este_gump:GetName())
|
||||
|
||||
--propriedades da janela
|
||||
este_gump:SetPoint("CENTER", UIParent)
|
||||
@@ -1631,7 +1631,7 @@ function gump:CriaJanelaInfo()
|
||||
este_gump.SummaryWindowWidgets = CreateFrame("frame", "DetailsPlayerDetailsWindowSummaryWidgets", este_gump, "BackdropTemplate")
|
||||
local SWW = este_gump.SummaryWindowWidgets
|
||||
SWW:SetAllPoints()
|
||||
tinsert (SummaryWidgets, SWW)
|
||||
tinsert(SummaryWidgets, SWW)
|
||||
|
||||
local scaleBar = Details.gump:CreateScaleBar (este_gump, Details.player_details_window)
|
||||
este_gump:SetScale(Details.player_details_window.scale)
|
||||
@@ -2250,7 +2250,7 @@ function gump:CriaJanelaInfo()
|
||||
if (self.spellid) then
|
||||
--self:SetBackdrop({bgFile = "Interface\\Tooltips\\UI-Tooltip-Background", tile = true, tileSize = 512, edgeFile = "Interface\\DialogFrame\\UI-DialogBox-Border", edgeSize = 8})
|
||||
self:SetBackdropColor(.5, .5, .5, .5)
|
||||
GameTooltip:SetOwner (self, "ANCHOR_TOPLEFT")
|
||||
GameTooltip:SetOwner(self, "ANCHOR_TOPLEFT")
|
||||
_detalhes:GameTooltipSetSpellByID (self.spellid)
|
||||
GameTooltip:Show()
|
||||
end
|
||||
@@ -2389,7 +2389,7 @@ function gump:CriaJanelaInfo()
|
||||
last_total_dodge = last_actor.avoidance.overall.DODGE / last_combat:GetCombatTime()
|
||||
end
|
||||
local ps, diff = getpercent (totaldodge, last_total_dodge, elapsed_time, true)
|
||||
tab.dodgepersecond:SetText( string.format ("%.2f", ps) .. " (" .. diff .. ")")
|
||||
tab.dodgepersecond:SetText( string.format("%.2f", ps) .. " (" .. diff .. ")")
|
||||
|
||||
--parry
|
||||
local totalparry = playerdamage.avoidance.overall.PARRY
|
||||
@@ -2400,7 +2400,7 @@ function gump:CriaJanelaInfo()
|
||||
last_total_parry = last_actor.avoidance.overall.PARRY / last_combat:GetCombatTime()
|
||||
end
|
||||
local ps, diff = getpercent (totalparry, last_total_parry, elapsed_time, true)
|
||||
tab.parrypersecond:SetText(string.format ("%.2f", ps) .. " (" .. diff .. ")")
|
||||
tab.parrypersecond:SetText(string.format("%.2f", ps) .. " (" .. diff .. ")")
|
||||
|
||||
--block
|
||||
local totalblock = playerdamage.avoidance.overall.BLOCKED_HITS
|
||||
@@ -2411,7 +2411,7 @@ function gump:CriaJanelaInfo()
|
||||
last_total_block = last_actor.avoidance.overall.BLOCKED_HITS / last_combat:GetCombatTime()
|
||||
end
|
||||
local ps, diff = getpercent (totalblock, last_total_block, elapsed_time, true)
|
||||
tab.blockpersecond:SetText(string.format ("%.2f", ps) .. " (" .. diff .. ")")
|
||||
tab.blockpersecond:SetText(string.format("%.2f", ps) .. " (" .. diff .. ")")
|
||||
|
||||
tab.blockeddamage_amt:SetText(_detalhes:ToK2 (playerdamage.avoidance.overall.BLOCKED_AMT))
|
||||
|
||||
@@ -2480,7 +2480,7 @@ function gump:CriaJanelaInfo()
|
||||
local heal_from = actor_heal.healing_from
|
||||
local myReceivedHeal = {}
|
||||
|
||||
for actorName, _ in pairs (heal_from) do
|
||||
for actorName, _ in pairs(heal_from) do
|
||||
local thisActor = combat (2, actorName)
|
||||
local targets = thisActor.targets --targets is a container with target classes
|
||||
local amount = targets [player.nome] or 0
|
||||
@@ -2548,7 +2548,7 @@ function gump:CriaJanelaInfo()
|
||||
|
||||
local cooldowns_usados = {}
|
||||
|
||||
for _spellid, _tabela in pairs (minha_tabela) do
|
||||
for _spellid, _tabela in pairs(minha_tabela) do
|
||||
cooldowns_usados [#cooldowns_usados+1] = {_spellid, _tabela.counter}
|
||||
end
|
||||
|
||||
@@ -2587,7 +2587,7 @@ function gump:CriaJanelaInfo()
|
||||
local cooldownInfo = DetailsFramework.CooldownsInfo
|
||||
|
||||
--see cooldowns that other players used in this actor
|
||||
for playerName, _ in pairs (combat.raid_roster) do
|
||||
for playerName, _ in pairs(combat.raid_roster) do
|
||||
if (playerName ~= player.nome) then
|
||||
local miscPlayer = combat (4, playerName)
|
||||
if (miscPlayer) then
|
||||
@@ -2596,7 +2596,7 @@ function gump:CriaJanelaInfo()
|
||||
for spellID, spellTable in cooldowns:ListActors() do
|
||||
local targets = spellTable.targets
|
||||
if (targets) then
|
||||
for targetName, amountCasted in pairs (targets) do
|
||||
for targetName, amountCasted in pairs(targets) do
|
||||
if (targetName == player.nome) then
|
||||
local spellName, _, spellIcon = _GetSpellInfo(spellID)
|
||||
local label1, label2, icon1, framebg = unpack (tab ["spell" .. index_used])
|
||||
@@ -2701,7 +2701,7 @@ function gump:CriaJanelaInfo()
|
||||
}
|
||||
|
||||
local line_onenter = function(self)
|
||||
GameTooltip:SetOwner (self, "ANCHOR_TOPRIGHT")
|
||||
GameTooltip:SetOwner(self, "ANCHOR_TOPRIGHT")
|
||||
_detalhes:GameTooltipSetSpellByID (self.spellID)
|
||||
GameTooltip:Show()
|
||||
self:SetBackdropColor(1, 1, 1, .2)
|
||||
@@ -2799,7 +2799,7 @@ function gump:CriaJanelaInfo()
|
||||
line.Refresh:SetText(aura [5])
|
||||
|
||||
--if (haveWA) then
|
||||
-- line.WaButton:SetClickFunction (wa_button, aura.spellID, line.AuraType)
|
||||
-- line.WaButton:SetClickFunction(wa_button, aura.spellID, line.AuraType)
|
||||
--else
|
||||
-- line.WaButton:Disable()
|
||||
--end
|
||||
@@ -2820,7 +2820,7 @@ function gump:CriaJanelaInfo()
|
||||
f:SetSize(40, 20)
|
||||
f:SetPoint("center", anchorWidget, "center")
|
||||
f:SetScript("OnEnter", function()
|
||||
GameTooltip:SetOwner (f, "ANCHOR_TOPRIGHT")
|
||||
GameTooltip:SetOwner(f, "ANCHOR_TOPRIGHT")
|
||||
GameTooltip:AddLine (desc)
|
||||
GameTooltip:Show()
|
||||
end)
|
||||
@@ -2897,9 +2897,9 @@ function gump:CriaJanelaInfo()
|
||||
do --buffs
|
||||
local newAuraTable = {}
|
||||
if (miscActor and miscActor.buff_uptime_spells) then
|
||||
for spellID, spellObject in pairs (miscActor.buff_uptime_spells._ActorTable) do
|
||||
for spellID, spellObject in pairs(miscActor.buff_uptime_spells._ActorTable) do
|
||||
local spellName, _, spellIcon = GetSpellInfo(spellID)
|
||||
tinsert (newAuraTable, {spellIcon, spellName, spellObject.uptime, spellObject.appliedamt, spellObject.refreshamt, spellObject.uptime/combatTime*100, spellID = spellID})
|
||||
tinsert(newAuraTable, {spellIcon, spellName, spellObject.uptime, spellObject.appliedamt, spellObject.refreshamt, spellObject.uptime/combatTime*100, spellID = spellID})
|
||||
end
|
||||
end
|
||||
table.sort (newAuraTable, _detalhes.Sort3)
|
||||
@@ -2910,9 +2910,9 @@ function gump:CriaJanelaInfo()
|
||||
do --debuffs
|
||||
local newAuraTable = {}
|
||||
if (miscActor and miscActor.debuff_uptime_spells) then
|
||||
for spellID, spellObject in pairs (miscActor.debuff_uptime_spells._ActorTable) do
|
||||
for spellID, spellObject in pairs(miscActor.debuff_uptime_spells._ActorTable) do
|
||||
local spellName, _, spellIcon = GetSpellInfo(spellID)
|
||||
tinsert (newAuraTable, {spellIcon, spellName, spellObject.uptime, spellObject.appliedamt, spellObject.refreshamt, spellObject.uptime/combatTime*100, spellID = spellID})
|
||||
tinsert(newAuraTable, {spellIcon, spellName, spellObject.uptime, spellObject.appliedamt, spellObject.refreshamt, spellObject.uptime/combatTime*100, spellID = spellID})
|
||||
end
|
||||
end
|
||||
table.sort (newAuraTable, _detalhes.Sort3)
|
||||
@@ -4455,7 +4455,7 @@ function gump:CriaJanelaInfo()
|
||||
bar.righttext2:SetJustifyH("right")
|
||||
bar.righttext2:SetTextColor (1, 1, 1, 1)
|
||||
|
||||
tinsert (parent.bars, {spellicon, bar, {0, 0, 0}})
|
||||
tinsert(parent.bars, {spellicon, bar, {0, 0, 0}})
|
||||
end
|
||||
|
||||
local create_tooltip = function(name)
|
||||
@@ -4467,7 +4467,7 @@ function gump:CriaJanelaInfo()
|
||||
tooltip:SetBackdropColor(0, 0, 0, 1)
|
||||
tooltip:SetBackdropBorderColor(0, 0, 0, 1)
|
||||
tooltip:SetSize(275, 77)
|
||||
tooltip:SetFrameStrata ("tooltip")
|
||||
tooltip:SetFrameStrata("tooltip")
|
||||
|
||||
local y = -3
|
||||
local x_start = 2
|
||||
@@ -4569,7 +4569,7 @@ function gump:CriaJanelaInfo()
|
||||
tooltip:SetBackdropColor(0, 0, 0, 1)
|
||||
tooltip:SetBackdropBorderColor(0, 0, 0, 1)
|
||||
tooltip:SetSize(175, 67)
|
||||
tooltip:SetFrameStrata ("tooltip")
|
||||
tooltip:SetFrameStrata("tooltip")
|
||||
tooltip.bars = {}
|
||||
|
||||
_detalhes.gump:CreateBorder (tooltip)
|
||||
@@ -4661,7 +4661,7 @@ function gump:CriaJanelaInfo()
|
||||
bar.bg = bg_line1
|
||||
|
||||
local object = {spellicon, bar}
|
||||
tinsert (tooltip.bars, object)
|
||||
tinsert(tooltip.bars, object)
|
||||
return object
|
||||
end
|
||||
|
||||
@@ -4903,14 +4903,14 @@ function gump:CriaJanelaInfo()
|
||||
local match_percentage = same_spells / max (my_spells_total, 0.000001) * 100
|
||||
|
||||
if (match_percentage > 30) then
|
||||
tinsert (tabOBject.players, actor)
|
||||
tinsert(tabOBject.players, actor)
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
if (#tabOBject.players > 0) then
|
||||
--tutorial flash
|
||||
local blink = _detalhes:GetTutorialCVar ("DETAILS_INFO_TUTORIAL2") or 0
|
||||
local blink = _detalhes:GetTutorialCVar("DETAILS_INFO_TUTORIAL2") or 0
|
||||
if (type(blink) == "number" and blink < 10) then
|
||||
|
||||
if (not tabOBject.FlashAnimation) then
|
||||
@@ -4966,7 +4966,7 @@ function gump:CriaJanelaInfo()
|
||||
--test if can show the tutorial for the comparison tab
|
||||
if (tab.tabname == "Compare") then
|
||||
--_detalhes:SetTutorialCVar ("DETAILS_INFO_TUTORIAL1", false)
|
||||
if (not _detalhes:GetTutorialCVar ("DETAILS_INFO_TUTORIAL1")) then
|
||||
if (not _detalhes:GetTutorialCVar("DETAILS_INFO_TUTORIAL1")) then
|
||||
_detalhes:SetTutorialCVar ("DETAILS_INFO_TUTORIAL1", true)
|
||||
|
||||
local alert = CreateFrame("frame", "DetailsInfoPopUp1", info, "DetailsHelpBoxTemplate")
|
||||
@@ -5050,7 +5050,7 @@ function _detalhes:CreatePlayerDetailsTab (tabname, localized_name, condition, f
|
||||
newTabButton:SetTemplate ("DETAILS_TAB_BUTTONSELECTED_TEMPLATE")
|
||||
end
|
||||
newTabButton:SetText(localized_name)
|
||||
newTabButton:SetFrameStrata ("HIGH")
|
||||
newTabButton:SetFrameStrata("HIGH")
|
||||
newTabButton:SetFrameLevel (info:GetFrameLevel()+1)
|
||||
newTabButton:Hide()
|
||||
|
||||
@@ -5063,7 +5063,7 @@ function _detalhes:CreatePlayerDetailsTab (tabname, localized_name, condition, f
|
||||
|
||||
newTabButton.frame = CreateFrame("frame", "DetailsPDWTabFrame" .. tabname, UIParent,"BackdropTemplate")
|
||||
newTabButton.frame:SetParent(info)
|
||||
newTabButton.frame:SetFrameStrata ("HIGH")
|
||||
newTabButton.frame:SetFrameStrata("HIGH")
|
||||
newTabButton.frame:SetFrameLevel (info:GetFrameLevel()+5)
|
||||
newTabButton.frame:EnableMouse (true)
|
||||
|
||||
@@ -5401,7 +5401,7 @@ local row_on_enter = function(self)
|
||||
|
||||
self.mouse_over = true
|
||||
|
||||
for index, block in pairs (_detalhes.playerDetailWindow.grupos_detalhes) do
|
||||
for index, block in pairs(_detalhes.playerDetailWindow.grupos_detalhes) do
|
||||
detalhe_infobg_onleave (block.bg)
|
||||
end
|
||||
|
||||
@@ -5416,7 +5416,7 @@ local row_on_enter = function(self)
|
||||
|
||||
if (self.isAlvo) then --monta o tooltip do alvo
|
||||
--talvez devesse escurecer a janela no fundo... pois o tooltip � transparente e pode confundir
|
||||
GameTooltip:SetOwner (self, "ANCHOR_TOPRIGHT")
|
||||
GameTooltip:SetOwner(self, "ANCHOR_TOPRIGHT")
|
||||
|
||||
if (self.spellid == "enemies") then --damage taken enemies
|
||||
if (not self.minha_tabela or not self.minha_tabela:MontaTooltipDamageTaken (self, self._index, info.instancia)) then -- > poderia ser aprimerado para uma tailcall
|
||||
@@ -5435,14 +5435,14 @@ local row_on_enter = function(self)
|
||||
|
||||
if (IsShiftKeyDown()) then
|
||||
if (type(self.show) == "number") then
|
||||
GameTooltip:SetOwner (self, "ANCHOR_TOPRIGHT")
|
||||
GameTooltip:SetOwner(self, "ANCHOR_TOPRIGHT")
|
||||
GameTooltip:AddLine (Loc ["ABILITY_ID"] .. ": " .. self.show)
|
||||
GameTooltip:Show()
|
||||
end
|
||||
end
|
||||
|
||||
if (self.show == 98021) then
|
||||
GameTooltip:SetOwner (self, "ANCHOR_TOPLEFT")
|
||||
GameTooltip:SetOwner(self, "ANCHOR_TOPLEFT")
|
||||
GameTooltip:AddLine (Loc ["STRING_SPIRIT_LINK_TOTEM_DESC"])
|
||||
GameTooltip:Show()
|
||||
end
|
||||
@@ -5644,7 +5644,7 @@ local miniframe_func_on_enter = function(self)
|
||||
if (barra.show and type (barra.show) == "number") then
|
||||
local spellname = _GetSpellInfo(barra.show)
|
||||
if (spellname) then
|
||||
GameTooltip:SetOwner (self, "ANCHOR_TOPLEFT")
|
||||
GameTooltip:SetOwner(self, "ANCHOR_TOPLEFT")
|
||||
_detalhes:GameTooltipSetSpellByID (barra.show)
|
||||
GameTooltip:Show()
|
||||
end
|
||||
@@ -5697,7 +5697,7 @@ local target_on_enter = function(self)
|
||||
|
||||
local spellname = _GetSpellInfo(barra.show)
|
||||
|
||||
GameTooltip:SetOwner (self, "ANCHOR_TOPRIGHT")
|
||||
GameTooltip:SetOwner(self, "ANCHOR_TOPRIGHT")
|
||||
GameTooltip:AddLine (barra.index .. ". " .. spellname)
|
||||
GameTooltip:AddLine (info.target_text)
|
||||
GameTooltip:AddLine (" ")
|
||||
@@ -5765,7 +5765,7 @@ local target_on_enter = function(self)
|
||||
|
||||
GameTooltip:Show()
|
||||
else
|
||||
GameTooltip:SetOwner (self, "ANCHOR_TOPRIGHT")
|
||||
GameTooltip:SetOwner(self, "ANCHOR_TOPRIGHT")
|
||||
GameTooltip:AddLine (barra.index .. ". " .. barra.show)
|
||||
GameTooltip:AddLine (info.target_text)
|
||||
GameTooltip:AddLine (Loc ["STRING_NO_TARGET"], 1, 1, 1)
|
||||
@@ -5773,7 +5773,7 @@ local target_on_enter = function(self)
|
||||
GameTooltip:Show()
|
||||
end
|
||||
else
|
||||
GameTooltip:SetOwner (self, "ANCHOR_TOPRIGHT")
|
||||
GameTooltip:SetOwner(self, "ANCHOR_TOPRIGHT")
|
||||
GameTooltip:AddLine (barra.index .. ". " .. barra.show)
|
||||
GameTooltip:AddLine (info.target_text)
|
||||
GameTooltip:AddLine (Loc ["STRING_NO_TARGET"], 1, 1, 1)
|
||||
|
||||
@@ -17,7 +17,7 @@ function Details:OpenProfiler()
|
||||
else
|
||||
--check is this is the first run of the addon (after being installed)
|
||||
local amount = 0
|
||||
for name, profile in pairs (_detalhes_global.__profiles) do
|
||||
for name, profile in pairs(_detalhes_global.__profiles) do
|
||||
amount = amount + 1
|
||||
end
|
||||
if (amount == 1) then
|
||||
@@ -80,7 +80,7 @@ function Details:OpenProfiler()
|
||||
end
|
||||
f:Hide()
|
||||
end
|
||||
local confirm = Details.gump:NewButton (f, f, "DetailsProfilerProfileConfirmButton", "button", 150, 20, confirm_func, nil, nil, nil, "Okey!")
|
||||
local confirm = Details.gump:NewButton(f, f, "DetailsProfilerProfileConfirmButton", "button", 150, 20, confirm_func, nil, nil, nil, "Okey!")
|
||||
confirm:SetPoint(50, -250)
|
||||
confirm:InstallCustomTexture()
|
||||
end
|
||||
@@ -106,7 +106,7 @@ local _
|
||||
end
|
||||
|
||||
if (Details.janela_report.ativa) then
|
||||
Details.janela_report:Flash (0.2, 0.2, 0.4, true, 0, 0, "NONE")
|
||||
Details.janela_report:Flash(0.2, 0.2, 0.4, true, 0, 0, "NONE")
|
||||
end
|
||||
|
||||
Details.janela_report.ativa = true
|
||||
@@ -206,7 +206,7 @@ local _
|
||||
end
|
||||
|
||||
if (Details.janela_report.ativa) then
|
||||
Details.janela_report:Flash (0.2, 0.2, 0.4, true, 0, 0, "NONE")
|
||||
Details.janela_report:Flash(0.2, 0.2, 0.4, true, 0, 0, "NONE")
|
||||
end
|
||||
|
||||
Details.janela_report.ativa = true
|
||||
|
||||
@@ -12,7 +12,7 @@ local scrollWidth = 825
|
||||
local panel = Details:CreateWelcomePanel ("DetailsWindowOptionsBarTextEditor", nil, windowWidth, 600, true)
|
||||
panel:SetPoint("center", UIParent, "center")
|
||||
panel:Hide()
|
||||
panel:SetFrameStrata ("FULLSCREEN")
|
||||
panel:SetFrameStrata("FULLSCREEN")
|
||||
DF:ApplyStandardBackdrop (panel)
|
||||
DF:CreateTitleBar (panel, "Details! Custom Line Text Editor")
|
||||
|
||||
@@ -39,9 +39,9 @@ DF:ApplyStandardBackdrop (textentry)
|
||||
DF:SetFontSize (textentry.editbox, 14)
|
||||
DF:ReskinSlider(textentry.scroll)
|
||||
|
||||
local arg1_button = DF:NewButton (panel, nil, "$parentButton1", nil, 80, 20, function() textentry.editbox:Insert ("{data1}") end, nil, nil, nil, string.format (Loc ["STRING_OPTIONS_TEXTEDITOR_DATA"], "1"), 1)
|
||||
local arg2_button = DF:NewButton (panel, nil, "$parentButton2", nil, 80, 20, function() textentry.editbox:Insert ("{data2}") end, nil, nil, nil, string.format (Loc ["STRING_OPTIONS_TEXTEDITOR_DATA"], "2"), 1)
|
||||
local arg3_button = DF:NewButton (panel, nil, "$parentButton3", nil, 80, 20, function() textentry.editbox:Insert ("{data3}") end, nil, nil, nil, string.format (Loc ["STRING_OPTIONS_TEXTEDITOR_DATA"], "3"), 1)
|
||||
local arg1_button = DF:NewButton(panel, nil, "$parentButton1", nil, 80, 20, function() textentry.editbox:Insert ("{data1}") end, nil, nil, nil, string.format(Loc ["STRING_OPTIONS_TEXTEDITOR_DATA"], "1"), 1)
|
||||
local arg2_button = DF:NewButton(panel, nil, "$parentButton2", nil, 80, 20, function() textentry.editbox:Insert ("{data2}") end, nil, nil, nil, string.format(Loc ["STRING_OPTIONS_TEXTEDITOR_DATA"], "2"), 1)
|
||||
local arg3_button = DF:NewButton(panel, nil, "$parentButton3", nil, 80, 20, function() textentry.editbox:Insert ("{data3}") end, nil, nil, nil, string.format(Loc ["STRING_OPTIONS_TEXTEDITOR_DATA"], "3"), 1)
|
||||
arg1_button:SetPoint("topright", panel, "topright", -12, y)
|
||||
arg2_button:SetPoint("topright", panel, "topright", -12, y - (20*1))
|
||||
arg3_button:SetPoint("topright", panel, "topright", -12, y - (20*2))
|
||||
@@ -162,7 +162,7 @@ local color_func = function(_, r, g, b, a)
|
||||
ColorSelection ( textentry.editbox, "|c" .. hex)
|
||||
end
|
||||
|
||||
local func_button = DF:NewButton (panel, nil, "$parentButton4", nil, 80, 20, function() textentry.editbox:Insert ("{func local player, combat = ...; return 0;}") end, nil, nil, nil, Loc ["STRING_OPTIONS_TEXTEDITOR_FUNC"], 1)
|
||||
local func_button = DF:NewButton(panel, nil, "$parentButton4", nil, 80, 20, function() textentry.editbox:Insert ("{func local player, combat = ...; return 0;}") end, nil, nil, nil, Loc ["STRING_OPTIONS_TEXTEDITOR_FUNC"], 1)
|
||||
local color_button = DF:NewColorPickButton (panel, "$parentButton5", nil, color_func)
|
||||
color_button:SetSize(80, 20)
|
||||
color_button:SetTemplate (buttonTemplate)
|
||||
@@ -178,21 +178,21 @@ local done = function()
|
||||
panel:Hide()
|
||||
end
|
||||
|
||||
local apply_button = DF:NewButton (panel, nil, "$parentApply", nil, 80, 20, function() panel.callback(panel.editbox:GetText()) end, nil, nil, nil, "Apply", 1) --localize-me
|
||||
local apply_button = DF:NewButton(panel, nil, "$parentApply", nil, 80, 20, function() panel.callback(panel.editbox:GetText()) end, nil, nil, nil, "Apply", 1) --localize-me
|
||||
apply_button:SetTemplate (buttonTemplate)
|
||||
apply_button:SetPoint("topright", panel, "topright", -14, -128)
|
||||
|
||||
local ok_button = DF:NewButton (panel, nil, "$parentButtonOk", nil, 80, 20, done, nil, nil, nil, Loc ["STRING_OPTIONS_TEXTEDITOR_DONE"], 1)
|
||||
local ok_button = DF:NewButton(panel, nil, "$parentButtonOk", nil, 80, 20, done, nil, nil, nil, Loc ["STRING_OPTIONS_TEXTEDITOR_DONE"], 1)
|
||||
ok_button.tooltip = Loc ["STRING_OPTIONS_TEXTEDITOR_DONE_TOOLTIP"]
|
||||
ok_button:SetTemplate (buttonTemplate)
|
||||
ok_button:SetPoint("topright", panel, "topright", -14, -194)
|
||||
|
||||
local reset_button = DF:NewButton (panel, nil, "$parentDefaultOk", nil, 80, 20, function() textentry.editbox:SetText(panel.default); panel.callback(panel.editbox:GetText()) end, nil, nil, nil, Loc ["STRING_OPTIONS_TEXTEDITOR_RESET"], 1)
|
||||
local reset_button = DF:NewButton(panel, nil, "$parentDefaultOk", nil, 80, 20, function() textentry.editbox:SetText(panel.default); panel.callback(panel.editbox:GetText()) end, nil, nil, nil, Loc ["STRING_OPTIONS_TEXTEDITOR_RESET"], 1)
|
||||
reset_button.tooltip = Loc ["STRING_OPTIONS_TEXTEDITOR_RESET_TOOLTIP"]
|
||||
reset_button:SetTemplate (buttonTemplate)
|
||||
reset_button:SetPoint("topright", panel, "topright", -14, -150)
|
||||
|
||||
local cancel_button = DF:NewButton (panel, nil, "$parentDefaultCancel", nil, 80, 20, function() textentry.editbox:SetText(panel.default_text); done(); end, nil, nil, nil, Loc ["STRING_OPTIONS_TEXTEDITOR_CANCEL"], 1)
|
||||
local cancel_button = DF:NewButton(panel, nil, "$parentDefaultCancel", nil, 80, 20, function() textentry.editbox:SetText(panel.default_text); done(); end, nil, nil, nil, Loc ["STRING_OPTIONS_TEXTEDITOR_CANCEL"], 1)
|
||||
cancel_button.tooltip = Loc ["STRING_OPTIONS_TEXTEDITOR_CANCEL_TOOLTIP"]
|
||||
cancel_button:SetTemplate (buttonTemplate)
|
||||
cancel_button:SetPoint("topright", panel, "topright", -14, -172)
|
||||
@@ -135,7 +135,7 @@ function Details.OpenRunCodeWindow()
|
||||
Details:Msg("Code saved!")
|
||||
code_editor:ClearFocus()
|
||||
else
|
||||
errortext_frame:Flash (0.2, 0.2, 0.4, true, nil, nil, "NONE")
|
||||
errortext_frame:Flash(0.2, 0.2, 0.4, true, nil, nil, "NONE")
|
||||
Details:Msg("Can't save the code: it has errors.")
|
||||
end
|
||||
end
|
||||
@@ -167,7 +167,7 @@ function Details.OpenRunCodeWindow()
|
||||
DF:SetEnvironment(func)
|
||||
DF:QuickDispatch (func)
|
||||
else
|
||||
errortext_frame:Flash (0.2, 0.2, 0.4, true, nil, nil, "NONE")
|
||||
errortext_frame:Flash(0.2, 0.2, 0.4, true, nil, nil, "NONE")
|
||||
end
|
||||
end
|
||||
|
||||
@@ -178,7 +178,7 @@ function Details.OpenRunCodeWindow()
|
||||
end
|
||||
|
||||
DetailsPluginContainerWindow.OpenPlugin (DetailsRunCodePanel)
|
||||
DetailsRunCodePanel.CodeTypeDropdown:Select (1, true)
|
||||
DetailsRunCodePanel.CodeTypeDropdown:Select(1, true)
|
||||
|
||||
--show the initialization code when showing up this window
|
||||
DetailsRunCodePanel.EditingCode = Details.RunCodeTypes [1].Value
|
||||
|
||||
@@ -220,7 +220,7 @@ function Details:ScrollDamage()
|
||||
|
||||
elseif (token == "SWING_DAMAGE") then
|
||||
-- amount, overkill, school, resisted, blocked, absorbed, critical, glacing, crushing, isoffhand = spellID, spellName, spellType, amount, overKill, school, resisted, blocked, absorbed, isCritical
|
||||
-- tinsert (DetailsScrollDamage.Data, 1, {timew, token, hidding, sourceSerial, sourceName, sourceFlag, sourceFlag2, targetSerial, targetName, targetFlag, targetFlag2, spellID, spellName, spellType, amount, overKill, school, resisted, blocked, absorbed, isCritical})
|
||||
-- tinsert(DetailsScrollDamage.Data, 1, {timew, token, hidding, sourceSerial, sourceName, sourceFlag, sourceFlag2, targetSerial, targetName, targetFlag, targetFlag2, spellID, spellName, spellType, amount, overKill, school, resisted, blocked, absorbed, isCritical})
|
||||
-- damageScroll:RefreshScroll()
|
||||
end
|
||||
end
|
||||
|
||||
@@ -35,13 +35,13 @@ function Details:OpenRaidHistoryWindow (_raid, _boss, _difficulty, _role, _guild
|
||||
|
||||
local f = DetailsRaidHistoryWindow or CreateFrame("frame", "DetailsRaidHistoryWindow", UIParent,"BackdropTemplate") --, "ButtonFrameTemplate"
|
||||
f:SetPoint("center", UIParent, "center")
|
||||
f:SetFrameStrata ("HIGH")
|
||||
f:SetFrameStrata("HIGH")
|
||||
f:SetToplevel (true)
|
||||
|
||||
f:SetMovable (true)
|
||||
f:SetWidth(850)
|
||||
f:SetHeight(500)
|
||||
tinsert (UISpecialFrames, "DetailsRaidHistoryWindow")
|
||||
tinsert(UISpecialFrames, "DetailsRaidHistoryWindow")
|
||||
|
||||
function f.OpenDB()
|
||||
local db = Details.storage:OpenRaidStorage()
|
||||
@@ -80,10 +80,10 @@ function Details:OpenRaidHistoryWindow (_raid, _boss, _difficulty, _role, _guild
|
||||
|
||||
local titlebar = DF:CreateTitleBar(f, "Details! " .. Loc ["STRING_STATISTICS"])
|
||||
|
||||
if (not Details:GetTutorialCVar ("HISTORYPANEL_TUTORIAL")) then
|
||||
if (not Details:GetTutorialCVar("HISTORYPANEL_TUTORIAL")) then
|
||||
local tutorialFrame = CreateFrame("frame", "$parentTutorialFrame",f,"BackdropTemplate")
|
||||
tutorialFrame:SetPoint("center", f, "center")
|
||||
tutorialFrame:SetFrameStrata ("DIALOG")
|
||||
tutorialFrame:SetFrameStrata("DIALOG")
|
||||
tutorialFrame:SetSize(400, 300)
|
||||
tutorialFrame:SetBackdrop({bgFile = [[Interface\AddOns\Details\images\background]], tile = true, tileSize = 16,
|
||||
insets = {left = 0, right = 0, top = 0, bottom = 0}, edgeFile = [[Interface\Buttons\WHITE8X8]], edgeSize=1})
|
||||
@@ -130,7 +130,7 @@ function Details:OpenRaidHistoryWindow (_raid, _boss, _difficulty, _role, _guild
|
||||
local selectGuildRank = function()
|
||||
f.HistoryCheckBox:SetValue(false)
|
||||
f.GuildRankCheckBox:SetValue(true)
|
||||
_G.DetailsRaidHistoryWindow.select_player:Select (1, true)
|
||||
_G.DetailsRaidHistoryWindow.select_player:Select(1, true)
|
||||
f.select_player2:Hide()
|
||||
f.select_player2_label:Hide()
|
||||
f.Mode = 2
|
||||
@@ -276,7 +276,7 @@ function Details:OpenRaidHistoryWindow (_raid, _boss, _difficulty, _role, _guild
|
||||
playerName = playerName:gsub ("%|c%x%x%x%x%x%x%x%x", "")
|
||||
playerName = playerName:gsub ("%|r", "")
|
||||
playerName = playerName:gsub (".*%s", "")
|
||||
tinsert (result, {playerName, f.LatestResourceTable[i][2]})
|
||||
tinsert(result, {playerName, f.LatestResourceTable[i][2]})
|
||||
else
|
||||
break
|
||||
end
|
||||
@@ -451,9 +451,9 @@ function Details:OpenRaidHistoryWindow (_raid, _boss, _difficulty, _role, _guild
|
||||
for encounterIndex, encounter in ipairs(encounterTable) do
|
||||
if (encounter.guild == guild) then
|
||||
local roleTable = encounter [role]
|
||||
for playerName, _ in pairs (roleTable) do
|
||||
for playerName, _ in pairs(roleTable) do
|
||||
if (not alreadyListed [playerName]) then
|
||||
tinsert (t, {value = playerName, label = playerName, icon = icon, onclick = onPlayer2Select})
|
||||
tinsert(t, {value = playerName, label = playerName, icon = icon, onclick = onPlayer2Select})
|
||||
alreadyListed [playerName] = true
|
||||
end
|
||||
end
|
||||
@@ -493,7 +493,7 @@ function Details:OpenRaidHistoryWindow (_raid, _boss, _difficulty, _role, _guild
|
||||
if (type(difficulty) == "number") then
|
||||
if (difficulty == 14) then
|
||||
--don't show normal encounters
|
||||
--tinsert (difficultyList, {value = 14, label = "Normal", icon = icon, onclick = on_diff_select})
|
||||
--tinsert(difficultyList, {value = 14, label = "Normal", icon = icon, onclick = on_diff_select})
|
||||
--print ("has normal encounter")
|
||||
|
||||
elseif (difficulty == 15) then
|
||||
@@ -505,7 +505,7 @@ function Details:OpenRaidHistoryWindow (_raid, _boss, _difficulty, _role, _guild
|
||||
end
|
||||
|
||||
if (not alreadyHave) then
|
||||
tinsert (difficultyList, 1, {value = 15, label = "Heroic", icon = icon, onclick = on_diff_select})
|
||||
tinsert(difficultyList, 1, {value = 15, label = "Heroic", icon = icon, onclick = on_diff_select})
|
||||
end
|
||||
|
||||
elseif (difficulty == 16) then
|
||||
@@ -517,23 +517,23 @@ function Details:OpenRaidHistoryWindow (_raid, _boss, _difficulty, _role, _guild
|
||||
end
|
||||
|
||||
if (not alreadyHave) then
|
||||
tinsert (difficultyList, {value = 16, label = "Mythic", icon = icon, onclick = on_diff_select})
|
||||
tinsert(difficultyList, {value = 16, label = "Mythic", icon = icon, onclick = on_diff_select})
|
||||
end
|
||||
end
|
||||
|
||||
for encounterId, encounterTable in pairs (encounterIdTable) do
|
||||
for encounterId, encounterTable in pairs(encounterIdTable) do
|
||||
if (not bossRepeated[encounterId]) then
|
||||
local encounter, instance = Details:GetBossEncounterDetailsFromEncounterId(nil, encounterId)
|
||||
|
||||
if (encounter) then
|
||||
local InstanceID = Details:GetInstanceIdFromEncounterId (encounterId)
|
||||
if (raidSelected == InstanceID) then
|
||||
tinsert (bossList, {value = encounterId, label = encounter.boss, icon = icon, onclick = on_boss_select})
|
||||
tinsert(bossList, {value = encounterId, label = encounter.boss, icon = icon, onclick = on_boss_select})
|
||||
bossRepeated [encounterId] = true
|
||||
end
|
||||
|
||||
if (not raidRepeated [instance.name]) then
|
||||
tinsert (raidList, {value = instance.id, label = instance.name, icon = icon, onclick = onRaidSelect})
|
||||
tinsert(raidList, {value = instance.id, label = instance.name, icon = icon, onclick = onRaidSelect})
|
||||
raidRepeated [instance.name] = true
|
||||
end
|
||||
|
||||
@@ -543,7 +543,7 @@ function Details:OpenRaidHistoryWindow (_raid, _boss, _difficulty, _role, _guild
|
||||
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 = on_guild_select})
|
||||
tinsert(guildList, {value = guild, label = guild, icon = icon, onclick = on_guild_select})
|
||||
guildRepeated [guild] = true
|
||||
end
|
||||
end
|
||||
@@ -555,19 +555,19 @@ function Details:OpenRaidHistoryWindow (_raid, _boss, _difficulty, _role, _guild
|
||||
|
||||
|
||||
diff_dropdown:Refresh()
|
||||
diff_dropdown:Select (1, true)
|
||||
diff_dropdown:Select(1, true)
|
||||
boss_dropdown:Refresh()
|
||||
boss_dropdown:Select (1, true)
|
||||
boss_dropdown:Select(1, true)
|
||||
if (not DoNotSelectRaid) then
|
||||
raid_dropdown:Refresh()
|
||||
raid_dropdown:Select (1, true)
|
||||
raid_dropdown:Select(1, true)
|
||||
end
|
||||
|
||||
guild_dropdown:Refresh()
|
||||
if (currentGuild) then
|
||||
guild_dropdown:Select (currentGuild)
|
||||
guild_dropdown:Select(currentGuild)
|
||||
else
|
||||
guild_dropdown:Select (1, true)
|
||||
guild_dropdown:Select(1, true)
|
||||
end
|
||||
end
|
||||
|
||||
@@ -577,10 +577,10 @@ function Details:OpenRaidHistoryWindow (_raid, _boss, _difficulty, _role, _guild
|
||||
local boss_repeated = {}
|
||||
wipe (bossList)
|
||||
|
||||
for difficulty, encounterIdTable in pairs (db) do
|
||||
for difficulty, encounterIdTable in pairs(db) do
|
||||
if (type(difficulty) == "number") then
|
||||
if (difficulty == 14) then
|
||||
--tinsert (difficultyList, {value = 14, label = "Normal", icon = icon, onclick = on_diff_select})
|
||||
--tinsert(difficultyList, {value = 14, label = "Normal", icon = icon, onclick = on_diff_select})
|
||||
--print ("has normal encounter")
|
||||
elseif (difficulty == 15) then
|
||||
local alreadyHave = false
|
||||
@@ -590,7 +590,7 @@ function Details:OpenRaidHistoryWindow (_raid, _boss, _difficulty, _role, _guild
|
||||
end
|
||||
end
|
||||
if (not alreadyHave) then
|
||||
tinsert (difficultyList, 1, {value = 15, label = "Heroic", icon = icon, onclick = on_diff_select})
|
||||
tinsert(difficultyList, 1, {value = 15, label = "Heroic", icon = icon, onclick = on_diff_select})
|
||||
end
|
||||
elseif (difficulty == 16) then
|
||||
local alreadyHave = false
|
||||
@@ -600,11 +600,11 @@ function Details:OpenRaidHistoryWindow (_raid, _boss, _difficulty, _role, _guild
|
||||
end
|
||||
end
|
||||
if (not alreadyHave) then
|
||||
tinsert (difficultyList, {value = 16, label = "Mythic", icon = icon, onclick = on_diff_select})
|
||||
tinsert(difficultyList, {value = 16, label = "Mythic", icon = icon, onclick = on_diff_select})
|
||||
end
|
||||
end
|
||||
|
||||
for encounterId, encounterTable in pairs (encounterIdTable) do
|
||||
for encounterId, encounterTable in pairs(encounterIdTable) do
|
||||
if (not boss_repeated [encounterId]) then
|
||||
local encounter, instance = Details:GetBossEncounterDetailsFromEncounterId (_, encounterId)
|
||||
if (encounter) then
|
||||
@@ -615,15 +615,15 @@ function Details:OpenRaidHistoryWindow (_raid, _boss, _difficulty, _role, _guild
|
||||
if (bossIndex) then
|
||||
local l, r, t, b, texturePath = Details:GetBossIcon (InstanceID, bossIndex)
|
||||
if (texturePath) then
|
||||
tinsert (bossList, {value = encounterId, label = encounter.boss, icon = texturePath, texcoord = {l, r, t, b}, onclick = on_boss_select})
|
||||
tinsert(bossList, {value = encounterId, label = encounter.boss, icon = texturePath, texcoord = {l, r, t, b}, onclick = on_boss_select})
|
||||
else
|
||||
tinsert (bossList, {value = encounterId, label = encounter.boss, icon = icon, onclick = on_boss_select})
|
||||
tinsert(bossList, {value = encounterId, label = encounter.boss, icon = icon, onclick = on_boss_select})
|
||||
end
|
||||
else
|
||||
tinsert (bossList, {value = encounterId, label = encounter.boss, icon = icon, onclick = on_boss_select})
|
||||
tinsert(bossList, {value = encounterId, label = encounter.boss, icon = icon, onclick = on_boss_select})
|
||||
end
|
||||
--]=]
|
||||
tinsert (bossList, {value = encounterId, label = encounter.boss, icon = icon, onclick = on_boss_select})
|
||||
tinsert(bossList, {value = encounterId, label = encounter.boss, icon = icon, onclick = on_boss_select})
|
||||
boss_repeated [encounterId] = true
|
||||
end
|
||||
end
|
||||
@@ -681,8 +681,8 @@ function Details:OpenRaidHistoryWindow (_raid, _boss, _difficulty, _role, _guild
|
||||
|
||||
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})
|
||||
--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})
|
||||
end
|
||||
end
|
||||
end
|
||||
@@ -700,7 +700,7 @@ function Details:OpenRaidHistoryWindow (_raid, _boss, _difficulty, _role, _guild
|
||||
GameCooltip:AddLine ("Item Level:", floor (self.data.data [2]), 1, "white")
|
||||
GameCooltip:AddLine ("Date:", self.data.fulldate:gsub (".*%s", ""), 1, "white")
|
||||
|
||||
GameCooltip:SetOwner (self.ball.tooltip_anchor)
|
||||
GameCooltip:SetOwner(self.ball.tooltip_anchor)
|
||||
GameCooltip:Show()
|
||||
end
|
||||
local onleave = function(self)
|
||||
@@ -737,7 +737,7 @@ function Details:OpenRaidHistoryWindow (_raid, _boss, _difficulty, _role, _guild
|
||||
date = date:gsub (".*%s", "")
|
||||
date = date:sub (1, -4)
|
||||
|
||||
for playerName, playerTable in pairs (roleTable) do
|
||||
for playerName, playerTable in pairs(roleTable) do
|
||||
|
||||
if (not playerScore [playerName]) then
|
||||
playerScore [playerName] = {
|
||||
@@ -767,7 +767,7 @@ function Details:OpenRaidHistoryWindow (_raid, _boss, _difficulty, _role, _guild
|
||||
end
|
||||
|
||||
local sortTable = {}
|
||||
for playerName, t in pairs (playerScore) do
|
||||
for playerName, t in pairs(playerScore) do
|
||||
local className = select (2, GetClassInfo (t.class or 0))
|
||||
local classColor = "FFFFFFFF"
|
||||
if (className) then
|
||||
@@ -775,7 +775,7 @@ function Details:OpenRaidHistoryWindow (_raid, _boss, _difficulty, _role, _guild
|
||||
end
|
||||
|
||||
local playerNameFormated = Details:GetOnlyName (playerName)
|
||||
tinsert (sortTable, {
|
||||
tinsert(sortTable, {
|
||||
"|c" .. classColor .. playerNameFormated .. "|r",
|
||||
Details:comma_value (t.ps),
|
||||
Details:ToK2 (t.total),
|
||||
@@ -825,9 +825,9 @@ function Details:OpenRaidHistoryWindow (_raid, _boss, _difficulty, _role, _guild
|
||||
date = date:sub (1, -4)
|
||||
amt_encounters = amt_encounters + 1
|
||||
|
||||
tinsert (header, {name = date, type = "text"})
|
||||
tinsert(header, {name = date, type = "text"})
|
||||
|
||||
for playerName, playerTable in pairs (roleTable) do
|
||||
for playerName, playerTable in pairs(roleTable) do
|
||||
local index = players_index [playerName]
|
||||
local player
|
||||
|
||||
@@ -835,19 +835,19 @@ function Details:OpenRaidHistoryWindow (_raid, _boss, _difficulty, _role, _guild
|
||||
player = {playerName}
|
||||
player_class [playerName] = playerTable [3]
|
||||
for i = 1, amt_encounters-1 do
|
||||
tinsert (player, "")
|
||||
tinsert(player, "")
|
||||
end
|
||||
tinsert (player, Details:ToK2 (playerTable [1] / encounter.elapsed))
|
||||
tinsert (players, player)
|
||||
tinsert(player, Details:ToK2 (playerTable [1] / encounter.elapsed))
|
||||
tinsert(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, "")
|
||||
tinsert(player, "")
|
||||
end
|
||||
tinsert (player, Details:ToK2 (playerTable [1] / encounter.elapsed))
|
||||
tinsert(player, Details:ToK2 (playerTable [1] / encounter.elapsed))
|
||||
end
|
||||
|
||||
end
|
||||
@@ -859,7 +859,7 @@ function Details:OpenRaidHistoryWindow (_raid, _boss, _difficulty, _role, _guild
|
||||
|
||||
for index, playerTable in ipairs(players) do
|
||||
for i = #playerTable, amt_encounters do
|
||||
tinsert (playerTable, "")
|
||||
tinsert(playerTable, "")
|
||||
end
|
||||
|
||||
local className = select (2, GetClassInfo (player_class [playerTable [1]] or 0))
|
||||
@@ -917,9 +917,9 @@ function Details:OpenRaidHistoryWindow (_raid, _boss, _difficulty, _role, _guild
|
||||
player_name = f.latest_player_selected or player_name
|
||||
|
||||
if (player_name) then
|
||||
player2_dropdown:Select (player_name)
|
||||
player2_dropdown:Select(player_name)
|
||||
else
|
||||
player2_dropdown:Select (1, true)
|
||||
player2_dropdown:Select(1, true)
|
||||
end
|
||||
|
||||
f:BuildPlayerTable (player2_dropdown.value)
|
||||
@@ -943,7 +943,7 @@ function Details:OpenRaidHistoryWindow (_raid, _boss, _difficulty, _role, _guild
|
||||
player2_dropdown:Show()
|
||||
f.build_player2_data = {{}, guild, role}
|
||||
player2_dropdown:Refresh()
|
||||
player2_dropdown:Select (1, true)
|
||||
player2_dropdown:Select(1, true)
|
||||
f:BuildPlayerTable (player2_dropdown.value)
|
||||
end
|
||||
end
|
||||
@@ -1007,23 +1007,23 @@ function Details:OpenRaidHistoryWindow (_raid, _boss, _difficulty, _role, _guild
|
||||
end
|
||||
|
||||
if (_raid) then
|
||||
statsWindow.select_raid:Select (_raid)
|
||||
statsWindow.select_raid:Select(_raid)
|
||||
statsWindow:Refresh()
|
||||
statsWindow.UpdateBossDropdown()
|
||||
end
|
||||
|
||||
if (_boss) then
|
||||
statsWindow.select_boss:Select (_boss)
|
||||
statsWindow.select_boss:Select(_boss)
|
||||
statsWindow:Refresh()
|
||||
end
|
||||
|
||||
if (_difficulty) then
|
||||
statsWindow.select_diff:Select (_difficulty)
|
||||
statsWindow.select_diff:Select(_difficulty)
|
||||
statsWindow:Refresh()
|
||||
end
|
||||
|
||||
if (_role) then
|
||||
statsWindow.select_role:Select (_role)
|
||||
statsWindow.select_role:Select(_role)
|
||||
statsWindow:Refresh()
|
||||
end
|
||||
|
||||
@@ -1031,18 +1031,18 @@ function Details:OpenRaidHistoryWindow (_raid, _boss, _difficulty, _role, _guild
|
||||
if (type(_guild) == "boolean") then
|
||||
_guild = GetGuildInfo ("player")
|
||||
end
|
||||
statsWindow.select_guild:Select (_guild)
|
||||
statsWindow.select_guild:Select(_guild)
|
||||
statsWindow:Refresh()
|
||||
end
|
||||
|
||||
if (_player_base) then
|
||||
statsWindow.select_player:Select (_player_base)
|
||||
statsWindow.select_player:Select(_player_base)
|
||||
statsWindow:Refresh()
|
||||
end
|
||||
|
||||
if (_player_name) then
|
||||
statsWindow.select_player2:Refresh()
|
||||
statsWindow.select_player2:Select (_player_name)
|
||||
statsWindow.select_player2:Select(_player_name)
|
||||
statsWindow:Refresh (_player_name)
|
||||
end
|
||||
|
||||
|
||||
@@ -243,7 +243,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)
|
||||
tinsert(allDisplaysFrame.buttons [attribute], button)
|
||||
y = y - 17
|
||||
end
|
||||
|
||||
@@ -301,7 +301,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)
|
||||
tinsert(allDisplaysFrame.buttons [custom_index], button)
|
||||
allDisplaysFrame.y = allDisplaysFrame.y - 17
|
||||
end
|
||||
|
||||
@@ -341,7 +341,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)
|
||||
tinsert(allDisplaysFrame.buttons [script_index], button)
|
||||
allDisplaysFrame.y = allDisplaysFrame.y - 17
|
||||
end
|
||||
|
||||
@@ -490,7 +490,7 @@ function Details.switch:ShowMe(instancia)
|
||||
if (not Details.switch.segments_blocks) then
|
||||
local segment_switch = function(self, button, segment)
|
||||
if (button == "LeftButton") then
|
||||
Details.switch.current_instancia:TrocaTabela (segment)
|
||||
Details.switch.current_instancia:TrocaTabela(segment)
|
||||
Details.switch.CloseMe()
|
||||
elseif (button == "RightButton") then
|
||||
Details.switch.CloseMe()
|
||||
@@ -535,7 +535,7 @@ function Details.switch:ShowMe(instancia)
|
||||
local button = gump:CreateButton (Details.switch.frame, segment_switch, 100, 20, "", index)
|
||||
button:SetPoint("topleft", s, "topleft", -17, 0)
|
||||
button:SetPoint("bottomright", s, "bottomright", 0, 0)
|
||||
button:SetClickFunction (segment_switch, nil, nil, "right")
|
||||
button:SetClickFunction(segment_switch, nil, nil, "right")
|
||||
|
||||
local boss_texture = gump:CreateImage (button, nil, 16, 16)
|
||||
boss_texture:SetPoint("right", s, "left", -2, 0)
|
||||
@@ -560,7 +560,7 @@ function Details.switch:ShowMe(instancia)
|
||||
s.HideMe = hide_label
|
||||
s.ShowMe = show_label
|
||||
|
||||
tinsert (Details.switch.segments_blocks, s)
|
||||
tinsert(Details.switch.segments_blocks, s)
|
||||
return s
|
||||
end
|
||||
|
||||
@@ -886,7 +886,7 @@ end
|
||||
|
||||
function Details.switch:InitSwitch()
|
||||
local instancia = Details.tabela_instancias[1]
|
||||
Details.switch:ShowMe (instancia)
|
||||
Details.switch:ShowMe(instancia)
|
||||
Details.switch:CloseMe()
|
||||
end
|
||||
|
||||
|
||||
+25
-25
@@ -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)
|
||||
tinsert(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)
|
||||
tinsert(WeakAurasSaved.displays [group].controlledChildren, new_aura.id)
|
||||
else
|
||||
new_aura.parent = nil
|
||||
end
|
||||
@@ -1983,7 +1983,7 @@ function _detalhes:OpenAuraPanel (spellid, spellname, spellicon, encounterid, tr
|
||||
local f = DetailsAuraPanel or CreateFrame("frame", "DetailsAuraPanel", UIParent,"BackdropTemplate")
|
||||
f:SetSize(800, 600)
|
||||
f:SetPoint("center", UIParent, "center", 0, 150)
|
||||
f:SetFrameStrata ("DIALOG")
|
||||
f:SetFrameStrata("DIALOG")
|
||||
f:EnableMouse (true)
|
||||
f:SetMovable (true)
|
||||
f:SetToplevel (true)
|
||||
@@ -2229,7 +2229,7 @@ function _detalhes:OpenAuraPanel (spellid, spellname, spellicon, encounterid, tr
|
||||
local checkBox = fw:CreateSwitch (f, OnChangeTriggerState, i == 1)
|
||||
checkBox:SetTemplate (fw:GetTemplate ("switch", "OPTIONS_CHECKBOX_TEMPLATE"))
|
||||
checkBox:SetAsCheckBox()
|
||||
checkBox:SetFixedParameter (triggerList [i].value)
|
||||
checkBox:SetFixedParameter(triggerList [i].value)
|
||||
|
||||
checkBox:SetSize(20, 20)
|
||||
checkBox:SetPoint("topleft", aura_on_label, "bottomleft", 0, 12 + (-i*20))
|
||||
@@ -2279,7 +2279,7 @@ function _detalhes:OpenAuraPanel (spellid, spellname, spellicon, encounterid, tr
|
||||
local icon_button_func = function(texture)
|
||||
f.IconButton.icon.texture = texture
|
||||
end
|
||||
local icon_pick_button = fw:NewButton (f, nil, "$parentIconButton", "IconButton", 20, 20, function() fw:IconPick (icon_button_func, true) end)
|
||||
local icon_pick_button = fw:NewButton(f, nil, "$parentIconButton", "IconButton", 20, 20, function() fw:IconPick (icon_button_func, true) end)
|
||||
local icon_button_icon = fw:NewImage (icon_pick_button, [[Interface\ICONS\TEMP]], 19, 19, "background", nil, "icon", "$parentIcon")
|
||||
icon_pick_button:InstallCustomTexture()
|
||||
|
||||
@@ -2358,7 +2358,7 @@ function _detalhes:OpenAuraPanel (spellid, spellname, spellicon, encounterid, tr
|
||||
local sounds = {}
|
||||
local already_added = {}
|
||||
|
||||
for name, soundFile in pairs (game_sounds) do
|
||||
for name, soundFile in pairs(game_sounds) do
|
||||
name = name:gsub ("(%a)([%w_']*)", titlecase)
|
||||
if (not already_added [name]) then
|
||||
sounds [#sounds+1] = {name = name, file = soundFile, gamesound = true}
|
||||
@@ -2366,7 +2366,7 @@ function _detalhes:OpenAuraPanel (spellid, spellname, spellicon, encounterid, tr
|
||||
end
|
||||
end
|
||||
|
||||
for name, soundFile in pairs (LibStub:GetLibrary("LibSharedMedia-3.0"):HashTable ("sound")) do
|
||||
for name, soundFile in pairs(LibStub:GetLibrary("LibSharedMedia-3.0"):HashTable ("sound")) do
|
||||
name = name:gsub ("(%a)([%w_']*)", titlecase)
|
||||
if (not already_added [name]) then
|
||||
sounds [#sounds+1] = {name = name, file = soundFile}
|
||||
@@ -2375,7 +2375,7 @@ function _detalhes:OpenAuraPanel (spellid, spellname, spellicon, encounterid, tr
|
||||
end
|
||||
|
||||
if (WeakAuras and WeakAuras.sound_types) then
|
||||
for soundFile, name in pairs (WeakAuras.sound_types) do
|
||||
for soundFile, name in pairs(WeakAuras.sound_types) do
|
||||
name = name:gsub ("(%a)([%w_']*)", titlecase)
|
||||
if (not already_added [name]) then
|
||||
sounds [#sounds+1] = {name = name, file = soundFile}
|
||||
@@ -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})
|
||||
tinsert(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})
|
||||
tinsert(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})
|
||||
tinsert(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]]})
|
||||
tinsert(t, {label = "Weak Auras 2", value = "WA", icon = [[Interface\AddOns\WeakAuras\Media\Textures\icon]]})
|
||||
end
|
||||
return t
|
||||
end
|
||||
@@ -2478,14 +2478,14 @@ function _detalhes:OpenAuraPanel (spellid, spellname, spellicon, encounterid, tr
|
||||
local weakauras_folder_options = function()
|
||||
local t = {}
|
||||
if (WeakAuras and WeakAurasSaved) then
|
||||
for display_name, aura_table in pairs (WeakAurasSaved.displays) do
|
||||
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})
|
||||
tinsert(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})
|
||||
tinsert(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
|
||||
|
||||
@@ -2533,7 +2533,7 @@ function _detalhes:OpenAuraPanel (spellid, spellname, spellicon, encounterid, tr
|
||||
|
||||
--select the new group in the dropdown
|
||||
weakauras_folder:Refresh()
|
||||
weakauras_folder:Select (groupName)
|
||||
weakauras_folder:Select(groupName)
|
||||
end
|
||||
|
||||
local weakauras_newgroup_label = fw:CreateLabel(f, "New WeakAuras Group: ", nil, nil, "GameFontNormal")
|
||||
@@ -2696,7 +2696,7 @@ function _detalhes:OpenAuraPanel (spellid, spellname, spellicon, encounterid, tr
|
||||
f.StackSlider:Disable()
|
||||
f.SpellName:Disable()
|
||||
f.UseSpellId:Disable()
|
||||
DetailsAuraPanel.AuraTypeDropdown:Select (2, true)
|
||||
DetailsAuraPanel.AuraTypeDropdown:Select(2, true)
|
||||
DetailsAuraPanel.OnSelectAuraType (nil, nil, 2, true)
|
||||
f.IsCooldown:Disable()
|
||||
|
||||
@@ -2731,15 +2731,15 @@ function _detalhes:OpenAuraPanel (spellid, spellname, spellicon, encounterid, tr
|
||||
|
||||
DetailsAuraPanel.WeakaurasFolderDropdown:Refresh()
|
||||
if (encounterid) then
|
||||
DetailsAuraPanel.WeakaurasFolderDropdown:Select ("Details! Aura Group")
|
||||
DetailsAuraPanel.WeakaurasFolderDropdown:Select("Details! Aura Group")
|
||||
DetailsAuraPanel.IconSizeSlider:SetValue(128)
|
||||
else
|
||||
DetailsAuraPanel.WeakaurasFolderDropdown:Select (1, true)
|
||||
DetailsAuraPanel.WeakaurasFolderDropdown:Select(1, true)
|
||||
DetailsAuraPanel.IconSizeSlider:SetValue(64)
|
||||
end
|
||||
|
||||
if (DetailsAuraPanel.other_values.dbm_timer_id or DetailsAuraPanel.other_values.bw_timer_id) then
|
||||
DetailsAuraPanel.WeakaurasFolderDropdown:Select ("Details! Boss Mods Group")
|
||||
DetailsAuraPanel.WeakaurasFolderDropdown:Select("Details! Boss Mods Group")
|
||||
end
|
||||
|
||||
if (DetailsAuraPanel.other_values.text_size) then
|
||||
@@ -2758,23 +2758,23 @@ function _detalhes:OpenAuraPanel (spellid, spellname, spellicon, encounterid, tr
|
||||
DetailsAuraPanel.UseGlow:SetValue(false)
|
||||
|
||||
DetailsAuraPanel.StackSlider:SetValue(0)
|
||||
DetailsAuraPanel.SoundEffectDropdown:Select (1, true)
|
||||
DetailsAuraPanel.SoundEffectDropdown:Select(1, true)
|
||||
DetailsAuraPanel.AuraText:SetText(DetailsAuraPanel.other_values.text or "")
|
||||
DetailsAuraPanel.SaySomething:SetText("")
|
||||
|
||||
if (triggertype and type (triggertype) == "number") then
|
||||
DetailsAuraPanel.AuraOnDropdown:Select (triggertype, true)
|
||||
DetailsAuraPanel.AuraOnDropdown:Select(triggertype, true)
|
||||
DetailsAuraPanel.SetTriggerState (DetailsAuraPanel.TriggerList [triggertype].value) --passed by index not by the trigger ID
|
||||
else
|
||||
DetailsAuraPanel.AuraOnDropdown:Select (1, true)
|
||||
DetailsAuraPanel.AuraOnDropdown:Select(1, true)
|
||||
DetailsAuraPanel.SetTriggerState (1)
|
||||
end
|
||||
|
||||
if (auratype and type (auratype) == "number") then
|
||||
DetailsAuraPanel.AuraTypeDropdown:Select (auratype, true)
|
||||
DetailsAuraPanel.AuraTypeDropdown:Select(auratype, true)
|
||||
DetailsAuraPanel.OnSelectAuraType (nil, nil, auratype)
|
||||
else
|
||||
DetailsAuraPanel.AuraTypeDropdown:Select (1, true)
|
||||
DetailsAuraPanel.AuraTypeDropdown:Select(1, true)
|
||||
DetailsAuraPanel.OnSelectAuraType (nil, nil, "icon")
|
||||
end
|
||||
|
||||
|
||||
+54
-54
@@ -199,7 +199,7 @@ function _detalhes:OpenWelcomeWindow()
|
||||
|
||||
--save standard
|
||||
local savedObject = {}
|
||||
for key, value in pairs (instance) do
|
||||
for key, value in pairs(instance) do
|
||||
if (_detalhes.instance_defaults [key] ~= nil) then
|
||||
if (type(value) == "table") then
|
||||
savedObject [key] = Details.CopyTable (value)
|
||||
@@ -211,7 +211,7 @@ function _detalhes:OpenWelcomeWindow()
|
||||
_detalhes.standard_skin = savedObject
|
||||
|
||||
_detalhes:ApplyPDWSkin ("ElvUI")
|
||||
--_detalhes:SetTooltipBackdrop ("Details BarBorder 3", 14, {0, 0, 0, 1})
|
||||
--_detalhes:SetTooltipBackdrop("Details BarBorder 3", 14, {0, 0, 0, 1})
|
||||
end
|
||||
--]=]
|
||||
|
||||
@@ -225,7 +225,7 @@ function _detalhes:OpenWelcomeWindow()
|
||||
_detalhes.stopwelcomealert = nil
|
||||
end
|
||||
frame_alert.alert = CreateFrame("frame", "DetailsWelcomeWindowAlert", UIParent, "ActionBarButtonSpellActivationAlert")
|
||||
frame_alert.alert:SetFrameStrata ("FULLSCREEN")
|
||||
frame_alert.alert:SetFrameStrata("FULLSCREEN")
|
||||
frame_alert.alert:Hide()
|
||||
|
||||
local window_openned_at = time()
|
||||
@@ -296,15 +296,15 @@ local window_openned_at = time()
|
||||
|
||||
--skin
|
||||
local onSelectSkin = function(_, _, skin_name)
|
||||
local instance1 = _detalhes:GetInstance (1)
|
||||
local instance1 = _detalhes:GetInstance(1)
|
||||
if (instance1 and instance1:IsEnabled()) then
|
||||
instance1:ChangeSkin (skin_name)
|
||||
window.FontDropdown:Select (instance1.row_info.font_face)
|
||||
window.FontDropdown:Select(instance1.row_info.font_face)
|
||||
window.BarHeightSlider:SetValue(instance1.row_info.height)
|
||||
window.TextSizeSlider:SetValue(instance1.row_info.font_size)
|
||||
window.ShowPercentCheckBox:SetValue(instance1.row_info.textR_show_data [3])
|
||||
end
|
||||
local instance2 = _detalhes:GetInstance (2)
|
||||
local instance2 = _detalhes:GetInstance(2)
|
||||
if (instance2 and instance2:IsEnabled()) then
|
||||
instance2:ChangeSkin (skin_name)
|
||||
end
|
||||
@@ -312,13 +312,13 @@ local window_openned_at = time()
|
||||
|
||||
local buildSkinMenu = function()
|
||||
local skinOptions = {}
|
||||
for skin_name, skin_table in pairs (_detalhes.skins) do
|
||||
for skin_name, skin_table in pairs(_detalhes.skins) do
|
||||
skinOptions [#skinOptions+1] = {value = skin_name, label = skin_name, onclick = onSelectSkin, icon = "Interface\\GossipFrame\\TabardGossipIcon", desc = skin_table.desc}
|
||||
end
|
||||
return skinOptions
|
||||
end
|
||||
|
||||
local instance1 = _detalhes:GetInstance (1)
|
||||
local instance1 = _detalhes:GetInstance(1)
|
||||
local skin_dropdown = g:NewDropDown (window, _, "$parentSkinDropdown", "skinDropdown", 160, 20, buildSkinMenu, instance1.skin)
|
||||
skin_dropdown:SetTemplate (g:GetTemplate ("dropdown", "OPTIONS_DROPDOWN_TEMPLATE"))
|
||||
skin_dropdown.tooltip = Loc ["STRING_WELCOME_58"]
|
||||
@@ -353,8 +353,8 @@ local window_openned_at = time()
|
||||
end
|
||||
end
|
||||
|
||||
local instance1 = Details:GetInstance (1)
|
||||
local instance2 = Details:GetInstance (2)
|
||||
local instance1 = Details:GetInstance(1)
|
||||
local instance2 = Details:GetInstance(2)
|
||||
|
||||
_detalhes.tabela_historico:resetar()
|
||||
|
||||
@@ -366,7 +366,7 @@ local window_openned_at = time()
|
||||
instance2:SetBarTextSettings (nil, "Accidental Presidency")
|
||||
end
|
||||
|
||||
window.FontDropdown:Select ("Accidental Presidency")
|
||||
window.FontDropdown:Select("Accidental Presidency")
|
||||
|
||||
_detalhes:CreateTestBars ("en")
|
||||
|
||||
@@ -378,7 +378,7 @@ local window_openned_at = time()
|
||||
instance2:SetBarTextSettings (nil, "Arial Narrow")
|
||||
end
|
||||
|
||||
window.FontDropdown:Select ("Arial Narrow")
|
||||
window.FontDropdown:Select("Arial Narrow")
|
||||
|
||||
_detalhes:CreateTestBars ("ru")
|
||||
|
||||
@@ -390,7 +390,7 @@ local window_openned_at = time()
|
||||
instance2:SetBarTextSettings (nil, "AR CrystalzcuheiGBK Demibold")
|
||||
end
|
||||
|
||||
window.FontDropdown:Select ("AR CrystalzcuheiGBK Demibold")
|
||||
window.FontDropdown:Select("AR CrystalzcuheiGBK Demibold")
|
||||
|
||||
_detalhes:CreateTestBars ("cn")
|
||||
|
||||
@@ -402,7 +402,7 @@ local window_openned_at = time()
|
||||
instance2:SetBarTextSettings (nil, "2002")
|
||||
end
|
||||
|
||||
window.FontDropdown:Select ("2002")
|
||||
window.FontDropdown:Select("2002")
|
||||
|
||||
_detalhes:CreateTestBars ("ko")
|
||||
|
||||
@@ -414,7 +414,7 @@ local window_openned_at = time()
|
||||
instance2:SetBarTextSettings (nil, "AR CrystalzcuheiGBK Demibold")
|
||||
end
|
||||
|
||||
window.FontDropdown:Select ("AR CrystalzcuheiGBK Demibold")
|
||||
window.FontDropdown:Select("AR CrystalzcuheiGBK Demibold")
|
||||
|
||||
_detalhes:CreateTestBars ("tw")
|
||||
end
|
||||
@@ -425,57 +425,57 @@ local window_openned_at = time()
|
||||
g:NewLabel(window, _, "$parentLatinAlphabetLabel", "LatinAlphabetLabel", Loc["STRING_WELCOME_74"], "GameFontHighlightLeft")
|
||||
g:NewSwitch (window, _, "$parentLatinAlphabetCheckBox", "LatinAlphabetCheckBox", 20, 20, _, _, true)
|
||||
window.LatinAlphabetCheckBox:SetAsCheckBox()
|
||||
window.LatinAlphabetCheckBox:SetFixedParameter (1)
|
||||
window.LatinAlphabetCheckBox:SetFixedParameter(1)
|
||||
window.LatinAlphabetCheckBox:SetTemplate (g:GetTemplate ("switch", "OPTIONS_CHECKBOX_TEMPLATE"))
|
||||
window.LatinAlphabetCheckBox.OnSwitch = onSelectAlphabet
|
||||
window.LatinAlphabetLabel:SetPoint("left", window.LatinAlphabetCheckBox, "right", 2, 0)
|
||||
|
||||
tinsert (allAlphabetCheckBoxes, window.LatinAlphabetCheckBox)
|
||||
tinsert (allAlphabetLabels, window.LatinAlphabetLabel)
|
||||
tinsert(allAlphabetCheckBoxes, window.LatinAlphabetCheckBox)
|
||||
tinsert(allAlphabetLabels, window.LatinAlphabetLabel)
|
||||
|
||||
--Russian
|
||||
g:NewLabel(window, _, "$parentCyrillicAlphabetLabel", "CyrillicAlphabetLabel", Loc["STRING_WELCOME_75"], "GameFontHighlightLeft")
|
||||
g:NewSwitch (window, _, "$parentCyrillicAlphabetCheckBox", "CyrillicAlphabetCheckBox", 20, 20, _, _, false)
|
||||
window.CyrillicAlphabetCheckBox:SetAsCheckBox()
|
||||
window.CyrillicAlphabetCheckBox:SetFixedParameter (2)
|
||||
window.CyrillicAlphabetCheckBox:SetFixedParameter(2)
|
||||
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)
|
||||
tinsert(allAlphabetCheckBoxes, window.CyrillicAlphabetCheckBox)
|
||||
tinsert(allAlphabetLabels, window.CyrillicAlphabetLabel)
|
||||
|
||||
--Chinese
|
||||
g:NewLabel(window, _, "$parentChinaAlphabetLabel", "ChinaAlphabetLabel", Loc["STRING_WELCOME_76"], "GameFontHighlightLeft")
|
||||
g:NewSwitch (window, _, "$parentChinaCheckBox", "ChinaCheckBox", 20, 20, _, _, false)
|
||||
window.ChinaCheckBox:SetAsCheckBox()
|
||||
window.ChinaCheckBox:SetFixedParameter (3)
|
||||
window.ChinaCheckBox:SetFixedParameter(3)
|
||||
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)
|
||||
tinsert(allAlphabetCheckBoxes, window.ChinaCheckBox)
|
||||
tinsert(allAlphabetLabels, window.ChinaAlphabetLabel)
|
||||
|
||||
--Korea
|
||||
g:NewLabel(window, _, "$parentKoreanAlphabetLabel", "KoreanAlphabetLabel", Loc["STRING_WELCOME_77"], "GameFontHighlightLeft")
|
||||
g:NewSwitch (window, _, "$parentKoreanCheckBox", "KoreanCheckBox", 20, 20, _, _, false)
|
||||
window.KoreanCheckBox:SetAsCheckBox()
|
||||
window.KoreanCheckBox:SetFixedParameter (4)
|
||||
window.KoreanCheckBox:SetFixedParameter(4)
|
||||
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)
|
||||
tinsert(allAlphabetCheckBoxes, window.KoreanCheckBox)
|
||||
tinsert(allAlphabetLabels, window.KoreanAlphabetLabel)
|
||||
|
||||
--Taiwan
|
||||
g:NewLabel(window, _, "$parentTaiwanAlphabetLabel", "TaiwanAlphabetLabel", Loc["STRING_WELCOME_78"], "GameFontHighlightLeft")
|
||||
g:NewSwitch (window, _, "$parentTaiwanCheckBox", "TaiwanCheckBox", 20, 20, _, _, false)
|
||||
window.TaiwanCheckBox:SetAsCheckBox()
|
||||
window.TaiwanCheckBox:SetFixedParameter (5)
|
||||
window.TaiwanCheckBox:SetFixedParameter(5)
|
||||
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)
|
||||
tinsert(allAlphabetCheckBoxes, window.TaiwanCheckBox)
|
||||
tinsert(allAlphabetLabels, window.TaiwanAlphabetLabel)
|
||||
|
||||
window.LatinAlphabetCheckBox:SetPoint("topleft", texto_alphabet, "bottomleft", 0, -10)
|
||||
window.CyrillicAlphabetCheckBox:SetPoint("topleft", window.LatinAlphabetCheckBox, "bottomleft", 0, -2)
|
||||
@@ -537,14 +537,14 @@ local window_openned_at = time()
|
||||
end
|
||||
end
|
||||
|
||||
local instance2 = _detalhes:GetInstance (2)
|
||||
local instance2 = _detalhes:GetInstance(2)
|
||||
if (instance2 and instance2:IsEnabled()) then
|
||||
instance2:InstanceColor (r, g, b, a, nil, true)
|
||||
end
|
||||
end
|
||||
|
||||
local change_color = function()
|
||||
window.editing_window = _detalhes:GetInstance (1)
|
||||
window.editing_window = _detalhes:GetInstance(1)
|
||||
local r, g, b, a = unpack (window.editing_window.color)
|
||||
_detalhes.gump:ColorPick (window, r, g, b, a, windowcolor_callback)
|
||||
end
|
||||
@@ -563,8 +563,8 @@ local window_openned_at = time()
|
||||
window.BarHeightSlider:SetTemplate (g:GetTemplate ("slider", "OPTIONS_SLIDER_TEMPLATE"))
|
||||
|
||||
window.BarHeightSlider:SetHook("OnValueChange", function(self, _, amount)
|
||||
local instance1 = Details:GetInstance (1)
|
||||
local instance2 = Details:GetInstance (2)
|
||||
local instance1 = Details:GetInstance(1)
|
||||
local instance2 = Details:GetInstance(2)
|
||||
|
||||
if (instance1 and instance1:IsEnabled()) then
|
||||
instance1:SetBarSettings (amount)
|
||||
@@ -583,8 +583,8 @@ local window_openned_at = time()
|
||||
window.TextSizeSlider:SetTemplate (g:GetTemplate ("slider", "OPTIONS_SLIDER_TEMPLATE"))
|
||||
|
||||
window.TextSizeSlider:SetHook("OnValueChange", function(self, _, amount)
|
||||
local instance1 = Details:GetInstance (1)
|
||||
local instance2 = Details:GetInstance (2)
|
||||
local instance1 = Details:GetInstance(1)
|
||||
local instance2 = Details:GetInstance(2)
|
||||
|
||||
if (instance1 and instance1:IsEnabled()) then
|
||||
instance1:SetBarTextSettings (amount)
|
||||
@@ -596,8 +596,8 @@ local window_openned_at = time()
|
||||
|
||||
--font
|
||||
local onSelectFont = function(_, instance, fontName)
|
||||
local instance1 = Details:GetInstance (1)
|
||||
local instance2 = Details:GetInstance (2)
|
||||
local instance1 = Details:GetInstance(1)
|
||||
local instance2 = Details:GetInstance(2)
|
||||
|
||||
if (instance1 and instance1:IsEnabled()) then
|
||||
instance1:SetBarTextSettings (nil, fontName)
|
||||
@@ -610,14 +610,14 @@ local window_openned_at = time()
|
||||
local buildFontMenu = function()
|
||||
local fontObjects = SharedMedia:HashTable ("font")
|
||||
local fontTable = {}
|
||||
for name, fontPath in pairs (fontObjects) do
|
||||
for name, fontPath in pairs(fontObjects) do
|
||||
fontTable[#fontTable+1] = {value = name, label = name, icon = font_select_icon, texcoord = font_select_texcoord, onclick = onSelectFont, font = fontPath, descfont = name, desc = Loc ["STRING_MUSIC_DETAILS_ROBERTOCARLOS"]}
|
||||
end
|
||||
table.sort (fontTable, function(t1, t2) return t1.label < t2.label end)
|
||||
return fontTable
|
||||
end
|
||||
|
||||
local instance1 = _detalhes:GetInstance (1)
|
||||
local instance1 = _detalhes:GetInstance(1)
|
||||
local font_dropdown = g:NewDropDown (window, _, "$parentFontDropdown", "FontDropdown", 160, 20, buildFontMenu, instance1.row_info.font_face)
|
||||
font_dropdown:SetTemplate (g:GetTemplate ("dropdown", "OPTIONS_DROPDOWN_TEMPLATE"))
|
||||
font_dropdown.tooltip = Loc ["STRING_WELCOME_58"]
|
||||
@@ -630,12 +630,12 @@ local window_openned_at = time()
|
||||
g:NewLabel(window, _, "$parentShowPercentLabel", "ShowPercentLabel", Loc ["STRING_OPTIONS_TEXT_SHOW_PERCENT"], "GameFontNormal")
|
||||
g:NewSwitch (window, _, "$parentShowPercentCheckBox", "ShowPercentCheckBox", 20, 20, _, _, false)
|
||||
window.ShowPercentCheckBox:SetAsCheckBox()
|
||||
window.ShowPercentCheckBox:SetFixedParameter (1)
|
||||
window.ShowPercentCheckBox:SetFixedParameter(1)
|
||||
window.ShowPercentCheckBox:SetTemplate (g:GetTemplate ("switch", "OPTIONS_CHECKBOX_TEMPLATE"))
|
||||
|
||||
window.ShowPercentCheckBox.OnSwitch = function(self, fixedParameter, value)
|
||||
local instance1 = Details:GetInstance (1)
|
||||
local instance2 = Details:GetInstance (2)
|
||||
local instance1 = Details:GetInstance(1)
|
||||
local instance2 = Details:GetInstance(2)
|
||||
|
||||
if (instance1 and instance1:IsEnabled()) then
|
||||
instance1:SetBarRightTextSettings (nil, nil, value)
|
||||
@@ -677,10 +677,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)
|
||||
tinsert(pages [#pages], widget)
|
||||
end
|
||||
for i, widget in ipairs(allAlphabetLabels) do
|
||||
tinsert (pages [#pages], widget)
|
||||
tinsert(pages [#pages], widget)
|
||||
end
|
||||
|
||||
for _, widget in ipairs(pages[#pages]) do
|
||||
@@ -712,7 +712,7 @@ local window_openned_at = time()
|
||||
g:NewLabel(window, _, "$parentWesternNumbersLabel", "WesternNumbersLabel", Loc ["STRING_NUMERALSYSTEM_ARABIC_WESTERN"] .. ": " .. Loc ["STRING_NUMERALSYSTEM_ARABIC_WESTERN_DESC"], "GameFontHighlightLeft")
|
||||
local WesternNumbersCheckbox = g:NewSwitch (window, _, "WesternNumbersCheckbox", "WesternNumbersCheckbox", 20, 20, _, _, true)
|
||||
WesternNumbersCheckbox:SetAsCheckBox()
|
||||
WesternNumbersCheckbox:SetFixedParameter (1)
|
||||
WesternNumbersCheckbox:SetFixedParameter(1)
|
||||
WesternNumbersCheckbox:SetTemplate (g:GetTemplate ("switch", "OPTIONS_CHECKBOX_TEMPLATE"))
|
||||
WesternNumbersCheckbox:SetPoint("topleft", window, "topleft", 40, -130)
|
||||
window.WesternNumbersLabel:SetPoint("left", WesternNumbersCheckbox, "right", 2, 0)
|
||||
@@ -721,7 +721,7 @@ local window_openned_at = time()
|
||||
g:NewLabel(window, _, "$parentAsianNumbersLabel", "AsianNumbersLabel", Loc ["STRING_NUMERALSYSTEM_MYRIAD_EASTASIA"] .. ": " .. Loc ["STRING_NUMERALSYSTEM_ARABIC_MYRIAD_EASTASIA"], "GameFontHighlightLeft")
|
||||
local AsianNumbersCheckbox = g:NewSwitch (window, _, "AsianNumbersCheckbox", "AsianNumbersCheckbox", 20, 20, _, _, true)
|
||||
AsianNumbersCheckbox:SetAsCheckBox()
|
||||
AsianNumbersCheckbox:SetFixedParameter (2)
|
||||
AsianNumbersCheckbox:SetFixedParameter(2)
|
||||
AsianNumbersCheckbox:SetTemplate (g:GetTemplate ("switch", "OPTIONS_CHECKBOX_TEMPLATE"))
|
||||
AsianNumbersCheckbox:SetPoint("topleft", window, "topleft", 40, -200)
|
||||
window.AsianNumbersLabel:SetPoint("left", AsianNumbersCheckbox, "right", 2, 0)
|
||||
@@ -831,7 +831,7 @@ local window_openned_at = time()
|
||||
g:NewLabel(window, _, "$parentChronometerLabel", "ChronometerLabel", Loc ["STRING_WELCOME_4"], "GameFontHighlightLeft")
|
||||
local chronometer = g:NewSwitch (window, _, "WelcomeWindowChronometer", "WelcomeWindowChronometer", 20, 20, _, _, true)
|
||||
chronometer:SetAsCheckBox()
|
||||
chronometer:SetFixedParameter (1)
|
||||
chronometer:SetFixedParameter(1)
|
||||
chronometer:SetTemplate (g:GetTemplate ("switch", "OPTIONS_CHECKBOX_TEMPLATE"))
|
||||
window.ChronometerLabel:SetPoint("left", chronometer, "right", 2, 0)
|
||||
|
||||
@@ -839,7 +839,7 @@ local window_openned_at = time()
|
||||
g:NewLabel(window, _, "$parentContinuousLabel", "ContinuousLabel", Loc ["STRING_WELCOME_5"], "GameFontHighlightLeft")
|
||||
local continuous = g:NewSwitch (window, _, "WelcomeWindowContinuous", "WelcomeWindowContinuous", 20, 20, _, _, true)
|
||||
continuous:SetAsCheckBox()
|
||||
continuous:SetFixedParameter (1)
|
||||
continuous:SetFixedParameter(1)
|
||||
continuous:SetTemplate (g:GetTemplate ("switch", "OPTIONS_CHECKBOX_TEMPLATE"))
|
||||
window.ContinuousLabel:SetPoint("left", continuous, "right", 2, 0)
|
||||
|
||||
@@ -1092,7 +1092,7 @@ local window_openned_at = time()
|
||||
created_test_bars = created_test_bars + 1
|
||||
end
|
||||
|
||||
local instance = _detalhes:GetInstance (1)
|
||||
local instance = _detalhes:GetInstance(1)
|
||||
instance:SetMode (3)
|
||||
end)
|
||||
|
||||
@@ -1150,7 +1150,7 @@ local window_openned_at = time()
|
||||
_detalhes:StopPlayStretchAlert()
|
||||
end)
|
||||
stretch_frame_alert:SetScript("OnShow", function()
|
||||
local instance = _detalhes:GetInstance (1)
|
||||
local instance = _detalhes:GetInstance(1)
|
||||
_detalhes.OnEnterMainWindow(instance)
|
||||
instance.baseframe.button_stretch:SetAlpha (1)
|
||||
frame_alert.alert:SetPoint("topleft", instance.baseframe.button_stretch, "topleft", -20, 6)
|
||||
@@ -1208,7 +1208,7 @@ local window_openned_at = time()
|
||||
_detalhes:StopPlayStretchAlert()
|
||||
end)
|
||||
instance_frame_alert:SetScript("OnShow", function()
|
||||
local instance = _detalhes:GetInstance (1)
|
||||
local instance = _detalhes:GetInstance(1)
|
||||
|
||||
frame_alert.alert:SetPoint("topleft", instance.baseframe.cabecalho.modo_selecao.widget, "topleft", -8, 6)
|
||||
frame_alert.alert:SetPoint("bottomright", instance.baseframe.cabecalho.modo_selecao.widget, "bottomright", 8, -6)
|
||||
@@ -1260,7 +1260,7 @@ local window_openned_at = time()
|
||||
shortcut_image2:SetTexCoord (2/512, 167/512, 306/512, 425/512)
|
||||
|
||||
|
||||
local instance1 = _detalhes:GetInstance (1)
|
||||
local instance1 = _detalhes:GetInstance(1)
|
||||
|
||||
local bookmark_frame = CreateFrame("frame", "WelcomeBookmarkFrame", window,"BackdropTemplate")
|
||||
bookmark_frame:SetPoint("topleft", instance1.baseframe, "topleft")
|
||||
@@ -1285,7 +1285,7 @@ local window_openned_at = time()
|
||||
|
||||
bookmark_frame:SetScript("OnMouseDown", function(self, button)
|
||||
if (button == "RightButton") then
|
||||
_detalhes.switch:ShowMe (instance1)
|
||||
_detalhes.switch:ShowMe(instance1)
|
||||
self:Hide()
|
||||
end
|
||||
end)
|
||||
|
||||
Reference in New Issue
Block a user