Small bug fixes and improvements

This commit is contained in:
Tercio Jose
2022-10-10 13:26:13 -03:00
parent b588d5e30c
commit 1ed29008aa
119 changed files with 6556 additions and 6650 deletions
+15 -15
View File
@@ -103,7 +103,7 @@ function _detalhes.PlayBestDamageOnGuild (damage)
BaseTexture:SetDrawLayer ("ARTWORK", -5)
BaseTexture:SetPoint("center", DetailsNewDamageRecord, "center", 0, 0)
BaseTexture:SetSize(256, 64)
BaseTexture:SetVertexColor (0.99999779462814, 0.99999779462814, 0.99999779462814, 0.99999779462814)
BaseTexture:SetVertexColor(0.99999779462814, 0.99999779462814, 0.99999779462814, 0.99999779462814)
--animations for BaseTexture
@@ -131,13 +131,13 @@ function _detalhes.PlayBestDamageOnGuild (damage)
BigFlash:SetDrawLayer ("OVERLAY", 0)
BigFlash:SetPoint("center", DetailsNewDamageRecord, "center", -2, 2)
BigFlash:SetSize(314, 100)
BigFlash:SetDesaturated (false)
BigFlash:SetDesaturated(false)
BigFlash:SetTexCoord (0.0010000000149012, 0.77400001525879, 0.0010000000149012, 0.65800003051758)
if (0 ~= 0) then
BigFlash:SetRotation (0)
end
BigFlash:SetVertexColor (0.96470373868942, 0.98823314905167, 0.99999779462814, 0.99999779462814)
BigFlash:SetAlpha (1)
BigFlash:SetVertexColor(0.96470373868942, 0.98823314905167, 0.99999779462814, 0.99999779462814)
BigFlash:SetAlpha(1)
BigFlash:SetBlendMode("ADD")
--animations for BigFlash
@@ -166,13 +166,13 @@ function _detalhes.PlayBestDamageOnGuild (damage)
FlashSwipe:SetDrawLayer ("OVERLAY", 7)
FlashSwipe:SetPoint("center", DetailsNewDamageRecord, "center", -99, 0)
FlashSwipe:SetSize(100, 57)
FlashSwipe:SetDesaturated (false)
FlashSwipe:SetDesaturated(false)
FlashSwipe:SetTexCoord (0.78199996948242, 0.91900001525879, 0.0010000000149012, 0.2760000038147)
if (0 ~= 0) then
FlashSwipe:SetRotation (0)
end
FlashSwipe:SetVertexColor (0.86666476726532, 0.54117530584335, 0, 0.99999779462814)
FlashSwipe:SetAlpha (1)
FlashSwipe:SetVertexColor(0.86666476726532, 0.54117530584335, 0, 0.99999779462814)
FlashSwipe:SetAlpha(1)
FlashSwipe:SetBlendMode("ADD")
--animations for FlashSwipe
@@ -208,13 +208,13 @@ function _detalhes.PlayBestDamageOnGuild (damage)
Portrait:SetDrawLayer ("OVERLAY", -5)
Portrait:SetPoint("center", DetailsNewDamageRecord, "center", 3, 0)
Portrait:SetSize(246, 44)
Portrait:SetDesaturated (false)
Portrait:SetDesaturated(false)
Portrait:SetTexCoord (0.051753740310669, 0.81701484680176, 0.086334381103516, 0.25102617263794)
if (0 ~= 0) then
Portrait:SetRotation (0)
end
Portrait:SetVertexColor (0.99999779462814, 0.99999779462814, 0.99999779462814, 0.99999779462814)
Portrait:SetAlpha (1)
Portrait:SetVertexColor(0.99999779462814, 0.99999779462814, 0.99999779462814, 0.99999779462814)
Portrait:SetAlpha(1)
Portrait:SetBlendMode("BLEND")
--animations for Portrait
@@ -259,13 +259,13 @@ function _detalhes.PlayBestDamageOnGuild (damage)
DamageIcon:SetDrawLayer ("OVERLAY", 2)
DamageIcon:SetPoint("center", DetailsNewDamageRecord, "center", -97, 1)
DamageIcon:SetSize(32, 32)
DamageIcon:SetDesaturated (false)
DamageIcon:SetDesaturated(false)
DamageIcon:SetTexCoord (0.27200000762939, 0.51899997711182, 0.25837841033936, 0.51399997711182)
if (0 ~= 0) then
DamageIcon:SetRotation (0)
end
DamageIcon:SetVertexColor (0.99999779462814, 0.99999779462814, 0.99999779462814, 0.99999779462814)
DamageIcon:SetAlpha (1)
DamageIcon:SetVertexColor(0.99999779462814, 0.99999779462814, 0.99999779462814, 0.99999779462814)
DamageIcon:SetAlpha(1)
DamageIcon:SetBlendMode("BLEND")
--animations for DamageIcon
@@ -296,7 +296,7 @@ function _detalhes.PlayBestDamageOnGuild (damage)
NewDamageRecord:SetPoint("center", DetailsNewDamageRecord, "center", 18, 7)
NewDamageRecord:SetSize(181, 20)
NewDamageRecord:SetTextColor (1, 1, 1)
NewDamageRecord:SetAlpha (1)
NewDamageRecord:SetAlpha(1)
NewDamageRecord:SetJustifyH("CENTER")
--animations for NewDamageRecord
@@ -335,7 +335,7 @@ function _detalhes.PlayBestDamageOnGuild (damage)
DamageAmount:SetPoint("center", DetailsNewDamageRecord, "center", 18, -7)
DamageAmount:SetSize(100, 20)
DamageAmount:SetTextColor (1, 1, 1)
DamageAmount:SetAlpha (1)
DamageAmount:SetAlpha(1)
DamageAmount:SetJustifyH("CENTER")
--animations for DamageAmount
+6 -6
View File
@@ -28,7 +28,7 @@ function gump:NewLabel2 (parent, container, member, text, font, size, color)
end
if (color) then
newFontString:SetTextColor (unpack (color))
newFontString:SetTextColor (unpack(color))
end
newFontString:SetJustifyH("LEFT")
@@ -78,7 +78,7 @@ function gump:NewDetailsButton (parent, container, instancia, func, param1, para
new_button.supportFrame = CreateFrame("frame", nil, new_button)
new_button.supportFrame:SetPoint("topleft", new_button, "topleft")
new_button.supportFrame:SetPoint("bottomright", new_button, "bottomright")
new_button.supportFrame:SetFrameLevel (new_button:GetFrameLevel()+1)
new_button.supportFrame:SetFrameLevel(new_button:GetFrameLevel()+1)
new_button.supportFrame.disable_overlay = new_button.supportFrame:CreateTexture(nil, "overlay")
new_button.supportFrame.disable_overlay:SetTexture("Interface\\AddOns\\Details\\images\\button_disable_overlay")
@@ -189,7 +189,7 @@ function gump:NewDetailsButton (parent, container, instancia, func, param1, para
GameCooltip:Reset()
GameCooltip:SetType ("tooltip")
GameCooltip:SetColor ("main", "transparent")
GameCooltip:AddLine (new_button.tooltip)
GameCooltip:AddLine(new_button.tooltip)
GameCooltip:SetOwner(new_button)
GameCooltip:ShowCooltip()
end
@@ -270,7 +270,7 @@ function gump:NewTextBox (parent, container, member, func, param1, param2, w, h,
editbox:SetWidth(w)
editbox:SetHeight(h)
editbox:SetJustifyH("CENTER")
editbox:EnableMouse (true)
editbox:EnableMouse(true)
editbox:SetBackdrop(EditBoxBackdrop)
editbox:SetBackdropColor(0, 0, 0, 0.5)
editbox:SetBackdropBorderColor(0.3, 0.3, 0.30, 0.80)
@@ -374,7 +374,7 @@ function gump:NewTextBox (parent, container, member, func, param1, param2, w, h,
GameCooltip:Reset()
GameCooltip:SetType ("tooltip")
GameCooltip:SetColor ("main", "transparent")
GameCooltip:AddLine (editbox.tooltip)
GameCooltip:AddLine(editbox.tooltip)
GameCooltip:SetOwner(editbox)
GameCooltip:ShowCooltip()
end
@@ -690,7 +690,7 @@ function gump:NewScrollBar2 (master, slave, x, y)
self.scrollMax = slave:GetHeight()-master:GetHeight()
if (self.scrollMax > 0) then
slider_gump:SetMinMaxValues (0, self.scrollMax)
slider_gump:SetMinMaxValues(0, self.scrollMax)
if (not slider_gump.ativo) then
slider_gump:Enable()
slider_gump.ativo = true
+19 -19
View File
@@ -24,12 +24,12 @@ function Details:CreateAPI2Frame()
local parametersAmount = 10
local returnAmount = 10
--local Api2Frame = DetailsFramework:CreateSimplePanel (UIParent, panelWidth, panelHeight, "Details! API 2.0", "DetailsAPI2Frame")
--local Api2Frame = DetailsFramework:CreateSimplePanel(UIParent, panelWidth, panelHeight, "Details! API 2.0", "DetailsAPI2Frame")
local Api2Frame = _G.DetailsAPI2Frame
Api2Frame:SetFrameStrata("FULLSCREEN")
Api2Frame:SetPoint("center")
DetailsFramework:ApplyStandardBackdrop (Api2Frame, false, 1.2)
DetailsFramework:ApplyStandardBackdrop(Api2Frame, false, 1.2)
--store
local apiFunctionNames = {}
@@ -134,9 +134,9 @@ function Details:CreateAPI2Frame()
line.index = index
if (currentSelected == index) then
line:SetBackdropColor(unpack (backdropColorSelected))
line:SetBackdropColor(unpack(backdropColorSelected))
else
line:SetBackdropColor(unpack (backdropColor))
line:SetBackdropColor(unpack(backdropColor))
end
end
end
@@ -152,7 +152,7 @@ function Details:CreateAPI2Frame()
Api2Frame.scrollMenu = api2ScrollMenu
local lineOnEnter = function(self)
self:SetBackdropColor(unpack (backdropColorOnEnter))
self:SetBackdropColor(unpack(backdropColorOnEnter))
local apiName = apiFunctionNames [self.index]
if (not apiName) then
@@ -167,15 +167,15 @@ function Details:CreateAPI2Frame()
GameCooltip2:Preset(2)
GameCooltip2:SetOwner(self, "left", "right", 2, 0)
GameCooltip2:AddLine (apiInfo.desc)
GameCooltip2:AddLine(apiInfo.desc)
GameCooltip2:ShowCooltip()
end
local lineOnLeave = function(self)
if (currentSelected == self.index) then
self:SetBackdropColor(unpack (backdropColorSelected))
self:SetBackdropColor(unpack(backdropColorSelected))
else
self:SetBackdropColor(unpack (backdropColor))
self:SetBackdropColor(unpack(backdropColor))
end
GameCooltip2:Hide()
@@ -193,7 +193,7 @@ function Details:CreateAPI2Frame()
line:SetScript("OnLeave", lineOnLeave)
line:SetBackdrop({bgFile = [[Interface\Tooltips\UI-Tooltip-Background]], tileSize = 64, tile = true})
line:SetBackdropColor(unpack (backdropColor))
line:SetBackdropColor(unpack(backdropColor))
line.text = DetailsFramework:CreateLabel(line)
line.text:SetPoint("left", line, "left", 2, 0)
@@ -221,7 +221,7 @@ function Details:CreateAPI2Frame()
apiCopyString:SetPoint("topleft", Api2Frame.ApiFunctionDesc, "bottomleft", 0, -20)
Api2Frame.ApiCopy = DetailsFramework:CreateTextEntry (Api2Frame, function() end, infoWidth, 20)
Api2Frame.ApiCopy:SetPoint("topleft", apiCopyString, "bottomleft", 0, -2)
Api2Frame.ApiCopy:SetTemplate (DetailsFramework:GetTemplate ("button", "DETAILS_CUSTOMDISPLAY_CODE_BOX"))
Api2Frame.ApiCopy:SetTemplate(DetailsFramework:GetTemplate("button", "DETAILS_CUSTOMDISPLAY_CODE_BOX"))
--parameters
local parametersYStart = yStart - 110
@@ -235,7 +235,7 @@ function Details:CreateAPI2Frame()
parametersHeader:SetSize(infoWidth, 20)
parametersHeader:SetPoint("topleft", Api2Frame, "topleft", xAnchorPoint, parametersYStart)
parametersHeader:SetBackdrop({bgFile = [[Interface\Tooltips\UI-Tooltip-Background]], tileSize = 64, tile = true})
parametersHeader:SetBackdropColor(unpack (backdropColor))
parametersHeader:SetBackdropColor(unpack(backdropColor))
parametersHeader.name = DetailsFramework:CreateLabel(parametersHeader, "Name", 12, "yellow")
parametersHeader.typeData = DetailsFramework:CreateLabel(parametersHeader, "Type", 12, "yellow")
parametersHeader.required = DetailsFramework:CreateLabel(parametersHeader, "Is Required", 12, "yellow")
@@ -254,14 +254,14 @@ function Details:CreateAPI2Frame()
if (not apiInfo) then
return
end
GameCooltip2:AddLine (apiInfo.parameters [self.index].desc)
GameCooltip2:AddLine(apiInfo.parameters [self.index].desc)
GameCooltip2:ShowCooltip()
self:SetBackdropColor(unpack (backdropColorOnEnter))
self:SetBackdropColor(unpack(backdropColorOnEnter))
end
local parameterOnLeave = function(self)
GameCooltip2:Hide()
self:SetBackdropColor(unpack (backdropColor))
self:SetBackdropColor(unpack(backdropColor))
end
for i = 1, parametersAmount do
@@ -271,7 +271,7 @@ function Details:CreateAPI2Frame()
f:SetScript("OnEnter", parameterOnEnter)
f:SetScript("OnLeave", parameterOnLeave)
f:SetBackdrop({bgFile = [[Interface\Tooltips\UI-Tooltip-Background]], tileSize = 64, tile = true})
f:SetBackdropColor(unpack (backdropColor))
f:SetBackdropColor(unpack(backdropColor))
f:Hide()
f.name = DetailsFramework:CreateLabel(f)
@@ -301,17 +301,17 @@ function Details:CreateAPI2Frame()
returnHeader:SetSize(infoWidth, 20)
returnHeader:SetPoint("topleft", Api2Frame, "topleft", xAnchorPoint, returnYStart)
returnHeader:SetBackdrop({bgFile = [[Interface\Tooltips\UI-Tooltip-Background]], tileSize = 64, tile = true})
returnHeader:SetBackdropColor(unpack (backdropColor))
returnHeader:SetBackdropColor(unpack(backdropColor))
returnHeader.name = DetailsFramework:CreateLabel(returnHeader, "Name", 12, "yellow")
returnHeader.typeData = DetailsFramework:CreateLabel(returnHeader, "Type", 12, "yellow")
returnHeader.name:SetPoint("left", returnHeader, "left", 2, 0)
returnHeader.typeData:SetPoint("left", returnHeader, "left", space1, 0)
local returnOnEnter = function(self)
self:SetBackdropColor(unpack (backdropColorOnEnter))
self:SetBackdropColor(unpack(backdropColorOnEnter))
end
local returnOnLeave = function(self)
self:SetBackdropColor(unpack (backdropColor))
self:SetBackdropColor(unpack(backdropColor))
end
for i = 1, returnAmount do
@@ -321,7 +321,7 @@ function Details:CreateAPI2Frame()
f:SetScript("OnEnter", returnOnEnter)
f:SetScript("OnLeave", returnOnLeave)
f:SetBackdrop({bgFile = [[Interface\Tooltips\UI-Tooltip-Background]], tileSize = 64, tile = true})
f:SetBackdropColor(unpack (backdropColor))
f:SetBackdropColor(unpack(backdropColor))
f:Hide()
f.name = DetailsFramework:CreateLabel(f)
+21 -21
View File
@@ -20,18 +20,18 @@ local libwindow = LibStub("LibWindow-1.1")
f:SetSize(800, 600)
f:SetPoint("left", UIParent, "left")
f:SetFrameStrata("LOW")
f:EnableMouse (true)
f:SetMovable (true)
f:EnableMouse(true)
f:SetMovable(true)
f:SetBackdrop({edgeFile = [[Interface\Buttons\WHITE8X8]], edgeSize = 1, bgFile = [[Interface\Tooltips\UI-Tooltip-Background]], tileSize = 64, tile = true})
f:SetBackdropColor(0, 0, 0, 0.9)
f:SetBackdropBorderColor(0, 0, 0, 1)
--register to libwindow
local LibWindow = LibStub ("LibWindow-1.1")
LibWindow.RegisterConfig (f, _detalhes.benchmark_db.frame)
LibWindow.RestorePosition (f)
LibWindow.MakeDraggable (f)
LibWindow.SavePosition (f)
local LibWindow = LibStub("LibWindow-1.1")
LibWindow.RegisterConfig(f, _detalhes.benchmark_db.frame)
LibWindow.RestorePosition(f)
LibWindow.MakeDraggable(f)
LibWindow.SavePosition(f)
--titlebar
f.TitleBar = CreateFrame("frame", "$parentTitleBar", f,"BackdropTemplate")
@@ -52,7 +52,7 @@ local libwindow = LibStub("LibWindow-1.1")
f.Close:GetNormalTexture():SetTexCoord (0, 16/128, 0, 1)
f.Close:GetHighlightTexture():SetTexCoord (0, 16/128, 0, 1)
f.Close:GetPushedTexture():SetTexCoord (0, 16/128, 0, 1)
f.Close:SetAlpha (0.7)
f.Close:SetAlpha(0.7)
f.Close:SetScript("OnClick", function() f:Hide() end)
--title
@@ -106,11 +106,11 @@ local libwindow = LibStub("LibWindow-1.1")
end
end)
local normal_text_template = DF:GetTemplate ("font", "DETAILS_BENCHMARK_NORMAL")
local options_dropdown_template = DF:GetTemplate ("dropdown", "OPTIONS_DROPDOWN_TEMPLATE")
local options_switch_template = DF:GetTemplate ("switch", "OPTIONS_CHECKBOX_TEMPLATE")
local options_slider_template = DF:GetTemplate ("slider", "OPTIONS_SLIDER_TEMPLATE")
local options_button_template = DF:GetTemplate ("button", "OPTIONS_BUTTON_TEMPLATE")
local normal_text_template = DF:GetTemplate("font", "DETAILS_BENCHMARK_NORMAL")
local options_dropdown_template = DF:GetTemplate("dropdown", "OPTIONS_DROPDOWN_TEMPLATE")
local options_switch_template = DF:GetTemplate("switch", "OPTIONS_CHECKBOX_TEMPLATE")
local options_slider_template = DF:GetTemplate("slider", "OPTIONS_SLIDER_TEMPLATE")
local options_button_template = DF:GetTemplate("button", "OPTIONS_BUTTON_TEMPLATE")
--locations
f.FrameLocations = {
@@ -127,8 +127,8 @@ local libwindow = LibStub("LibWindow-1.1")
--declaration
local summaryFrame = CreateFrame("frame", "$parentSummaryFrame", f,"BackdropTemplate")
summaryFrame:SetPoint("topleft", f, "topleft", unpack (f.FrameLocations.summary))
summaryFrame:SetSize(unpack (f.FrameSizes.default))
summaryFrame:SetPoint("topleft", f, "topleft", unpack(f.FrameLocations.summary))
summaryFrame:SetSize(unpack(f.FrameSizes.default))
summaryFrame:SetBackdrop({edgeFile = [[Interface\Buttons\WHITE8X8]], edgeSize = 1, bgFile = [[Interface\Tooltips\UI-Tooltip-Background]], tileSize = 64, tile = true})
summaryFrame:SetBackdropColor(0, 0, 0, 0.9)
summaryFrame:SetBackdropBorderColor(0, 0, 0, 1)
@@ -209,8 +209,8 @@ local libwindow = LibStub("LibWindow-1.1")
--declaration
local spellsFrame = CreateFrame("frame", "$parentSpellsFrame", f,"BackdropTemplate")
spellsFrame:SetPoint("topleft", f, "topleft", unpack (f.FrameLocations.spells))
spellsFrame:SetSize(unpack (f.FrameSizes.default))
spellsFrame:SetPoint("topleft", f, "topleft", unpack(f.FrameLocations.spells))
spellsFrame:SetSize(unpack(f.FrameSizes.default))
spellsFrame:SetBackdrop({edgeFile = [[Interface\Buttons\WHITE8X8]], edgeSize = 1, bgFile = [[Interface\Tooltips\UI-Tooltip-Background]], tileSize = 64, tile = true})
spellsFrame:SetBackdropColor(0, 0, 0, 0.9)
spellsFrame:SetBackdropBorderColor(0, 0, 0, 1)
@@ -228,8 +228,8 @@ local libwindow = LibStub("LibWindow-1.1")
--declaration
local aurasFrame = CreateFrame("frame", "$parentAurasFrame", f,"BackdropTemplate")
aurasFrame:SetPoint("topleft", f, "topleft", unpack (f.FrameLocations.auras))
aurasFrame:SetSize(unpack (f.FrameSizes.default))
aurasFrame:SetPoint("topleft", f, "topleft", unpack(f.FrameLocations.auras))
aurasFrame:SetSize(unpack(f.FrameSizes.default))
aurasFrame:SetBackdrop({edgeFile = [[Interface\Buttons\WHITE8X8]], edgeSize = 1, bgFile = [[Interface\Tooltips\UI-Tooltip-Background]], tileSize = 64, tile = true})
aurasFrame:SetBackdropColor(0, 0, 0, 0.9)
aurasFrame:SetBackdropBorderColor(0, 0, 0, 1)
@@ -245,8 +245,8 @@ local libwindow = LibStub("LibWindow-1.1")
--declaration
local historyFrame = CreateFrame("frame", "$parentHistoryFrame", f,"BackdropTemplate")
historyFrame:SetPoint("topleft", f, "topleft", unpack (f.FrameLocations.history))
historyFrame:SetSize(unpack (f.FrameSizes.default))
historyFrame:SetPoint("topleft", f, "topleft", unpack(f.FrameLocations.history))
historyFrame:SetSize(unpack(f.FrameSizes.default))
historyFrame:SetBackdrop({edgeFile = [[Interface\Buttons\WHITE8X8]], edgeSize = 1, bgFile = [[Interface\Tooltips\UI-Tooltip-Background]], tileSize = 64, tile = true})
historyFrame:SetBackdropColor(0, 0, 0, 0.9)
historyFrame:SetBackdropBorderColor(0, 0, 0, 1)
+12 -12
View File
@@ -8,7 +8,7 @@ local Loc = _G.LibStub("AceLocale-3.0"):GetLocale("Details")
function Details:OpenBookmarkConfig()
if (not _G.DetailsBookmarkManager) then
DF:CreateSimplePanel (UIParent, 465, 460, Loc ["STRING_OPTIONS_MANAGE_BOOKMARKS"], "DetailsBookmarkManager")
DF:CreateSimplePanel(UIParent, 465, 460, Loc ["STRING_OPTIONS_MANAGE_BOOKMARKS"], "DetailsBookmarkManager")
local panel = _G.DetailsBookmarkManager
DF:ApplyStandardBackdrop(panel)
panel:SetBackdropColor(.1, .1, .1, .9)
@@ -62,7 +62,7 @@ function Details:OpenBookmarkConfig()
end
for i = 1, 40 do
local clear = DF:CreateButton (panel, clear_func, 16, 16, nil, i, nil, [[Interface\Glues\LOGIN\Glues-CheckBox-Check]])
local clear = DF:CreateButton(panel, clear_func, 16, 16, nil, i, nil, [[Interface\Glues\LOGIN\Glues-CheckBox-Check]])
if (i%2 ~= 0) then
--impar
clear:SetPoint(15, (( i*10 ) * -1) - 35) --left
@@ -72,7 +72,7 @@ function Details:OpenBookmarkConfig()
clear:SetPoint(250, (( o*10 ) * -1) - 35) --right
end
local set = DF:CreateButton (panel, set_att, 16, 16, nil, i)
local set = DF:CreateButton(panel, set_att, 16, 16, nil, i)
set:SetPoint("left", clear, "right")
set:SetPoint("right", clear, "right", 180, 0)
set:SetBackdrop(button_backdrop)
@@ -81,13 +81,13 @@ function Details:OpenBookmarkConfig()
set:SetHook("OnLeave", set_onleave)
--set:InstallCustomTexture (nil, nil, nil, nil, true)
set:SetTemplate (DF:GetTemplate ("button", "OPTIONS_BUTTON_TEMPLATE"))
set:SetTemplate(DF:GetTemplate("button", "OPTIONS_BUTTON_TEMPLATE"))
local bg_texture = DF:CreateImage (set, [[Interface\AddOns\Details\images\bar_skyline]], 135, 30, "background")
local bg_texture = DF:CreateImage(set, [[Interface\AddOns\Details\images\bar_skyline]], 135, 30, "background")
bg_texture:SetAllPoints()
set.bg = bg_texture
local icon = DF:CreateImage (set, nil, 16, 16, nil, nil, "icon")
local icon = DF:CreateImage(set, nil, 16, 16, nil, nil, "icon")
icon:SetPoint("left", clear, "right", 4, 0)
local label = DF:CreateLabel(set, "")
@@ -112,12 +112,12 @@ function Details:OpenBookmarkConfig()
this_block.label.text = "-- x -- x --"
this_block.icon.texture = "Interface\\ICONS\\Ability_DualWield"
this_block.icon.texcoord = normal_coords
this_block.bg:SetVertexColor (.4, .1, .1, .12)
this_block.bg:SetVertexColor(.4, .1, .1, .12)
else
this_block.label.text = CustomObject.name
this_block.icon.texture = CustomObject.icon
this_block.icon.texcoord = normal_coords
this_block.bg:SetVertexColor (.4, .4, .4, .6)
this_block.bg:SetVertexColor(.4, .4, .4, .6)
end
else
bookmark.atributo = bookmark.atributo or 1
@@ -125,16 +125,16 @@ function Details:OpenBookmarkConfig()
this_block.label.text = Details.sub_atributos [bookmark.atributo] and Details.sub_atributos [bookmark.atributo].lista [bookmark.sub_atributo]
this_block.icon.texture = Details.sub_atributos [bookmark.atributo] and Details.sub_atributos [bookmark.atributo].icones [bookmark.sub_atributo] [1]
this_block.icon.texcoord = Details.sub_atributos [bookmark.atributo] and Details.sub_atributos [bookmark.atributo].icones [bookmark.sub_atributo] [2]
this_block.bg:SetVertexColor (.4, .4, .4, .6)
this_block.bg:SetVertexColor(.4, .4, .4, .6)
end
this_block.button:SetAlpha (1)
this_block.button:SetAlpha(1)
else
this_block.label.text = "-- x -- x --"
this_block.icon.texture = [[Interface\AddOns\Details\images\icons]]
this_block.icon.texcoord = unknown_coords
this_block.bg:SetVertexColor (.1, .1, .1, .12)
this_block.button:SetAlpha (0.3)
this_block.bg:SetVertexColor(.1, .1, .1, .12)
this_block.button:SetAlpha(0.3)
end
end
end
+6 -6
View File
@@ -56,7 +56,7 @@ function Details:OpenBrokerTextEditor()
local d = DF:NewDropDown (panel, _, "$parentTextOptionsDropdown", "TextOptionsDropdown", 150, 20, buildAddMenu, 1)
d:SetPoint("topright", panel, "topright", -12, -25)
d:SetTemplate(DF:GetTemplate ("dropdown", "OPTIONS_DROPDOWN_TEMPLATE"))
d:SetTemplate(DF:GetTemplate("dropdown", "OPTIONS_DROPDOWN_TEMPLATE"))
local optiontable = {"{dmg}", "{dps}", "{dpos}", "{ddiff}", "{heal}", "{hps}", "{hpos}", "{hdiff}", "{time}"}
@@ -65,7 +65,7 @@ function Details:OpenBrokerTextEditor()
end,
nil, nil, nil, "<-")
add_button:SetPoint("right", d, "left", -2, 0)
add_button:SetTemplate(DF:GetTemplate ("button", "OPTIONS_BUTTON_TEMPLATE"))
add_button:SetTemplate(DF:GetTemplate("button", "OPTIONS_BUTTON_TEMPLATE"))
-- code author Saiket from http://www.wowinterface.com/forums/showpost.php?p=245759&postcount=6
@@ -181,7 +181,7 @@ function Details:OpenBrokerTextEditor()
color_button:SetSize(80, 20)
color_button:SetPoint("topright", panel, "topright", -12, -102)
color_button.tooltip = Loc ["STRING_OPTIONS_TEXTEDITOR_COLOR_TOOLTIP"]
color_button:SetTemplate(DF:GetTemplate ("button", "OPTIONS_BUTTON_TEMPLATE"))
color_button:SetTemplate(DF:GetTemplate("button", "OPTIONS_BUTTON_TEMPLATE"))
local done = function()
local text = panel.editbox:GetText()
@@ -197,17 +197,17 @@ function Details:OpenBrokerTextEditor()
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"))
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)
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"))
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)
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"))
cancel_button:SetTemplate(DF:GetTemplate("button", "OPTIONS_BUTTON_TEMPLATE"))
end
+5 -5
View File
@@ -369,11 +369,11 @@ end
--enabled with a toggle button
--execute to reset position
--misc configs
local options_text_template = DF:GetTemplate ("font", "OPTIONS_FONT_TEMPLATE")
local options_dropdown_template = DF:GetTemplate ("dropdown", "OPTIONS_DROPDOWN_TEMPLATE")
local options_switch_template = DF:GetTemplate ("switch", "OPTIONS_CHECKBOX_TEMPLATE")
local options_slider_template = DF:GetTemplate ("slider", "OPTIONS_SLIDER_TEMPLATE")
local options_button_template = DF:GetTemplate ("button", "OPTIONS_BUTTON_TEMPLATE")
local options_text_template = DF:GetTemplate("font", "OPTIONS_FONT_TEMPLATE")
local options_dropdown_template = DF:GetTemplate("dropdown", "OPTIONS_DROPDOWN_TEMPLATE")
local options_switch_template = DF:GetTemplate("switch", "OPTIONS_CHECKBOX_TEMPLATE")
local options_slider_template = DF:GetTemplate("slider", "OPTIONS_SLIDER_TEMPLATE")
local options_button_template = DF:GetTemplate("button", "OPTIONS_BUTTON_TEMPLATE")
local generalOptions = {
{--enable ocd
+15 -15
View File
@@ -7,7 +7,7 @@ local Loc = _G.LibStub("AceLocale-3.0"):GetLocale("Details")
--config class colors
function Details:OpenClassColorsConfig()
if (not _G.DetailsClassColorManager) then
DF:CreateSimplePanel (UIParent, 300, 425, Loc ["STRING_OPTIONS_CLASSCOLOR_MODIFY"], "DetailsClassColorManager")
DF:CreateSimplePanel(UIParent, 300, 425, Loc ["STRING_OPTIONS_CLASSCOLOR_MODIFY"], "DetailsClassColorManager")
local panel = _G.DetailsClassColorManager
DF:ApplyStandardBackdrop(panel)
@@ -15,12 +15,12 @@ function Details:OpenClassColorsConfig()
local upper_panel = CreateFrame("frame", nil, panel,"BackdropTemplate")
upper_panel:SetAllPoints(panel)
upper_panel:SetFrameLevel (panel:GetFrameLevel()+3)
upper_panel:SetFrameLevel(panel:GetFrameLevel()+3)
local y = -50
local callback = function(button, r, g, b, a, self)
self.MyObject.my_texture:SetVertexColor (r, g, b)
self.MyObject.my_texture:SetVertexColor(r, g, b)
Details.class_colors [self.MyObject.my_class][1] = r
Details.class_colors [self.MyObject.my_class][2] = g
Details.class_colors [self.MyObject.my_class][3] = b
@@ -29,14 +29,14 @@ function Details:OpenClassColorsConfig()
local set_color = function(self, button, class, index)
local current_class_color = Details.class_colors [class]
local r, g, b = unpack (current_class_color)
local r, g, b = unpack(current_class_color)
DF:ColorPick (self, r, g, b, 1, callback)
end
local reset_color = function(self, button, class, index)
local color_table = RAID_CLASS_COLORS [class]
local r, g, b = color_table.r, color_table.g, color_table.b
self.MyObject.my_texture:SetVertexColor (r, g, b)
self.MyObject.my_texture:SetVertexColor(r, g, b)
Details.class_colors [self.MyObject.my_class][1] = r
Details.class_colors [self.MyObject.my_class][2] = g
Details.class_colors [self.MyObject.my_class][3] = b
@@ -45,7 +45,7 @@ function Details:OpenClassColorsConfig()
local on_enter = function(self, capsule)
--Details:CooltipPreset(1)
--GameCooltip:AddLine ("right click to reset")
--GameCooltip:AddLine("right click to reset")
--GameCooltip:Show (self)
end
local on_leave = function(self, capsule)
@@ -62,7 +62,7 @@ function Details:OpenClassColorsConfig()
panel.buttons = {}
for index, className in ipairs(CLASS_SORT_ORDER) do
local icon = DF:CreateImage (upper_panel, [[Interface\Glues\CHARACTERCREATE\UI-CHARACTERCREATE-CLASSES]], 32, 32, nil, CLASS_ICON_TCOORDS [className], "icon_" .. className)
local icon = DF:CreateImage(upper_panel, [[Interface\Glues\CHARACTERCREATE\UI-CHARACTERCREATE-CLASSES]], 32, 32, nil, CLASS_ICON_TCOORDS [className], "icon_" .. className)
if (index%2 ~= 0) then
icon:SetPoint(10, y)
@@ -77,7 +77,7 @@ function Details:OpenClassColorsConfig()
local button = DF:CreateButton(panel, set_color, 135, 30, className, className, index)
button:SetPoint("left", icon, "right", -32, 0)
button:InstallCustomTexture(nil, nil, nil, nil, true)
button:SetFrameLevel (panel:GetFrameLevel()+1)
button:SetFrameLevel(panel:GetFrameLevel()+1)
button.text_overlay:ClearAllPoints()
button.text_overlay:SetPoint("left", icon.widget, "right", 2, 0)
@@ -102,7 +102,7 @@ function Details:OpenClassColorsConfig()
num = math.floor(num / 16)
end
if s == '' then s = '00' end
if (string.len (s) == 1) then
if (string.len(s) == 1) then
s = "0"..s
end
return s
@@ -185,11 +185,11 @@ function Details:OpenClassColorsConfig()
}
--templates
local options_text_template = DF:GetTemplate ("font", "OPTIONS_FONT_TEMPLATE")
local options_dropdown_template = DF:GetTemplate ("dropdown", "OPTIONS_DROPDOWN_TEMPLATE")
local options_switch_template = DF:GetTemplate ("switch", "OPTIONS_CHECKBOX_TEMPLATE")
local options_slider_template = DF:GetTemplate ("slider", "OPTIONS_SLIDER_TEMPLATE")
local options_button_template = DF:GetTemplate ("button", "OPTIONS_BUTTON_TEMPLATE")
local options_text_template = DF:GetTemplate("font", "OPTIONS_FONT_TEMPLATE")
local options_dropdown_template = DF:GetTemplate("dropdown", "OPTIONS_DROPDOWN_TEMPLATE")
local options_switch_template = DF:GetTemplate("switch", "OPTIONS_CHECKBOX_TEMPLATE")
local options_slider_template = DF:GetTemplate("slider", "OPTIONS_SLIDER_TEMPLATE")
local options_button_template = DF:GetTemplate("button", "OPTIONS_BUTTON_TEMPLATE")
DetailsFramework:BuildMenu(panel, deathLogOptions, 5, -285, 700, true, options_text_template, options_dropdown_template, options_switch_template, true, options_slider_template, options_button_template)
@@ -198,7 +198,7 @@ function Details:OpenClassColorsConfig()
end
for class, button in pairs(_G.DetailsClassColorManager.buttons) do
button.my_texture:SetVertexColor (unpack (Details.class_colors [class]))
button.my_texture:SetVertexColor(unpack(Details.class_colors [class]))
end
+2 -2
View File
@@ -14,7 +14,7 @@ do
panel:SetPoint("center", UIParent, "center")
panel.locked = false
panel:SetToplevel (true)
panel:SetMovable (true)
panel:SetMovable(true)
panel:SetScript("OnMouseDown", function(self, button)
if (self.isMoving) then
return
@@ -40,7 +40,7 @@ do
--panel.TitleText:SetText("Paste & Copy") --10.0 fuck
--panel.portrait:SetTexture([[Interface\CHARACTERFRAME\TEMPORARYPORTRAIT-FEMALE-BLOODELF]])
DetailsFrameWork:NewTextEntry (panel, _, "$parentTextEntry", "text", 476, 14)
DetailsFrameWork:NewTextEntry(panel, _, "$parentTextEntry", "text", 476, 14)
panel.text:SetPoint(20, -127)
panel.text:SetHook("OnEditFocusLost", function() panel:Hide() end)
panel.text:SetHook("OnChar", function() panel:Hide() end)
+42 -42
View File
@@ -16,7 +16,7 @@ function Details:OpenCurrentRealDPSOptions(from_options_panel)
local DF = _detalhes.gump
local f = DF:CreateSimplePanel (UIParent, 700, 400, "Details! Arena Damage Bar Options", "DetailsCurrentRealDPSOptions")
local f = DF:CreateSimplePanel(UIParent, 700, 400, "Details! Arena Damage Bar Options", "DetailsCurrentRealDPSOptions")
f:SetPoint("center", UIParent, "center")
f:SetScript("OnMouseDown", nil)
f:SetScript("OnMouseUp", nil)
@@ -24,16 +24,16 @@ function Details:OpenCurrentRealDPSOptions(from_options_panel)
--scale bar
local scaleBar = DF:CreateScaleBar(f, _detalhes.realtime_dps_meter.options_frame)
local LibWindow = LibStub ("LibWindow-1.1")
LibWindow.RegisterConfig (f, _detalhes.realtime_dps_meter.options_frame)
LibWindow.MakeDraggable (f)
LibWindow.RestorePosition (f)
local LibWindow = LibStub("LibWindow-1.1")
LibWindow.RegisterConfig(f, _detalhes.realtime_dps_meter.options_frame)
LibWindow.MakeDraggable(f)
LibWindow.RestorePosition(f)
local options_text_template = DF:GetTemplate ("font", "OPTIONS_FONT_TEMPLATE")
local options_dropdown_template = DF:GetTemplate ("dropdown", "OPTIONS_DROPDOWN_TEMPLATE")
local options_switch_template = DF:GetTemplate ("switch", "OPTIONS_CHECKBOX_TEMPLATE")
local options_slider_template = DF:GetTemplate ("slider", "OPTIONS_SLIDER_TEMPLATE")
local options_button_template = DF:GetTemplate ("button", "OPTIONS_BUTTON_TEMPLATE")
local options_text_template = DF:GetTemplate("font", "OPTIONS_FONT_TEMPLATE")
local options_dropdown_template = DF:GetTemplate("dropdown", "OPTIONS_DROPDOWN_TEMPLATE")
local options_switch_template = DF:GetTemplate("switch", "OPTIONS_CHECKBOX_TEMPLATE")
local options_slider_template = DF:GetTemplate("slider", "OPTIONS_SLIDER_TEMPLATE")
local options_button_template = DF:GetTemplate("button", "OPTIONS_BUTTON_TEMPLATE")
--status bar
local statusBar = DF:CreateStatusBar(f)
@@ -94,7 +94,7 @@ function Details:OpenCurrentRealDPSOptions(from_options_panel)
--options table
local options = {
{type = "label", get = function() return "Frame Settings:" end, text_template = DF:GetTemplate ("font", "ORANGE_FONT_TEMPLATE")},
{type = "label", get = function() return "Frame Settings:" end, text_template = DF:GetTemplate("font", "ORANGE_FONT_TEMPLATE")},
--enabled
{
type = "toggle",
@@ -200,7 +200,7 @@ function Details:OpenCurrentRealDPSOptions(from_options_panel)
--[=[
{type = "breakline"},
{type = "label", get = function() return "Enabled On:" end, text_template = DF:GetTemplate ("font", "ORANGE_FONT_TEMPLATE")},
{type = "label", get = function() return "Enabled On:" end, text_template = DF:GetTemplate("font", "ORANGE_FONT_TEMPLATE")},
--arenas
{
type = "toggle",
@@ -226,7 +226,7 @@ function Details:OpenCurrentRealDPSOptions(from_options_panel)
--]=]
{type = "breakline"},
{type = "label", get = function() return "Text Settings:" end, text_template = DF:GetTemplate ("font", "ORANGE_FONT_TEMPLATE")},
{type = "label", get = function() return "Text Settings:" end, text_template = DF:GetTemplate("font", "ORANGE_FONT_TEMPLATE")},
--font size
{
type = "range",
@@ -301,7 +301,7 @@ function Details:OpenCurrentRealDPSOptions(from_options_panel)
--reopen the options panel
if (f.FromOptionsPanel) then
C_Timer.After (0.2, function()
C_Timer.After(0.2, function()
Details:OpenOptionsWindow(Details:GetInstance(1))
end)
end
@@ -343,9 +343,9 @@ function Details:CreateCurrentDpsFrame(parent, name)
f:SetSize(_detalhes.realtime_dps_meter.frame_settings.width, _detalhes.realtime_dps_meter.frame_settings.height)
f:SetBackdrop({bgFile = [[Interface\Tooltips\UI-Tooltip-Background]], tile = true, tileSize = 16, insets = {left = 0, right = 0, top = 0, bottom = 0}})
f:SetBackdropColor(unpack (_detalhes.realtime_dps_meter.frame_settings.backdrop_color))
f:EnableMouse (true)
f:SetMovable (true)
f:SetBackdropColor(unpack(_detalhes.realtime_dps_meter.frame_settings.backdrop_color))
f:EnableMouse(true)
f:SetMovable(true)
f:SetClampedToScreen (true)
f.movemeLabel = f:CreateFontString(nil, "overlay", "GameFontNormal")
@@ -367,10 +367,10 @@ function Details:CreateCurrentDpsFrame(parent, name)
f.PlayerTeam = 0
local LibWindow = LibStub ("LibWindow-1.1")
LibWindow.RegisterConfig (f, _detalhes.realtime_dps_meter.frame_settings)
LibWindow.MakeDraggable (f)
LibWindow.RestorePosition (f)
local LibWindow = LibStub("LibWindow-1.1")
LibWindow.RegisterConfig(f, _detalhes.realtime_dps_meter.frame_settings)
LibWindow.MakeDraggable(f)
LibWindow.RestorePosition(f)
local lockCallback = function()
local f = _G.DetailsCurrentDpsMeter
@@ -470,8 +470,8 @@ function Details:CreateCurrentDpsFrame(parent, name)
DF:SetFontSize (TitleString, 9)
local TitleBackground = f:CreateTexture(nil, "artwork")
TitleBackground:SetTexture([[Interface\Tooltips\UI-Tooltip-Background]])
TitleBackground:SetVertexColor (.1, .1, .1, .9)
TitleBackground:SetVertexColor (.1, .1, .1, 0)
TitleBackground:SetVertexColor(.1, .1, .1, .9)
TitleBackground:SetVertexColor(.1, .1, .1, 0)
TitleBackground:SetPoint("topleft", f, "topleft")
TitleBackground:SetPoint("topright", f, "topright")
TitleBackground:SetHeight(header_size)
@@ -489,11 +489,11 @@ function Details:CreateCurrentDpsFrame(parent, name)
yellow_team_color = Details.class_colors.ARENA_YELLOW
if (f.PlayerTeam == 0) then
labelPlayerTeam:SetTextColor (unpack (yellow_team_color))
labelYellowTeam:SetTextColor (unpack (green_team_color))
labelPlayerTeam:SetTextColor (unpack(yellow_team_color))
labelYellowTeam:SetTextColor (unpack(green_team_color))
else
labelPlayerTeam:SetTextColor (unpack (green_team_color))
labelYellowTeam:SetTextColor (unpack (yellow_team_color))
labelPlayerTeam:SetTextColor (unpack(green_team_color))
labelYellowTeam:SetTextColor (unpack(yellow_team_color))
end
end
@@ -632,20 +632,20 @@ function Details:CreateCurrentDpsFrame(parent, name)
--frame position
f:SetSize(_detalhes.realtime_dps_meter.frame_settings.width, _detalhes.realtime_dps_meter.frame_settings.height)
LibWindow.RegisterConfig (f, _detalhes.realtime_dps_meter.frame_settings)
LibWindow.RestorePosition (f)
LibWindow.RegisterConfig(f, _detalhes.realtime_dps_meter.frame_settings)
LibWindow.RestorePosition(f)
--backdrop color
f:SetBackdropColor(unpack (_detalhes.realtime_dps_meter.frame_settings.backdrop_color))
f:SetBackdropColor(unpack(_detalhes.realtime_dps_meter.frame_settings.backdrop_color))
--set frame size
f:SetSize(_detalhes.realtime_dps_meter.frame_settings.width, _detalhes.realtime_dps_meter.frame_settings.height)
--frame is locked
if (_detalhes.realtime_dps_meter.frame_settings.locked) then
f:EnableMouse (false)
f:EnableMouse(false)
else
f:EnableMouse (true)
f:EnableMouse(true)
end
--frame can show title
@@ -725,19 +725,19 @@ function Details:CreateCurrentDpsFrame(parent, name)
f.YellowDamage = f.YellowDamage + yellowDamageDone
--remove player team damage
local removedDamage = tremove (f.PlayerTeamBuffer, f.MaxBufferIndex+1)
local removedDamage = tremove(f.PlayerTeamBuffer, f.MaxBufferIndex+1)
if (removedDamage) then
f.PlayerTeamDamage = f.PlayerTeamDamage - removedDamage
--be save
f.PlayerTeamDamage = max (0, f.PlayerTeamDamage)
f.PlayerTeamDamage = max(0, f.PlayerTeamDamage)
end
--remove yellow damage
local removedDamage = tremove (f.YellowTeamBuffer, f.MaxBufferIndex+1)
local removedDamage = tremove(f.YellowTeamBuffer, f.MaxBufferIndex+1)
if (removedDamage) then
f.YellowDamage = f.YellowDamage - removedDamage
--be save
f.YellowDamage = max (0, f.YellowDamage)
f.YellowDamage = max(0, f.YellowDamage)
end
self.NextScreenUpdate = self.NextScreenUpdate - time_fraction --always 0.1
@@ -772,8 +772,8 @@ function Details:CreateCurrentDpsFrame(parent, name)
end
else
--not in use, player team is forced to 0
dpsBarFrame:SetLeftColor(unpack (yellow_team_color))
dpsBarFrame:SetRightColor(unpack (green_team_color))
dpsBarFrame:SetLeftColor(unpack(yellow_team_color))
dpsBarFrame:SetRightColor(unpack(green_team_color))
end
if (Details.realtime_dps_meter.frame_settings.locked) then
@@ -820,12 +820,12 @@ function Details:CreateCurrentDpsFrame(parent, name)
f.GroupTotalDamage = f.GroupTotalDamage + groupDamageDoneOnThisTick
--cicle buffer removing the last index and subtract its damage
local removedDamage = tremove (f.GroupBuffer, f.MaxBufferIndex+1)
local removedDamage = tremove(f.GroupBuffer, f.MaxBufferIndex+1)
if (removedDamage) then
--remove the value from the total damage
f.GroupTotalDamage = f.GroupTotalDamage - removedDamage
--be save
f.GroupTotalDamage = max (0, f.GroupTotalDamage)
f.GroupTotalDamage = max(0, f.GroupTotalDamage)
end
self.NextScreenUpdate = self.NextScreenUpdate - time_fraction
@@ -936,8 +936,8 @@ function DetailsTestSplitBar()
local SharedMedia = LibStub:GetLibrary("LibSharedMedia-3.0")
barFrame.splitBar:SetTexture(SharedMedia:Fetch("statusbar", "Details Flat"))
barFrame.splitBar:SetLeftColor(unpack (green_team_color))
barFrame.splitBar:SetRightColor(unpack (yellow_team_color))
barFrame.splitBar:SetLeftColor(unpack(green_team_color))
barFrame.splitBar:SetRightColor(unpack(yellow_team_color))
--test the splitbar
local loopTime = 0.1
+95 -95
View File
@@ -4,9 +4,9 @@
local gump = _detalhes.gump
local _
local AceComm = LibStub ("AceComm-3.0")
local AceSerializer = LibStub ("AceSerializer-3.0")
local Loc = LibStub ("AceLocale-3.0"):GetLocale ( "Details" )
local AceComm = LibStub("AceComm-3.0")
local AceSerializer = LibStub("AceSerializer-3.0")
local Loc = LibStub("AceLocale-3.0"):GetLocale ( "Details" )
-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
--local pointers
@@ -15,7 +15,7 @@
local _cstr = string.format --lua local
local _math_ceil = math.ceil --lua local
local _math_floor = math.floor --lua local
local _ipairs = ipairs --lua local
local ipairs = ipairs --lua local
local _pairs = pairs --lua local
local _string_lower = string.lower --lua local
local _table_sort = table.sort --lua local
@@ -28,7 +28,7 @@
local _GetTime = GetTime --api local
local _GetCursorPosition = GetCursorPosition --api local
local _GameTooltip = GameTooltip --api local
local _UIParent = UIParent --api local
local UIParent = UIParent --api local
local _GetScreenWidth = GetScreenWidth --api local
local _GetScreenHeight = GetScreenHeight --api local
local _IsAltKeyDown = IsAltKeyDown --api local
@@ -53,8 +53,8 @@
local CONST_EDITBOX_BUTTON_WIDTH = 80
local CONST_EDITBOX_BUTTON_HEIGHT = 20
local CONST_BUTTON_TEMPLATE = gump:GetTemplate ("button", "OPTIONS_BUTTON_TEMPLATE")
local CONST_TEXTENTRY_TEMPLATE = gump:GetTemplate ("button", "OPTIONS_BUTTON_TEMPLATE")
local CONST_BUTTON_TEMPLATE = gump:GetTemplate("button", "OPTIONS_BUTTON_TEMPLATE")
local CONST_TEXTENTRY_TEMPLATE = gump:GetTemplate("button", "OPTIONS_BUTTON_TEMPLATE")
gump:InstallTemplate ("button", "DETAILS_CUSTOMDISPLAY_CODE_BUTTONS",
{
@@ -89,11 +89,11 @@
gump:NewColor("DETAILS_CUSTOMDISPLAY_ICON", .7, .6, .5, 1)
local CONST_CODETEXTENTRY_TEMPLATE = gump:GetTemplate ("button", "DETAILS_CUSTOMDISPLAY_CODE_BOX")
local CONST_CODETEXTENTRYEXPANDED_TEMPLATE = gump:GetTemplate ("button", "DETAILS_CUSTOMDISPLAY_CODE_BOX_EXPANDED")
local CONST_CODETEXTENTRYBUTTON_TEMPLATE = gump:GetTemplate ("button", "DETAILS_CUSTOMDISPLAY_CODE_BOX_BUTTON")
local CONST_CODETEXTENTRY_OPENCODEBUTTONS_TEMPLATE = gump:GetTemplate ("button", "DETAILS_CUSTOMDISPLAY_CODE_BUTTONS")
local CONST_REGULAR_BUTTON_TEMPLATE = gump:GetTemplate ("button", "DETAILS_CUSTOMDISPLAY_REGULAR_BUTTON")
local CONST_CODETEXTENTRY_TEMPLATE = gump:GetTemplate("button", "DETAILS_CUSTOMDISPLAY_CODE_BOX")
local CONST_CODETEXTENTRYEXPANDED_TEMPLATE = gump:GetTemplate("button", "DETAILS_CUSTOMDISPLAY_CODE_BOX_EXPANDED")
local CONST_CODETEXTENTRYBUTTON_TEMPLATE = gump:GetTemplate("button", "DETAILS_CUSTOMDISPLAY_CODE_BOX_BUTTON")
local CONST_CODETEXTENTRY_OPENCODEBUTTONS_TEMPLATE = gump:GetTemplate("button", "DETAILS_CUSTOMDISPLAY_CODE_BUTTONS")
local CONST_REGULAR_BUTTON_TEMPLATE = gump:GetTemplate("button", "DETAILS_CUSTOMDISPLAY_REGULAR_BUTTON")
local atributos = _detalhes.atributos
local sub_atributos = _detalhes.sub_atributos
@@ -169,8 +169,8 @@
custom_window:SetPoint("center", UIParent, "center")
custom_window:SetSize(850, 500)
custom_window:EnableMouse (true)
custom_window:SetMovable (true)
custom_window:EnableMouse(true)
custom_window:SetMovable(true)
custom_window:SetScript("OnMouseDown", function(self, button)
if (button == "LeftButton") then
if (not self.moving) then
@@ -222,7 +222,7 @@
f.Close:GetHighlightTexture():SetDesaturated(true)
f.Close:GetPushedTexture():SetDesaturated(true)
f.Close:SetAlpha (0.7)
f.Close:SetAlpha(0.7)
f.Close:SetScript("OnClick", function() _detalhes:CloseCustomDisplayWindow() end)
f.Close:SetScript("OnHide", function()
_detalhes:CloseCustomDisplayWindow()
@@ -231,10 +231,10 @@
--background
f.bg1 = f:CreateTexture(nil, "background")
f.bg1:SetTexture([[Interface\AddOns\Details\images\background]], true)
f.bg1:SetAlpha (0.7)
f.bg1:SetVertexColor (0.27, 0.27, 0.27)
f.bg1:SetVertTile (true)
f.bg1:SetHorizTile (true)
f.bg1:SetAlpha(0.7)
f.bg1:SetVertexColor(0.27, 0.27, 0.27)
f.bg1:SetVertTile(true)
f.bg1:SetHorizTile(true)
f.bg1:SetAllPoints()
f:SetBackdrop({edgeFile = [[Interface\Buttons\WHITE8X8]], edgeSize = 1, bgFile = [[Interface\AddOns\Details\images\background]], tileSize = 64, tile = true})
@@ -279,7 +279,7 @@
DetailsCustomPanel.code3_default = [[
local value, top, total, combat, instance = ...
return math.floor (value)
return math.floor(value)
]]
DetailsCustomPanel.code3 = DetailsCustomPanel.code3_default
@@ -325,7 +325,7 @@
function DetailsCustomPanel:RemoveDisplay (custom_object, index)
table.remove (_detalhes.custom, index)
for _, instance in _ipairs(_detalhes.tabela_instancias) do
for _, instance in ipairs(_detalhes.tabela_instancias) do
if (instance.atributo == 5 and instance.sub_atributo == index) then
instance:ResetAttribute()
elseif (instance.atributo == 5 and instance.sub_atributo > index) then
@@ -435,10 +435,10 @@
DetailsCustomPanel:ClearFocus()
_detalhes.MicroButtonAlert:Hide()
if (string.len (name) < 5) then
return false, _detalhes:Msg (Loc ["STRING_CUSTOM_SHORTNAME"])
elseif (string.len (name) > 32) then
return false, _detalhes:Msg (Loc ["STRING_CUSTOM_LONGNAME"])
if (string.len(name) < 5) then
return false, _detalhes:Msg(Loc ["STRING_CUSTOM_SHORTNAME"])
elseif (string.len(name) > 32) then
return false, _detalhes:Msg(Loc ["STRING_CUSTOM_LONGNAME"])
end
_detalhes:ResetCustomFunctionsCache()
@@ -480,9 +480,9 @@
object.tooltip = false
if (DetailsCustomPanel.IsImporting) then
_detalhes:Msg (Loc ["STRING_CUSTOM_IMPORTED"])
_detalhes:Msg(Loc ["STRING_CUSTOM_IMPORTED"])
else
_detalhes:Msg (Loc ["STRING_CUSTOM_SAVED"])
_detalhes:Msg(Loc ["STRING_CUSTOM_SAVED"])
end
if (DetailsCustomPanel.IsImporting) then
@@ -508,9 +508,9 @@
}
tinsert(_detalhes.custom, new_custom_object)
_setmetatable (new_custom_object, _detalhes.atributo_custom)
_setmetatable(new_custom_object, _detalhes.atributo_custom)
new_custom_object.__index = _detalhes.atributo_custom
_detalhes:Msg (Loc ["STRING_CUSTOM_CREATED"])
_detalhes:Msg(Loc ["STRING_CUSTOM_CREATED"])
end
DetailsCustomPanel:Reset()
@@ -548,9 +548,9 @@
end
if (DetailsCustomPanel.IsImporting) then
_detalhes:Msg (Loc ["STRING_CUSTOM_IMPORTED"])
_detalhes:Msg(Loc ["STRING_CUSTOM_IMPORTED"])
else
_detalhes:Msg (Loc ["STRING_CUSTOM_SAVED"])
_detalhes:Msg(Loc ["STRING_CUSTOM_SAVED"])
end
if (DetailsCustomPanel.IsImporting) then
@@ -591,9 +591,9 @@
end
tinsert(_detalhes.custom, new_custom_object)
_setmetatable (new_custom_object, _detalhes.atributo_custom)
_setmetatable(new_custom_object, _detalhes.atributo_custom)
new_custom_object.__index = _detalhes.atributo_custom
_detalhes:Msg (Loc ["STRING_CUSTOM_CREATED"])
_detalhes:Msg(Loc ["STRING_CUSTOM_CREATED"])
end
DetailsCustomPanel:Reset()
@@ -740,13 +740,13 @@
custom_window.menu = {}
local menu_start = -50
local menu_up_frame = _CreateFrame ("frame", nil, custom_window)
menu_up_frame:SetFrameLevel (custom_window:GetFrameLevel()+2)
menu_up_frame:SetFrameLevel(custom_window:GetFrameLevel()+2)
local onenter = function(self)
--self.icontexture:SetVertexColor (1, 1, 1, 1)
--self.icontexture:SetVertexColor(1, 1, 1, 1)
end
local onleave = function(self)
--self.icontexture:SetVertexColor (.9, .9, .9, 1)
--self.icontexture:SetVertexColor(.9, .9, .9, 1)
end
function custom_window:CreateMenuButton (label, icon, clickfunc, param1, param2, tooltip, name, coords)
@@ -755,8 +755,8 @@
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)
button:SetTemplate (gump:GetTemplate ("button", "DETAILS_PLUGIN_BUTTON_TEMPLATE"))
--button:SetTemplate(CONST_BUTTON_TEMPLATE)
button:SetTemplate(gump:GetTemplate("button", "DETAILS_PLUGIN_BUTTON_TEMPLATE"))
button:SetWidth(160)
button:SetIcon (icon, CONST_MENU_HEIGHT-4, CONST_MENU_HEIGHT-4, "overlay", {.1, .9, .1, .9}, nil, 4)
@@ -771,8 +771,8 @@
local build_menu = function(self, button, func, param2)
GameCooltip:Reset()
for index, custom_object in _ipairs(_detalhes.custom) do
GameCooltip:AddLine (custom_object:GetName())
for index, custom_object in ipairs(_detalhes.custom) do
GameCooltip:AddLine(custom_object:GetName())
GameCooltip:AddIcon (custom_object:GetIcon())
GameCooltip:AddMenu (1, func, custom_object, index, true)
end
@@ -814,7 +814,7 @@
for key, value in pairs(custom_object) do
if (object_keys [key]) then
if (type(value) == "table") then
export_object [key] = Details.CopyTable (value)
export_object [key] = Details.CopyTable(value)
else
export_object [key] = value
end
@@ -824,10 +824,10 @@
local encoded = Details:CompressData (export_object, "print")
if (not custom_window.ExportBox) then
local editbox = _detalhes.gump:NewTextEntry (custom_window, nil, "$parentExportBox", "ExportBox", CONST_EDITBOX_WIDTH, 20)
local editbox = _detalhes.gump:NewTextEntry(custom_window, nil, "$parentExportBox", "ExportBox", CONST_EDITBOX_WIDTH, 20)
editbox:SetPoint("bottomleft", custom_window, "bottomleft", 10, 6)
editbox:SetAutoFocus (false)
editbox:SetTemplate (CONST_TEXTENTRY_TEMPLATE)
editbox:SetTemplate(CONST_TEXTENTRY_TEMPLATE)
editbox:SetHook("OnEditFocusLost", function()
editbox:Hide()
end)
@@ -838,7 +838,7 @@
local flashTexture = editbox:CreateTexture(nil, "overlay")
flashTexture:SetColorTexture (1, 1, 1)
flashTexture:SetAllPoints()
flashTexture:SetAlpha (0)
flashTexture:SetAlpha(0)
local flashAnimHub = DetailsFramework:CreateAnimationHub (flashTexture)
DetailsFramework:CreateAnimation(flashAnimHub, "alpha", 1, 0.2, 0, 1)
@@ -871,10 +871,10 @@
local export_string = gump:NewLabel(custom_window, custom_window, "$parenImportLabel", "exportLabel", "Import String:", "GameFontNormal") --Loc ["STRING_CUSTOM_PASTE"]
export_string:SetPoint("bottomleft", DetailsCustomPanel, "bottomleft", 10, 8)
local editbox = _detalhes.gump:NewTextEntry (custom_window, nil, "$parentImportBox", "ImportBox", CONST_EDITBOX_WIDTH - export_string.width - CONST_EDITBOX_BUTTON_WIDTH - 4, 20)
local editbox = _detalhes.gump:NewTextEntry(custom_window, nil, "$parentImportBox", "ImportBox", CONST_EDITBOX_WIDTH - export_string.width - CONST_EDITBOX_BUTTON_WIDTH - 4, 20)
editbox:SetPoint("left", export_string, "right", 2, 0)
editbox:SetAutoFocus (false)
editbox:SetTemplate (CONST_TEXTENTRY_TEMPLATE)
editbox:SetTemplate(CONST_TEXTENTRY_TEMPLATE)
local import = function()
local text = editbox:GetText()
@@ -882,7 +882,7 @@
local deserialized_object = Details:DecompressData (text, "print")
if (not deserialized_object) then
_detalhes:Msg (Loc ["STRING_CUSTOM_IMPORT_ERROR"])
_detalhes:Msg(Loc ["STRING_CUSTOM_IMPORT_ERROR"])
return
end
@@ -890,7 +890,7 @@
DetailsCustomPanel:CancelFunc()
end
setmetatable (deserialized_object, _detalhes.atributo_custom)
setmetatable(deserialized_object, _detalhes.atributo_custom)
deserialized_object.__index = _detalhes.atributo_custom
_detalhes.MicroButtonAlert.Text:SetText(Loc ["STRING_CUSTOM_IMPORT_ALERT"])
@@ -907,7 +907,7 @@
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"])
okey_button:SetTemplate (CONST_BUTTON_TEMPLATE)
okey_button:SetTemplate(CONST_BUTTON_TEMPLATE)
okey_button:SetPoint("left", editbox, "right", 2, 0)
end
@@ -963,21 +963,21 @@
local selected_left = attribute_box:CreateTexture(nil, "overlay")
selected_left:SetTexture([[Interface\Store\Store-Main]])
selected_left:SetSize(50, 20)
selected_left:SetVertexColor (1, .8, 0, 1)
selected_left:SetVertexColor(1, .8, 0, 1)
selected_left:SetTexCoord (960/1024, 1020/1024, 68/1024, 101/1024)
custom_window.selected_left = selected_left
local selected_right = attribute_box:CreateTexture(nil, "overlay")
selected_right:SetTexture([[Interface\Store\Store-Main]])
selected_right:SetSize(31, 20)
selected_right:SetVertexColor (1, .8, 0, 1)
selected_right:SetVertexColor(1, .8, 0, 1)
selected_right:SetTexCoord (270/1024, 311/1024, 873/1024, 906/1024)
custom_window.selected_right = selected_right
local selected_center = attribute_box:CreateTexture(nil, "overlay")
selected_center:SetTexture([[Interface\Store\Store-Main]])
selected_center:SetSize(49, 20)
selected_center:SetVertexColor (1, .8, 0, 1)
selected_center:SetVertexColor(1, .8, 0, 1)
selected_center:SetTexCoord (956/1024, 1004/1024, 164/1024, 197/1024)
selected_center:SetPoint("left", selected_left, "right")
@@ -1033,9 +1033,9 @@
local name_label = gump:NewLabel(box0, box0, "$parenNameLabel", "name", Loc ["STRING_CUSTOM_NAME"], "GameFontHighlightLeft") --localize-me
name_label:SetPoint("topleft", box0, "topleft", 10, 0)
local name_field = gump:NewTextEntry (box0, nil, "$parentNameEntry", "nameentry", 200, 20)
local name_field = gump:NewTextEntry(box0, nil, "$parentNameEntry", "nameentry", 200, 20)
name_field:SetPoint("left", name_label, "left", 62, 0)
name_field:SetTemplate (CONST_TEXTENTRY_TEMPLATE)
name_field:SetTemplate(CONST_TEXTENTRY_TEMPLATE)
name_field.tooltip = Loc ["STRING_CUSTOM_NAME_DESC"]
custom_window.name_field = name_field
@@ -1043,9 +1043,9 @@
local author_label = gump:NewLabel(box0, box0, "$parenAuthorLabel", "author", Loc ["STRING_CUSTOM_AUTHOR"], "GameFontHighlightLeft") --localize-me
author_label:SetPoint("topleft", name_label, "bottomleft", 0, -12)
local author_field = gump:NewTextEntry (box0, nil, "$parentAuthorEntry", "authorentry", 200, 20)
local author_field = gump:NewTextEntry(box0, nil, "$parentAuthorEntry", "authorentry", 200, 20)
author_field:SetPoint("left", author_label, "left", 62, 0)
author_field:SetTemplate (CONST_TEXTENTRY_TEMPLATE)
author_field:SetTemplate(CONST_TEXTENTRY_TEMPLATE)
author_field.tooltip = Loc ["STRING_CUSTOM_AUTHOR_DESC"]
author_field:SetText(UnitName ("player") .. "-" .. GetRealmName())
custom_window.author_field = author_field
@@ -1054,9 +1054,9 @@
local desc_label = gump:NewLabel(box0, box0, "$parenDescLabel", "desc", Loc ["STRING_CUSTOM_DESCRIPTION"], "GameFontHighlightLeft") --localize-me
desc_label:SetPoint("topleft", author_label, "bottomleft", 0, -12)
local desc_field = gump:NewTextEntry (box0, nil, "$parentDescEntry", "descentry", 200, 20)
local desc_field = gump:NewTextEntry(box0, nil, "$parentDescEntry", "descentry", 200, 20)
desc_field:SetPoint("left", desc_label, "left", 62, 0)
desc_field:SetTemplate (CONST_TEXTENTRY_TEMPLATE)
desc_field:SetTemplate(CONST_TEXTENTRY_TEMPLATE)
desc_field.tooltip = Loc ["STRING_CUSTOM_DESCRIPTION_DESC"]
custom_window.desc_field = desc_field
@@ -1082,22 +1082,22 @@
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)
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"])
accept_button:SetPoint("left", cancel_button, "right", 2, 0)
accept_button:SetTemplate (CONST_REGULAR_BUTTON_TEMPLATE)
accept_button:SetTemplate(CONST_REGULAR_BUTTON_TEMPLATE)
cancel_button:SetFrameLevel (500)
accept_button:SetFrameLevel (500)
cancel_button:SetFrameLevel(500)
accept_button:SetFrameLevel(500)
--create box type 1
local box1 = _CreateFrame ("frame", "DetailsCustomPanelBox1", custom_window)
custom_window.box1 = box1
box1:SetSize(450, 180)
box1:SetPoint("topleft", icon_label.widget, "bottomleft", -10, -20)
box1:SetFrameLevel (box0:GetFrameLevel()+1)
box1:SetFrameLevel(box0:GetFrameLevel()+1)
--source
local source_label = gump:NewLabel(box1, box1, "$parenSourceLabel", "source", Loc ["STRING_CUSTOM_SOURCE"], "GameFontHighlightLeft") --localize-me
@@ -1125,7 +1125,7 @@
source_dropdown.tooltip = Loc ["STRING_CUSTOM_SOURCE_DESC"]
custom_window.source_dropdown = source_dropdown
local source_field = gump:NewTextEntry (box1, nil, "$parentSourceEntry", "sourceentry", 201, 20)
local source_field = gump:NewTextEntry(box1, nil, "$parentSourceEntry", "sourceentry", 201, 20)
source_field:SetPoint("topleft", source_dropdown, "bottomleft", 0, -2)
source_field:Disable()
custom_window.source_field = source_field
@@ -1141,7 +1141,7 @@
adds_boss_image:SetWidth(20)
adds_boss_image:SetHeight(16)
local actorsFrame = gump:NewPanel (custom_window, _, "DetailsCustomActorsFrame2", "actorsFrame", 1, 1)
local actorsFrame = gump:NewPanel(custom_window, _, "DetailsCustomActorsFrame2", "actorsFrame", 1, 1)
actorsFrame:SetPoint("topleft", custom_window, "topright", 5, -60)
actorsFrame:Hide()
@@ -1157,12 +1157,12 @@
modelFrameBackground:SetPoint("topright", actorsFrame.widget, "topleft", -15, -8)
modelFrameBackground:SetTexture([[Interface\ACHIEVEMENTFRAME\UI-GuildAchievement-Parchment-Horizontal-Desaturated]])
modelFrameBackground:SetRotation (90)
modelFrameBackground:SetVertexColor (.5, .5, .5, 0.5)
modelFrameBackground:SetVertexColor(.5, .5, .5, 0.5)
local modelFrameBackgroundIcon = custom_window:CreateTexture(nil, "overlay")
modelFrameBackgroundIcon:SetPoint("center", modelFrameBackground, "center")
modelFrameBackgroundIcon:SetTexture([[Interface\CHARACTERFRAME\Disconnect-Icon]])
modelFrameBackgroundIcon:SetVertexColor (.5, .5, .5, 0.7)
modelFrameBackgroundIcon:SetVertexColor(.5, .5, .5, 0.7)
modelFrameBackground:Hide()
modelFrameBackgroundIcon:Hide()
@@ -1181,7 +1181,7 @@
button.MyObject.line:SetBlendMode("ADD")
button.MyObject.label:SetTextColor (1, 1, 1, 1)
GameTooltip:SetOwner(button, "ANCHOR_TOPLEFT")
GameTooltip:AddLine (button.MyObject.actor)
GameTooltip:AddLine(button.MyObject.actor)
GameTooltip:Show()
local name, description, bgImage, buttonImage, loreImage, dungeonAreaMapID, link = DetailsFramework.EncounterJournal.EJ_GetInstanceInfo (button.MyObject.ej_id)
@@ -1229,9 +1229,9 @@
local t = gump:NewImage (thisButton, nil, 20, 20, nil, nil, "image", "DetailsCustomActors2EncounterImageButton"..i)
t:SetPoint("left", thisButton)
t:SetTexture([[Interface\MINIMAP\TRACKING\Target]])
t:SetDesaturated (true)
t:SetDesaturated(true)
t:SetSize(20, 20)
t:SetAlpha (0.7)
t:SetAlpha(0.7)
local text = gump:NewLabel(thisButton, nil, "DetailsCustomActorsFrame2Button"..i.."Label", "label", "Spell", nil, 9.5, {.8, .8, .8, .8})
text:SetPoint("left", t.image, "right", 2, 0)
@@ -1286,7 +1286,7 @@
if (_detalhes:InstanceIsRaid (instanceId)) then
GameCooltip:AddLine (instanceTable.name, _, 1, "white")
GameCooltip:AddLine(instanceTable.name, _, 1, "white")
GameCooltip:AddIcon (instanceTable.icon, 1, 1, 64, 32)
for index, encounterName in ipairs(instanceTable.boss_names) do
@@ -1347,7 +1347,7 @@
target_dropdown.tooltip = Loc ["STRING_CUSTOM_TARGET_DESC"]
custom_window.target_dropdown = target_dropdown
local target_field = gump:NewTextEntry (box1, nil, "$parentTargetEntry", "targetentry", 201, 20)
local target_field = gump:NewTextEntry(box1, nil, "$parentTargetEntry", "targetentry", 201, 20)
target_field:SetPoint("topleft", target_dropdown, "bottomleft", 0, -2)
target_field:Disable()
custom_window.target_field = target_field
@@ -1363,7 +1363,7 @@
adds_boss_image:SetWidth(20)
adds_boss_image:SetHeight(16)
local actorsFrame = gump:NewPanel (custom_window, _, "DetailsCustomActorsFrame", "actorsFrame", 1, 1)
local actorsFrame = gump:NewPanel(custom_window, _, "DetailsCustomActorsFrame", "actorsFrame", 1, 1)
actorsFrame:SetPoint("topleft", custom_window, "topright", 5, -60)
actorsFrame:Hide()
@@ -1389,7 +1389,7 @@
button.MyObject.line:SetBlendMode("ADD")
button.MyObject.label:SetTextColor (1, 1, 1, 1)
GameTooltip:SetOwner(button, "ANCHOR_TOPLEFT")
GameTooltip:AddLine (button.MyObject.actor)
GameTooltip:AddLine(button.MyObject.actor)
GameTooltip:Show()
local name, description, bgImage, buttonImage, loreImage, dungeonAreaMapID, link = DetailsFramework.EncounterJournal.EJ_GetInstanceInfo (button.MyObject.ej_id)
@@ -1437,9 +1437,9 @@
local t = gump:NewImage (thisButton, nil, 20, 20, nil, nil, "image", "DetailsCustomActorsEncounterImageButton"..i)
t:SetPoint("left", thisButton)
t:SetTexture([[Interface\MINIMAP\TRACKING\Target]])
t:SetDesaturated (true)
t:SetDesaturated(true)
t:SetSize(20, 20)
t:SetAlpha (0.7)
t:SetAlpha(0.7)
local text = gump:NewLabel(thisButton, nil, "DetailsCustomActorsFrameButton"..i.."Label", "label", "Spell", nil, 9.5, {.8, .8, .8, .8})
text:SetPoint("left", t.image, "right", 2, 0)
@@ -1494,7 +1494,7 @@
if (_detalhes:InstanceIsRaid (instanceId)) then
GameCooltip:AddLine (instanceTable.name, _, 1, "white")
GameCooltip:AddLine(instanceTable.name, _, 1, "white")
GameCooltip:AddIcon (instanceTable.icon, 1, 1, 64, 32)
for index, encounterName in ipairs(instanceTable.boss_names) do
@@ -1545,7 +1545,7 @@
spell_id_boss_image:SetWidth(20)
spell_id_boss_image:SetHeight(16)
local spellsFrame = gump:NewPanel (custom_window, _, "DetailsCustomSpellsFrame", "spellsFrame", 1, 1)
local spellsFrame = gump:NewPanel(custom_window, _, "DetailsCustomSpellsFrame", "spellsFrame", 1, 1)
spellsFrame:SetPoint("topleft", custom_window, "topright", 5, 0)
spellsFrame:Hide()
@@ -1654,7 +1654,7 @@
if (_detalhes:InstanceisRaid (instanceId)) then
GameCooltip:AddLine (instanceTable.name, _, 1, "white")
GameCooltip:AddLine(instanceTable.name, _, 1, "white")
GameCooltip:AddIcon (instanceTable.icon, 1, 1, 64, 32)
for index, encounterName in ipairs(instanceTable.boss_names) do
@@ -1696,38 +1696,38 @@
box2:SetSize(450, 180)
box2:SetPoint("topleft", icon_label.widget, "bottomleft", -10, -20)
box2:SetFrameLevel (box0:GetFrameLevel()+1)
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"])
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)
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"])
tooltipcode_button:SetPoint("topleft", maincode_button, "bottomleft", 0, -8)
tooltipcode_button.tooltip = Loc ["STRING_CUSTOM_EDITTOOLTIP_DESC"]
tooltipcode_button:SetTemplate (CONST_CODETEXTENTRY_OPENCODEBUTTONS_TEMPLATE)
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")
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)
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")
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)
percentcode_button:SetTemplate(CONST_CODETEXTENTRY_OPENCODEBUTTONS_TEMPLATE)
box2:Hide()
--create the code editbox
local code_editor = gump:NewSpecialLuaEditorEntry (custom_window, CONST_EDITBOX_WIDTH, CONST_EDITBOX_HEIGHT, "codeeditor", "$parentCodeEditor")
code_editor:SetPoint("topleft", custom_window, "topleft", CONST_MENU_X_POSITION, CONST_EDITBOX_Y_POSITION)
code_editor:SetFrameLevel (custom_window:GetFrameLevel()+4)
code_editor:SetFrameLevel(custom_window:GetFrameLevel()+4)
code_editor:SetBackdrop(nil)
code_editor:HookScript ("OnUpdate", function()
local script = code_editor:GetText()
@@ -1748,7 +1748,7 @@
--create a background area where the code editor is
local codeEditorBackground = gump:NewButton(custom_window, nil, nil, nil, 1, 1, function()end)
codeEditorBackground:SetAllPoints(code_editor)
codeEditorBackground:SetTemplate (CONST_CODETEXTENTRY_TEMPLATE)
codeEditorBackground:SetTemplate(CONST_CODETEXTENTRY_TEMPLATE)
code_editor:Hide()
code_editor.font_size = 11
@@ -1760,14 +1760,14 @@
if (code_editor.expanded) then
code_editor:SetSize(CONST_EDITBOX_WIDTH, CONST_EDITBOX_HEIGHT)
code_editor.expanded = nil
codeEditorBackground:SetTemplate (CONST_CODETEXTENTRY_TEMPLATE)
codeEditorBackground:SetTemplate(CONST_CODETEXTENTRY_TEMPLATE)
--custom_window.box0.cancelbutton:SetPoint("bottomleft", attribute_box, "bottomright", 37, -10)
--custom_window.box0.acceptbutton:SetPoint("left", cancel_button, "right", 2, 0)
else
code_editor:SetSize(CONST_EDITBOX_WIDTH, CONST_EDITBOX_HEIGHT*1.9)
code_editor.expanded = true
codeEditorBackground:SetTemplate (CONST_CODETEXTENTRYEXPANDED_TEMPLATE)
codeEditorBackground:SetTemplate(CONST_CODETEXTENTRYEXPANDED_TEMPLATE)
--custom_window.box0.cancelbutton:SetPoint("bottomleft", attribute_box, "bottomright", -237, -10)
--custom_window.box0.acceptbutton:SetPoint
@@ -1808,7 +1808,7 @@
local object = DetailsCustomPanel.IsEditing
if (type(object) ~= "table") then
return _detalhes:Msg ("This object need to be saved before.")
return _detalhes:Msg("This object need to be saved before.")
end
object.script = main_code
@@ -1830,27 +1830,27 @@
end
local supportFrame = CreateFrame("frame", "$parentSupportFrame", custom_window)
supportFrame:SetFrameLevel (500)
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")
expand:SetPoint("bottomleft", code_editor, "topleft", 0, 1)
expand:SetTemplate (CONST_CODETEXTENTRYBUTTON_TEMPLATE)
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")
font_size1:SetPoint("left", expand, "right", 2, 0)
font_size1:SetTemplate (CONST_CODETEXTENTRYBUTTON_TEMPLATE)
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")
font_size2:SetPoint("left", font_size1, "right", 2, 0)
font_size2:SetTemplate (CONST_CODETEXTENTRYBUTTON_TEMPLATE)
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")
apply1:SetPoint("left", font_size2, "right", 2, 0)
apply1:SetTemplate (CONST_CODETEXTENTRYBUTTON_TEMPLATE)
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
open_API:SetPoint("left", apply1, "right", 2, 0)
open_API:SetTemplate (CONST_CODETEXTENTRYBUTTON_TEMPLATE)
open_API:SetTemplate(CONST_CODETEXTENTRYBUTTON_TEMPLATE)
local errorString = gump:CreateLabel(supportFrame)
errorString:SetPoint("left", open_API, "right", 10, 0)
+9 -9
View File
@@ -4,8 +4,8 @@ local Details = _G._detalhes
local DF = _G.DetailsFramework
local _
--local AceComm = LibStub ("AceComm-3.0")
--local AceSerializer = LibStub ("AceSerializer-3.0")
--local AceComm = LibStub("AceComm-3.0")
--local AceSerializer = LibStub("AceSerializer-3.0")
local Loc = LibStub("AceLocale-3.0"):GetLocale("Details")
local CONST_MENU_X_POSITION = 10
@@ -23,8 +23,8 @@ local CONST_EDITBOX_HEIGHT = 370
local CONST_EDITBOX_BUTTON_WIDTH = 80
local CONST_EDITBOX_BUTTON_HEIGHT = 20
local CONST_BUTTON_TEMPLATE = DF:GetTemplate ("button", "OPTIONS_BUTTON_TEMPLATE")
local CONST_TEXTENTRY_TEMPLATE = DF:GetTemplate ("button", "OPTIONS_BUTTON_TEMPLATE")
local CONST_BUTTON_TEMPLATE = DF:GetTemplate("button", "OPTIONS_BUTTON_TEMPLATE")
local CONST_TEXTENTRY_TEMPLATE = DF:GetTemplate("button", "OPTIONS_BUTTON_TEMPLATE")
DF:InstallTemplate ("button", "DETAILS_CUSTOMDISPLAY_CODE_BUTTONS",
{
@@ -59,11 +59,11 @@ DF:InstallTemplate ("button", "DETAILS_CUSTOMDISPLAY_CODE_BOX_BUTTON", {
DF:NewColor("DETAILS_CUSTOMDISPLAY_ICON", .7, .6, .5, 1)
local CONST_CODETEXTENTRY_TEMPLATE = DF:GetTemplate ("button", "DETAILS_CUSTOMDISPLAY_CODE_BOX")
local CONST_CODETEXTENTRYEXPANDED_TEMPLATE = DF:GetTemplate ("button", "DETAILS_CUSTOMDISPLAY_CODE_BOX_EXPANDED")
local CONST_CODETEXTENTRYBUTTON_TEMPLATE = DF:GetTemplate ("button", "DETAILS_CUSTOMDISPLAY_CODE_BOX_BUTTON")
local CONST_CODETEXTENTRY_OPENCODEBUTTONS_TEMPLATE = DF:GetTemplate ("button", "DETAILS_CUSTOMDISPLAY_CODE_BUTTONS")
local CONST_REGULAR_BUTTON_TEMPLATE = DF:GetTemplate ("button", "DETAILS_CUSTOMDISPLAY_REGULAR_BUTTON")
local CONST_CODETEXTENTRY_TEMPLATE = DF:GetTemplate("button", "DETAILS_CUSTOMDISPLAY_CODE_BOX")
local CONST_CODETEXTENTRYEXPANDED_TEMPLATE = DF:GetTemplate("button", "DETAILS_CUSTOMDISPLAY_CODE_BOX_EXPANDED")
local CONST_CODETEXTENTRYBUTTON_TEMPLATE = DF:GetTemplate("button", "DETAILS_CUSTOMDISPLAY_CODE_BOX_BUTTON")
local CONST_CODETEXTENTRY_OPENCODEBUTTONS_TEMPLATE = DF:GetTemplate("button", "DETAILS_CUSTOMDISPLAY_CODE_BUTTONS")
local CONST_REGULAR_BUTTON_TEMPLATE = DF:GetTemplate("button", "DETAILS_CUSTOMDISPLAY_REGULAR_BUTTON")
--new script button
+14 -14
View File
@@ -19,7 +19,7 @@ end
function Details:Dump (...)
if (not DetailsDumpFrame) then
DetailsDumpFrame = DetailsFramework:CreateSimplePanel (_G.UIParent)
DetailsDumpFrame = DetailsFramework:CreateSimplePanel(_G.UIParent)
DetailsDumpFrame:SetSize(700, 600)
DetailsDumpFrame:SetTitle ("Details! Dump Table [|cFFFF3333Ready Only|r]")
@@ -40,10 +40,10 @@ function Details:Dump (...)
text_editor:SetBackdropBorderColor(0, 0, 0, 1)
text_editor.__background:SetColorTexture (0.2317647, 0.2317647, 0.2317647)
text_editor.__background:SetVertexColor (0.27, 0.27, 0.27)
text_editor.__background:SetAlpha (0.8)
text_editor.__background:SetVertTile (true)
text_editor.__background:SetHorizTile (true)
text_editor.__background:SetVertexColor(0.27, 0.27, 0.27)
text_editor.__background:SetAlpha(0.8)
text_editor.__background:SetVertTile(true)
text_editor.__background:SetHorizTile(true)
text_editor.__background:SetAllPoints()
end
@@ -80,10 +80,10 @@ end
function _detalhes:ShowImportWindow (defaultText, confirmFunc, titleText)
if (not _G.DetailsExportWindow) then
local importWindow = DetailsFramework:CreateSimplePanel (_G.UIParent, 800, 610, "Details! Dump String", "DetailsExportWindow")
local importWindow = DetailsFramework:CreateSimplePanel(_G.UIParent, 800, 610, "Details! Dump String", "DetailsExportWindow")
importWindow:SetFrameStrata("FULLSCREEN")
importWindow:SetPoint("center")
DetailsFramework:ApplyStandardBackdrop (importWindow, false, 1.2)
DetailsFramework:ApplyStandardBackdrop(importWindow, false, 1.2)
local importTextEditor = DetailsFramework:NewSpecialLuaEditorEntry (importWindow, 780, 540, "ImportEditor", "$parentEditor", true)
importTextEditor:SetBackdrop({edgeFile = [[Interface\Buttons\WHITE8X8]], edgeSize = 1, bgFile = [[Interface\Tooltips\UI-Tooltip-Background]], tileSize = 64, tile = true})
@@ -105,10 +105,10 @@ function _detalhes:ShowImportWindow (defaultText, confirmFunc, titleText)
importTextEditor:SetBackdropBorderColor(0, 0, 0, 1)
importTextEditor.__background:SetColorTexture (0.2317647, 0.2317647, 0.2317647)
importTextEditor.__background:SetVertexColor (0.27, 0.27, 0.27)
importTextEditor.__background:SetAlpha (0.8)
importTextEditor.__background:SetVertTile (true)
importTextEditor.__background:SetHorizTile (true)
importTextEditor.__background:SetVertexColor(0.27, 0.27, 0.27)
importTextEditor.__background:SetAlpha(0.8)
importTextEditor.__background:SetVertTile(true)
importTextEditor.__background:SetHorizTile(true)
importTextEditor.__background:SetAllPoints()
--import button
@@ -118,12 +118,12 @@ function _detalhes:ShowImportWindow (defaultText, confirmFunc, titleText)
end
importWindow:Hide()
end
local okayButton = DetailsFramework:CreateButton (importTextEditor, onClickImportButton, 120, 20, "Okay", -1, nil, nil, nil, nil, nil, _detalhes.gump:GetTemplate ("button", "OPTIONS_BUTTON_TEMPLATE"), _detalhes.gump:GetTemplate ("font", "OPTIONS_FONT_TEMPLATE")) --localize-me
local okayButton = DetailsFramework:CreateButton(importTextEditor, onClickImportButton, 120, 20, "Okay", -1, nil, nil, nil, nil, nil, _detalhes.gump:GetTemplate("button", "OPTIONS_BUTTON_TEMPLATE"), _detalhes.gump:GetTemplate("font", "OPTIONS_FONT_TEMPLATE")) --localize-me
okayButton:SetIcon ([[Interface\BUTTONS\UI-Panel-BiggerButton-Up]], 20, 20, "overlay", {0.1, .9, 0.1, .9})
importTextEditor.OkayButton = okayButton
--cancel button
local cancelButton = DetailsFramework:CreateButton (importTextEditor, function() importWindow:Hide() end, 120, 20, "Cancel", -1, nil, nil, nil, nil, nil, _detalhes.gump:GetTemplate ("button", "OPTIONS_BUTTON_TEMPLATE"), _detalhes.gump:GetTemplate ("font", "OPTIONS_FONT_TEMPLATE")) --localize-me
local cancelButton = DetailsFramework:CreateButton(importTextEditor, function() importWindow:Hide() end, 120, 20, "Cancel", -1, nil, nil, nil, nil, nil, _detalhes.gump:GetTemplate("button", "OPTIONS_BUTTON_TEMPLATE"), _detalhes.gump:GetTemplate("font", "OPTIONS_FONT_TEMPLATE")) --localize-me
cancelButton:SetIcon ([[Interface\BUTTONS\UI-Panel-MinimizeButton-Up]], 20, 20, "overlay", {0.1, .9, 0.1, .9})
okayButton:SetPoint("topright", importTextEditor, "bottomright", 0, -10)
@@ -138,7 +138,7 @@ function _detalhes:ShowImportWindow (defaultText, confirmFunc, titleText)
titleText = titleText or "Details! Dump String"
_G.DetailsExportWindow.Title:SetText(titleText)
C_Timer.After (.2, function()
C_Timer.After(.2, function()
_G.DetailsExportWindow.ImportEditor:SetFocus (true)
_G.DetailsExportWindow.ImportEditor.editbox:HighlightText (0)
end)
+39 -39
View File
@@ -10,20 +10,20 @@ function Details:OpenEventTrackerOptions (from_options_panel)
local DF = _detalhes.gump
local f = DF:CreateSimplePanel (_G.UIParent, 700, 400, "Details! Event Tracker Options", "DetailsEventTrackerOptions")
local f = DF:CreateSimplePanel(_G.UIParent, 700, 400, "Details! Event Tracker Options", "DetailsEventTrackerOptions")
f:SetPoint("center", _G.UIParent, "center")
f:SetScript("OnMouseDown", nil)
f:SetScript("OnMouseUp", nil)
local LibWindow = _G.LibStub("LibWindow-1.1")
LibWindow.RegisterConfig (f, _detalhes.event_tracker.options_frame)
LibWindow.MakeDraggable (f)
LibWindow.RestorePosition (f)
LibWindow.RegisterConfig(f, _detalhes.event_tracker.options_frame)
LibWindow.MakeDraggable(f)
LibWindow.RestorePosition(f)
local options_text_template = DF:GetTemplate ("font", "OPTIONS_FONT_TEMPLATE")
local options_dropdown_template = DF:GetTemplate ("dropdown", "OPTIONS_DROPDOWN_TEMPLATE")
local options_switch_template = DF:GetTemplate ("switch", "OPTIONS_CHECKBOX_TEMPLATE")
local options_slider_template = DF:GetTemplate ("slider", "OPTIONS_SLIDER_TEMPLATE")
local options_button_template = DF:GetTemplate ("button", "OPTIONS_BUTTON_TEMPLATE")
local options_text_template = DF:GetTemplate("font", "OPTIONS_FONT_TEMPLATE")
local options_dropdown_template = DF:GetTemplate("dropdown", "OPTIONS_DROPDOWN_TEMPLATE")
local options_switch_template = DF:GetTemplate("switch", "OPTIONS_CHECKBOX_TEMPLATE")
local options_slider_template = DF:GetTemplate("slider", "OPTIONS_SLIDER_TEMPLATE")
local options_button_template = DF:GetTemplate("button", "OPTIONS_BUTTON_TEMPLATE")
--frame strata options
local set_frame_strata = function(_, _, strata)
@@ -69,7 +69,7 @@ function Details:OpenEventTrackerOptions (from_options_panel)
--options table
local options = {
{type = "label", get = function() return "Frame Settings:" end, text_template = DF:GetTemplate ("font", "ORANGE_FONT_TEMPLATE")},
{type = "label", get = function() return "Frame Settings:" end, text_template = DF:GetTemplate("font", "ORANGE_FONT_TEMPLATE")},
--enabled
{
type = "toggle",
@@ -129,7 +129,7 @@ function Details:OpenEventTrackerOptions (from_options_panel)
name = "Frame Strata"
},
{type = "breakline"},
{type = "label", get = function() return "Line Settings:" end, text_template = DF:GetTemplate ("font", "ORANGE_FONT_TEMPLATE")},
{type = "label", get = function() return "Line Settings:" end, text_template = DF:GetTemplate("font", "ORANGE_FONT_TEMPLATE")},
--line height
{
type = "range",
@@ -217,7 +217,7 @@ function Details:OpenEventTrackerOptions (from_options_panel)
f:SetScript("OnHide", function()
--reopen the options panel
if (f.FromOptionsPanel) then
C_Timer.After (0.2, function()
C_Timer.After(0.2, function()
Details:OpenOptionsWindow(Details:GetInstance(1))
end)
end
@@ -249,16 +249,16 @@ function Details:CreateEventTrackerFrame(parent, name)
f:SetSize(_detalhes.event_tracker.frame.width, _detalhes.event_tracker.frame.height)
f:SetBackdrop({bgFile = [[Interface\Tooltips\UI-Tooltip-Background]], tile = true, tileSize = 16, insets = {left = 0, right = 0, top = 0, bottom = 0}})
f:SetBackdropColor(unpack (_detalhes.event_tracker.frame.backdrop_color))
f:EnableMouse (true)
f:SetMovable (true)
f:SetBackdropColor(unpack(_detalhes.event_tracker.frame.backdrop_color))
f:EnableMouse(true)
f:SetMovable(true)
f:SetResizable(true)
f:SetClampedToScreen (true)
local LibWindow = LibStub ("LibWindow-1.1")
LibWindow.RegisterConfig (f, _detalhes.event_tracker.frame)
LibWindow.MakeDraggable (f)
LibWindow.RestorePosition (f)
local LibWindow = LibStub("LibWindow-1.1")
LibWindow.RegisterConfig(f, _detalhes.event_tracker.frame)
LibWindow.MakeDraggable(f)
LibWindow.RestorePosition(f)
--two resizers
@@ -334,7 +334,7 @@ function Details:CreateEventTrackerFrame(parent, name)
local scroll_createline = function(self, index)
local line = CreateFrame("frame", "$parentLine" .. index, self,"BackdropTemplate")
line:EnableMouse (false)
line:EnableMouse(false)
line.Index = index --hack to not trigger error on UpdateWorldTrackerLines since Index is set after this function is ran
--set its backdrop
@@ -346,7 +346,7 @@ function Details:CreateEventTrackerFrame(parent, name)
statusbar:SetAllPoints()
local statusbartexture = statusbar:CreateTexture(nil, "border")
statusbar:SetStatusBarTexture (statusbartexture)
statusbar:SetMinMaxValues (0, 1)
statusbar:SetMinMaxValues(0, 1)
statusbar:SetValue(0)
local statusbarspark = statusbar:CreateTexture(nil, "artwork")
@@ -432,9 +432,9 @@ function Details:CreateEventTrackerFrame(parent, name)
local get_player_icon = function(spec, class)
if (spec) then
return [[Interface\AddOns\Details\images\spec_icons_normal]], unpack (_detalhes.class_specs_coords [spec])
return [[Interface\AddOns\Details\images\spec_icons_normal]], unpack(_detalhes.class_specs_coords [spec])
elseif (class) then
return [[Interface\AddOns\Details\images\classes_small]], unpack (_detalhes.class_coords [class])
return [[Interface\AddOns\Details\images\classes_small]], unpack(_detalhes.class_coords [class])
else
return [[Interface\AddOns\Details\images\classes_plus]], 0.50390625, 0.62890625, 0, 0.125
end
@@ -443,11 +443,11 @@ function Details:CreateEventTrackerFrame(parent, name)
local add_role_and_class_color = function(player_name, player_serial)
--get the actor object
local actor = _detalhes.tabela_vigente[1]:GetActor (player_name)
local actor = _detalhes.tabela_vigente[1]:GetActor(player_name)
if (actor) then
--remove realm name
player_name = _detalhes:GetOnlyName (player_name)
player_name = _detalhes:GetOnlyName(player_name)
local class, spec, role = actor.classe, actor.spec, actor.role
if (not class) then
@@ -468,7 +468,7 @@ function Details:CreateEventTrackerFrame(parent, name)
else
local spec, class = get_spec_or_class (player_serial, player_name)
player_name = _detalhes:GetOnlyName (player_name)
player_name = _detalhes:GetOnlyName(player_name)
if (class) then
--add the class color
@@ -520,7 +520,7 @@ function Details:CreateEventTrackerFrame(parent, name)
local texture, L, R, T, B = get_player_icon (spec, class)
line.LeftIcon:SetTexture(texture)
line.LeftIcon:SetTexCoord (L, R, T, B)
line.LeftText:SetText(_detalhes:GetOnlyName (ability [ABILITYTABLE_CASTERNAME]))
line.LeftText:SetText(_detalhes:GetOnlyName(ability [ABILITYTABLE_CASTERNAME]))
if (ability [ABILITYTABLE_ISENEMY]) then
line:SetBackdropColor(1, .3, .3, 0.5)
@@ -596,7 +596,7 @@ function Details:CreateEventTrackerFrame(parent, name)
TitleString:SetText("Details!: Event Tracker")
local TitleBackground = f:CreateTexture(nil, "artwork")
TitleBackground:SetTexture([[Interface\Tooltips\UI-Tooltip-Background]])
TitleBackground:SetVertexColor (.1, .1, .1, .9)
TitleBackground:SetVertexColor(.1, .1, .1, .9)
TitleBackground:SetPoint("topleft", f, "topleft")
TitleBackground:SetPoint("topright", f, "topright")
TitleBackground:SetHeight(header_size)
@@ -639,13 +639,13 @@ function Details:CreateEventTrackerFrame(parent, name)
--set texture
local texture = SharedMedia:Fetch ("statusbar", _detalhes.event_tracker.line_texture)
line.StatusbarTexture:SetTexture(texture)
line.StatusbarTexture:SetVertexColor (unpack (_detalhes.event_tracker.line_color))
line.StatusbarTexture:SetVertexColor(unpack(_detalhes.event_tracker.line_color))
--set icon size
line.LeftIcon:SetSize(_detalhes.event_tracker.line_height, _detalhes.event_tracker.line_height)
line.RightIcon:SetSize(_detalhes.event_tracker.line_height, _detalhes.event_tracker.line_height)
line.ActionIcon:SetSize(_detalhes.event_tracker.line_height-4, _detalhes.event_tracker.line_height-4)
line.ActionIcon:SetAlpha (0.65)
line.ActionIcon:SetAlpha(0.65)
end
-- /run _detalhes.event_tracker.font_shadow = 24
@@ -676,16 +676,16 @@ function Details:CreateEventTrackerFrame(parent, name)
end
f:SetSize(_detalhes.event_tracker.frame.width, _detalhes.event_tracker.frame.height)
LibWindow.RegisterConfig (f, _detalhes.event_tracker.frame)
LibWindow.RestorePosition (f)
LibWindow.RegisterConfig(f, _detalhes.event_tracker.frame)
LibWindow.RestorePosition(f)
scrollframe:OnSizeChanged()
if (_detalhes.event_tracker.frame.locked) then
f:EnableMouse (false)
f:EnableMouse(false)
left_resize:Hide()
right_resize:Hide()
else
f:EnableMouse (true)
f:EnableMouse(true)
left_resize:Show()
right_resize:Show()
end
@@ -702,8 +702,8 @@ function Details:CreateEventTrackerFrame(parent, name)
scrollframe:SetPoint("topright", f, "topright", 0, 0)
end
f:SetBackdropColor(unpack (_detalhes.event_tracker.frame.backdrop_color))
scrollframe.__background:SetVertexColor (unpack (_detalhes.event_tracker.frame.backdrop_color))
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)
@@ -734,13 +734,13 @@ function Details:CreateEventTrackerFrame(parent, name)
if (not flag) then
return false
end
return bit.band (flag, OBJECT_TYPE_PLAYER) ~= 0
return bit.band(flag, OBJECT_TYPE_PLAYER) ~= 0
end
local is_enemy = function(flag)
if (not flag) then
return false
end
return bit.band (flag, OBJECT_TYPE_ENEMY) ~= 0
return bit.band(flag, OBJECT_TYPE_ENEMY) ~= 0
end
combatLog:SetScript("OnEvent", function(self, event)
@@ -778,7 +778,7 @@ function Details:CreateEventTrackerFrame(parent, name)
local amountToShow = #CurrentShowing
if (amountToShow > amountOfLines) then
tremove (CurrentShowing, amountToShow)
tremove(CurrentShowing, amountToShow)
end
scrollframe:Refresh()
end
+35 -35
View File
@@ -22,7 +22,7 @@ local CONST_BUTTONSELECTED_TEMPLATE = Details:GetFramework():InstallTemplate("bu
function Details:InitializeForge()
local DetailsForgePanel = Details.gump:CreateSimplePanel (UIParent, 960, 600, "Details! " .. L["STRING_SPELLLIST"], "DetailsForgePanel")
local DetailsForgePanel = Details.gump:CreateSimplePanel(UIParent, 960, 600, "Details! " .. L["STRING_SPELLLIST"], "DetailsForgePanel")
DetailsForgePanel.Frame = DetailsForgePanel
DetailsForgePanel.__name = L["STRING_SPELLLIST"]
DetailsForgePanel.real_name = "DETAILS_FORGE"
@@ -44,11 +44,11 @@ function Details:OpenForge()
DetailsForgePanel.Initialized = true
--main frame
local f = DetailsForgePanel or Details.gump:CreateSimplePanel (UIParent, 960, 600, "Details! " .. L["STRING_SPELLLIST"], "DetailsForgePanel")
local f = DetailsForgePanel or Details.gump:CreateSimplePanel(UIParent, 960, 600, "Details! " .. L["STRING_SPELLLIST"], "DetailsForgePanel")
f:SetPoint("center", UIParent, "center")
f:SetFrameStrata("HIGH")
f:SetToplevel (true)
f:SetMovable (true)
f:SetMovable(true)
f.Title:SetTextColor (1, .8, .2)
local have_plugins_enabled
@@ -91,11 +91,11 @@ function Details:OpenForge()
local editBox = Details.gump:CreateTextEntry (tutorialFrame, function()end, 375, 20, nil, nil, nil, entry_template, label_template)
editBox:SetPoint("topleft", tutorialFrame.Example, "bottomleft", 0, -10)
editBox:SetText([[https://www.youtube.com/watch?v=om0k1Yj2pEw]])
editBox:SetTemplate (Details.gump:GetTemplate ("button", "OPTIONS_BUTTON_TEMPLATE"))
editBox:SetTemplate(Details.gump:GetTemplate("button", "OPTIONS_BUTTON_TEMPLATE"))
local closeButton = Details.gump:CreateButton (tutorialFrame, function() Details:SetTutorialCVar ("FORGE_TUTORIAL", true); tutorialFrame:Hide() end, 80, 20, L["STRING_OPTIONS_CHART_CLOSE"])
local closeButton = Details.gump:CreateButton(tutorialFrame, function() Details:SetTutorialCVar ("FORGE_TUTORIAL", true); tutorialFrame:Hide() end, 80, 20, L["STRING_OPTIONS_CHART_CLOSE"])
closeButton:SetPoint("bottom", tutorialFrame, "bottom", 0, 10)
closeButton:SetTemplate (Details.gump:GetTemplate ("button", "OPTIONS_BUTTON_TEMPLATE"))
closeButton:SetTemplate(Details.gump:GetTemplate("button", "OPTIONS_BUTTON_TEMPLATE"))
end
--modules
@@ -113,10 +113,10 @@ function Details:OpenForge()
f.bg1 = f:CreateTexture(nil, "background")
f.bg1:SetTexture([[Interface\AddOns\Details\images\background]], true)
f.bg1:SetAlpha (0.7)
f.bg1:SetVertexColor (0.27, 0.27, 0.27)
f.bg1:SetVertTile (true)
f.bg1:SetHorizTile (true)
f.bg1:SetAlpha(0.7)
f.bg1:SetVertexColor(0.27, 0.27, 0.27)
f.bg1:SetVertTile(true)
f.bg1:SetHorizTile(true)
f.bg1:SetSize(790, 454)
f.bg1:SetAllPoints()
@@ -128,8 +128,8 @@ function Details:OpenForge()
--scroll gradient
local blackdiv = f:CreateTexture(nil, "artwork")
blackdiv:SetTexture([[Interface\ACHIEVEMENTFRAME\UI-Achievement-HorizontalShadow]])
blackdiv:SetVertexColor (0, 0, 0)
blackdiv:SetAlpha (1)
blackdiv:SetVertexColor(0, 0, 0)
blackdiv:SetAlpha(1)
blackdiv:SetPoint("topleft", f, "topleft", 170, -100)
blackdiv:SetHeight(461)
blackdiv:SetWidth(200)
@@ -137,8 +137,8 @@ function Details:OpenForge()
--big gradient
local blackdiv = f:CreateTexture(nil, "artwork")
blackdiv:SetTexture([[Interface\ACHIEVEMENTFRAME\UI-Achievement-HorizontalShadow]])
blackdiv:SetVertexColor (0, 0, 0)
blackdiv:SetAlpha (0.7)
blackdiv:SetVertexColor(0, 0, 0)
blackdiv:SetAlpha(0.7)
blackdiv:SetPoint("topleft", f, "topleft", 0, 0)
blackdiv:SetPoint("bottomleft", f, "bottomleft", 0, 0)
blackdiv:SetWidth(200)
@@ -150,7 +150,7 @@ function Details:OpenForge()
local buttons = {}
function f:InstallModule (module)
if (module and type (module) == "table") then
if (module and type(module) == "table") then
tinsert(all_modules, module)
end
end
@@ -170,7 +170,7 @@ function Details:OpenForge()
local entry = fw:CreateTextEntry (w, nil, 120, 20, "entry", "DetailsForgeAllPlayersNameFilter")
entry:SetHook("OnTextChanged", function() f:refresh() end)
entry:SetPoint("left", label, "right", 2, 0)
entry:SetTemplate (Details.gump:GetTemplate ("button", "OPTIONS_BUTTON_TEMPLATE"))
entry:SetTemplate(Details.gump:GetTemplate("button", "OPTIONS_BUTTON_TEMPLATE"))
end
return DetailsForgeAllPlayersFilterPanel
end,
@@ -234,7 +234,7 @@ function Details:OpenForge()
local entry = fw:CreateTextEntry (w, nil, 120, 20, "entry", "DetailsForgeAllPetsNameFilter")
entry:SetHook("OnTextChanged", function() f:refresh() end)
entry:SetPoint("left", label, "right", 2, 0)
entry:SetTemplate (Details.gump:GetTemplate ("button", "OPTIONS_BUTTON_TEMPLATE"))
entry:SetTemplate(Details.gump:GetTemplate("button", "OPTIONS_BUTTON_TEMPLATE"))
--
local label = w:CreateFontString (nil, "overlay", "GameFontHighlightSmall")
label:SetText(L["STRING_FORGE_FILTER_OWNERNAME"] .. ": ")
@@ -242,7 +242,7 @@ function Details:OpenForge()
local entry = fw:CreateTextEntry (w, nil, 120, 20, "entry", "DetailsForgeAllPetsOwnerFilter")
entry:SetHook("OnTextChanged", function() f:refresh() end)
entry:SetPoint("left", label, "right", 2, 0)
entry:SetTemplate (Details.gump:GetTemplate ("button", "OPTIONS_BUTTON_TEMPLATE"))
entry:SetTemplate(Details.gump:GetTemplate("button", "OPTIONS_BUTTON_TEMPLATE"))
end
return DetailsForgeAllPetsFilterPanel
end,
@@ -321,7 +321,7 @@ function Details:OpenForge()
local entry = fw:CreateTextEntry (w, nil, 120, 20, "entry", "DetailsForgeAllEnemiesNameFilter")
entry:SetHook("OnTextChanged", function() f:refresh() end)
entry:SetPoint("left", label, "right", 2, 0)
entry:SetTemplate (Details.gump:GetTemplate ("button", "OPTIONS_BUTTON_TEMPLATE"))
entry:SetTemplate(Details.gump:GetTemplate("button", "OPTIONS_BUTTON_TEMPLATE"))
end
return DetailsForgeAllEnemiesFilterPanel
end,
@@ -418,7 +418,7 @@ function Details:OpenForge()
local entry = fw:CreateTextEntry (w, nil, 120, 20, "entry", "DetailsForgeAllSpellsNameFilter")
entry:SetHook("OnTextChanged", function() f:refresh() end)
entry:SetPoint("left", label, "right", 2, 0)
entry:SetTemplate (Details.gump:GetTemplate ("button", "OPTIONS_BUTTON_TEMPLATE"))
entry:SetTemplate(Details.gump:GetTemplate("button", "OPTIONS_BUTTON_TEMPLATE"))
--
local label = w:CreateFontString (nil, "overlay", "GameFontHighlightSmall")
label:SetText(L["STRING_FORGE_FILTER_CASTERNAME"] .. ": ")
@@ -426,7 +426,7 @@ function Details:OpenForge()
local entry = fw:CreateTextEntry (w, nil, 120, 20, "entry", "DetailsForgeAllSpellsCasterFilter")
entry:SetHook("OnTextChanged", function() f:refresh() end)
entry:SetPoint("left", label, "right", 2, 0)
entry:SetTemplate (Details.gump:GetTemplate ("button", "OPTIONS_BUTTON_TEMPLATE"))
entry:SetTemplate(Details.gump:GetTemplate("button", "OPTIONS_BUTTON_TEMPLATE"))
end
return DetailsForgeAllSpellsFilterPanel
end,
@@ -548,7 +548,7 @@ function Details:OpenForge()
local entry = fw:CreateTextEntry (w, nil, 120, 20, "entry", "DetailsForgeEncounterSpellsNameFilter")
entry:SetHook("OnTextChanged", function() f:refresh() end)
entry:SetPoint("left", label, "right", 2, 0)
entry:SetTemplate (Details.gump:GetTemplate ("button", "OPTIONS_BUTTON_TEMPLATE"))
entry:SetTemplate(Details.gump:GetTemplate("button", "OPTIONS_BUTTON_TEMPLATE"))
--
local label = w:CreateFontString (nil, "overlay", "GameFontHighlightSmall")
label:SetText(L["STRING_FORGE_FILTER_CASTERNAME"] .. ": ")
@@ -556,7 +556,7 @@ function Details:OpenForge()
local entry = fw:CreateTextEntry (w, nil, 120, 20, "entry", "DetailsForgeEncounterSpellsCasterFilter")
entry:SetHook("OnTextChanged", function() f:refresh() end)
entry:SetPoint("left", label, "right", 2, 0)
entry:SetTemplate (Details.gump:GetTemplate ("button", "OPTIONS_BUTTON_TEMPLATE"))
entry:SetTemplate(Details.gump:GetTemplate("button", "OPTIONS_BUTTON_TEMPLATE"))
--
local label = w:CreateFontString (nil, "overlay", "GameFontHighlightSmall")
label:SetText(L["STRING_FORGE_FILTER_ENCOUNTERNAME"] .. ": ")
@@ -564,7 +564,7 @@ function Details:OpenForge()
local entry = fw:CreateTextEntry (w, nil, 120, 20, "entry", "DetailsForgeEncounterSpellsEncounterFilter")
entry:SetHook("OnTextChanged", function() f:refresh() end)
entry:SetPoint("left", label, "right", 2, 0)
entry:SetTemplate (Details.gump:GetTemplate ("button", "OPTIONS_BUTTON_TEMPLATE"))
entry:SetTemplate(Details.gump:GetTemplate("button", "OPTIONS_BUTTON_TEMPLATE"))
end
return DetailsForgeEncounterBossSpellsFilterPanel
end,
@@ -709,7 +709,7 @@ function Details:OpenForge()
local searchEntry = fw:CreateTextEntry(npcIdFrame, nil, 120, 20, "entry", "DetailsForgeEncounterNpcIDsFilter")
searchEntry:SetHook("OnTextChanged", function() f:refresh() end)
searchEntry:SetPoint("left", filterSpellNameLabel, "right", 2, 0)
searchEntry:SetTemplate(Details.gump:GetTemplate ("button", "OPTIONS_BUTTON_TEMPLATE"))
searchEntry:SetTemplate(Details.gump:GetTemplate("button", "OPTIONS_BUTTON_TEMPLATE"))
end
return DetailsForgeEncounterNpcIDsFilterPanel
@@ -803,7 +803,7 @@ function Details:OpenForge()
local entry = fw:CreateTextEntry (w, nil, 120, 20, "entry", "DetailsForgeDBMBarsTextFilter")
entry:SetHook("OnTextChanged", function() f:refresh() end)
entry:SetPoint("left", label, "right", 2, 0)
entry:SetTemplate (Details.gump:GetTemplate ("button", "OPTIONS_BUTTON_TEMPLATE"))
entry:SetTemplate(Details.gump:GetTemplate("button", "OPTIONS_BUTTON_TEMPLATE"))
--
local label = w:CreateFontString (nil, "overlay", "GameFontHighlightSmall")
label:SetText(L["STRING_FORGE_FILTER_ENCOUNTERNAME"] .. ": ")
@@ -811,7 +811,7 @@ function Details:OpenForge()
local entry = fw:CreateTextEntry (w, nil, 120, 20, "entry", "DetailsForgeDBMBarsEncounterFilter")
entry:SetHook("OnTextChanged", function() f:refresh() end)
entry:SetPoint("left", label, "right", 2, 0)
entry:SetTemplate (Details.gump:GetTemplate ("button", "OPTIONS_BUTTON_TEMPLATE"))
entry:SetTemplate(Details.gump:GetTemplate("button", "OPTIONS_BUTTON_TEMPLATE"))
end
return DetailsForgeDBMBarsFilterPanel
end,
@@ -906,7 +906,7 @@ function Details:OpenForge()
if (type(spellid) == "number") then
if (spellid < 0) then
local title, description, depth, abilityIcon, displayInfo, siblingID, nextSectionID, filteredByDifficulty, link, startsOpen, flag1, flag2, flag3, flag4 = DetailsFramework.EncounterJournal.EJ_GetSectionInfo (abs (spellid))
local title, description, depth, abilityIcon, displayInfo, siblingID, nextSectionID, filteredByDifficulty, link, startsOpen, flag1, flag2, flag3, flag4 = DetailsFramework.EncounterJournal.EJ_GetSectionInfo (abs(spellid))
spellname, spellicon = title, abilityIcon
else
spellname, _, spellicon = GetSpellInfo(spellid)
@@ -934,7 +934,7 @@ function Details:OpenForge()
local entry = fw:CreateTextEntry (w, nil, 120, 20, "entry", "DetailsForgeBigWigsBarsTextFilter")
entry:SetHook("OnTextChanged", function() f:refresh() end)
entry:SetPoint("left", label, "right", 2, 0)
entry:SetTemplate (Details.gump:GetTemplate ("button", "OPTIONS_BUTTON_TEMPLATE"))
entry:SetTemplate(Details.gump:GetTemplate("button", "OPTIONS_BUTTON_TEMPLATE"))
--
local label = w:CreateFontString (nil, "overlay", "GameFontHighlightSmall")
label:SetText(L["STRING_FORGE_FILTER_ENCOUNTERNAME"] .. ": ")
@@ -942,7 +942,7 @@ function Details:OpenForge()
local entry = fw:CreateTextEntry (w, nil, 120, 20, "entry", "DetailsForgeBWBarsEncounterFilter")
entry:SetHook("OnTextChanged", function() f:refresh() end)
entry:SetPoint("left", label, "right", 2, 0)
entry:SetTemplate (Details.gump:GetTemplate ("button", "OPTIONS_BUTTON_TEMPLATE"))
entry:SetTemplate(Details.gump:GetTemplate("button", "OPTIONS_BUTTON_TEMPLATE"))
--
end
return DetailsForgeBigWigsBarsFilterPanel
@@ -1042,9 +1042,9 @@ function Details:OpenForge()
end
for index, button in ipairs(buttons) do
button:SetTemplate (CONST_BUTTON_TEMPLATE)
button:SetTemplate(CONST_BUTTON_TEMPLATE)
end
buttons[module_number]:SetTemplate (CONST_BUTTONSELECTED_TEMPLATE)
buttons[module_number]:SetTemplate(CONST_BUTTONSELECTED_TEMPLATE)
local module = all_modules [module_number]
if (module) then
@@ -1075,7 +1075,7 @@ function Details:OpenForge()
for o = 1, #fillpanel.scrollframe.lines do
for i = 1, #fillpanel.scrollframe.lines [o].entry_inuse do
--text entry
fillpanel.scrollframe.lines [o].entry_inuse [i]:SetTemplate (fw:GetTemplate ("button", "DETAILS_FORGE_TEXTENTRY_TEMPLATE"))
fillpanel.scrollframe.lines [o].entry_inuse [i]:SetTemplate(fw:GetTemplate("button", "DETAILS_FORGE_TEXTENTRY_TEMPLATE"))
end
end
end
@@ -1109,10 +1109,10 @@ function Details:OpenForge()
for i = 1, #all_modules do
local module = all_modules [i]
local b = fw:CreateButton (f, select_module, 140, 20, module.name, i)
local b = fw:CreateButton(f, select_module, 140, 20, module.name, i)
b.tooltip = module.desc
b:SetTemplate (CONST_BUTTON_TEMPLATE)
b:SetTemplate(CONST_BUTTON_TEMPLATE)
b:SetIcon ([[Interface\BUTTONS\UI-GuildButton-PublicNote-Up]], nil, nil, nil, nil, {1, 1, 1, 0.7})
b:SetWidth(140)
+12 -12
View File
@@ -6,7 +6,7 @@ local DF = _G.DetailsFramework
local _
function Details:InitializeMacrosWindow()
local DetailsMacrosPanel = DF:CreateSimplePanel (UIParent, 700, 480, "Details! Useful Macros", "DetailsMacrosPanel")
local DetailsMacrosPanel = DF:CreateSimplePanel(UIParent, 700, 480, "Details! Useful Macros", "DetailsMacrosPanel")
DetailsMacrosPanel.Frame = DetailsMacrosPanel
DetailsMacrosPanel.__name = "Macros"
DetailsMacrosPanel.real_name = "DETAILS_MACROSWINDOW"
@@ -27,7 +27,7 @@ function Details.OpenMacrosWindow()
if (not DetailsMacrosPanel or not DetailsMacrosPanel.Initialized) then
DetailsMacrosPanel.Initialized = true
local f = DetailsMacrosPanel or DF:CreateSimplePanel (UIParent, 700, 480, "Details! Useful Macros", "DetailsMacrosPanel")
local f = DetailsMacrosPanel or DF:CreateSimplePanel(UIParent, 700, 480, "Details! Useful Macros", "DetailsMacrosPanel")
local scrollbox_line_backdrop_color = {0, 0, 0, 0.2}
local scrollbox_line_backdrop_color_onenter = {.3, .3, .3, 0.5}
@@ -37,10 +37,10 @@ function Details.OpenMacrosWindow()
f.bg1 = f:CreateTexture(nil, "background")
f.bg1:SetTexture([[Interface\AddOns\Details\images\background]], true)
f.bg1:SetAlpha (0.8)
f.bg1:SetVertexColor (0.27, 0.27, 0.27)
f.bg1:SetVertTile (true)
f.bg1:SetHorizTile (true)
f.bg1:SetAlpha(0.8)
f.bg1:SetVertexColor(0.27, 0.27, 0.27)
f.bg1:SetVertTile(true)
f.bg1:SetHorizTile(true)
f.bg1:SetSize(790, 454)
f.bg1:SetAllPoints()
f:SetBackdrop({edgeFile = [[Interface\Buttons\WHITE8X8]], edgeSize = 1, bgFile = [[Interface\AddOns\Details\images\background]], tileSize = 64, tile = true})
@@ -50,11 +50,11 @@ function Details.OpenMacrosWindow()
local macrosAvailable = Details.MacroList
local OnEnterMacroButton = function(self)
self:SetBackdropColor(unpack (scrollbox_line_backdrop_color_onenter))
self:SetBackdropColor(unpack(scrollbox_line_backdrop_color_onenter))
end
local onLeaveMacroButton = function(self)
self:SetBackdropColor(unpack (scrollbox_line_backdrop_color))
self:SetBackdropColor(unpack(scrollbox_line_backdrop_color))
end
local updateMacroLine = function(self, index, title, desc, macroText)
@@ -92,16 +92,16 @@ function Details.OpenMacrosWindow()
line:SetScript("OnEnter", OnEnterMacroButton)
line:SetScript("OnLeave", onLeaveMacroButton)
line:SetBackdrop({bgFile = [[Interface\Tooltips\UI-Tooltip-Background]], tileSize = 64, tile = true, edgeFile = [[Interface\Buttons\WHITE8X8]], edgeSize = 1})
line:SetBackdropColor(unpack (scrollbox_line_backdrop_color))
line:SetBackdropColor(unpack(scrollbox_line_backdrop_color))
line:SetBackdropBorderColor(0, 0, 0, 0.3)
local titleLabel = DF:CreateLabel(line, "", DF:GetTemplate ("font", "ORANGE_FONT_TEMPLATE"))
local titleLabel = DF:CreateLabel(line, "", DF:GetTemplate("font", "ORANGE_FONT_TEMPLATE"))
titleLabel.textsize = 14
titleLabel.textcolor = "yellow"
local descLabel = DF:CreateLabel(line, "", DF:GetTemplate ("font", "ORANGE_FONT_TEMPLATE"))
local descLabel = DF:CreateLabel(line, "", DF:GetTemplate("font", "ORANGE_FONT_TEMPLATE"))
descLabel.textsize = 12
local options_dropdown_template = DF:GetTemplate ("dropdown", "OPTIONS_DROPDOWN_TEMPLATE")
local options_dropdown_template = DF:GetTemplate("dropdown", "OPTIONS_DROPDOWN_TEMPLATE")
options_dropdown_template = DF.table.copy ({}, options_dropdown_template)
options_dropdown_template.backdropcolor = {.51, .51, .51, .3}
options_dropdown_template.onenterbordercolor = {.51, .51, .51, .2}
+79 -81
View File
@@ -18,7 +18,7 @@ local unpack = unpack
local CreateFrame = CreateFrame
local _GetTime = GetTime
local _GetCursorPosition = GetCursorPosition
local _UIParent = UIParent
local UIParent = UIParent
local _IsAltKeyDown = IsAltKeyDown
local _IsShiftKeyDown = IsShiftKeyDown
local _IsControlKeyDown = IsControlKeyDown
@@ -237,7 +237,7 @@ function Details:MostrarScrollBar(sem_animacao)
local nao_mostradas = self.rows_showing - self.rows_fit_in_window
local slider_height = nao_mostradas*self.row_height
self.scroll.scrollMax = slider_height
self.scroll:SetMinMaxValues (0, slider_height)
self.scroll:SetMinMaxValues(0, slider_height)
self.rolagem = true
self.scroll:Enable()
@@ -1658,13 +1658,13 @@ end
function Details:DelayOptionsRefresh(instance, noReopen)
if (_G.DetailsOptionsWindow and _G.DetailsOptionsWindow:IsShown()) then
Details:ScheduleTimer ("OpenOptionsWindow", 0.1, {instance or _G.DetailsOptionsWindow.instance, noReopen})
Details:ScheduleTimer("OpenOptionsWindow", 0.1, {instance or _G.DetailsOptionsWindow.instance, noReopen})
end
end
function Details:RefreshLockedState()
if (not self.baseframe and self.meu_id and self:IsEnabled()) then
self:ScheduleTimer ("RefreshLockedState", 1)
self:ScheduleTimer("RefreshLockedState", 1)
return
elseif (not self.baseframe) then
return
@@ -1982,7 +1982,7 @@ local lineScript_Onmouseup = function(self, button)
end
end
if (Details.row_singleclick_overwrite [self._instance.atributo] and type (Details.row_singleclick_overwrite [self._instance.atributo][self._instance.sub_atributo]) == "function") then
if (Details.row_singleclick_overwrite [self._instance.atributo] and type(Details.row_singleclick_overwrite [self._instance.atributo][self._instance.sub_atributo]) == "function") then
return Details.row_singleclick_overwrite [self._instance.atributo][self._instance.sub_atributo] (_, self.minha_tabela, self._instance, is_shift_down, is_control_down)
end
@@ -2413,10 +2413,10 @@ local icon_frame_on_click_up = function(self, button)
if (Details.ilevel.core:HasQueuedInspec (self.unitname)) then
--icon animation
local anim = tremove (Details.icon_animations.load.available)
local anim = tremove(Details.icon_animations.load.available)
if (not anim) then
icon_frame_create_animation()
anim = tremove (Details.icon_animations.load.available)
anim = tremove(Details.icon_animations.load.available)
end
local f = anim
@@ -2435,13 +2435,13 @@ local icon_frame_on_click_up = function(self, button)
frame.question_icon:Hide()
end
end
Details:ScheduleTimer ("HideBarQuestionIcon", 1, f)
Details:ScheduleTimer("HideBarQuestionIcon", 1, f)
self.icon_animation = anim
anim.icon_frame = self
local pid
pid = icon_frame_events:ScheduleTimer ("CancelAnim", 1, {anim})
pid = icon_frame_events:ScheduleTimer("CancelAnim", 1, {anim})
Details.icon_animations.load.in_use [anim] = pid
anim.parent = self
@@ -2455,10 +2455,10 @@ local icon_frame_on_click_up = function(self, button)
end
--icon animation
local anim = tremove (Details.icon_animations.load.available)
local anim = tremove(Details.icon_animations.load.available)
if (not anim) then
icon_frame_create_animation()
anim = tremove (Details.icon_animations.load.available)
anim = tremove(Details.icon_animations.load.available)
end
anim:Show()
@@ -2475,9 +2475,9 @@ local icon_frame_on_click_up = function(self, button)
local pid
if (does_query) then
pid = icon_frame_events:ScheduleTimer ("CancelAnim", 4, {anim, true})
pid = icon_frame_events:ScheduleTimer("CancelAnim", 4, {anim, true})
else
pid = icon_frame_events:ScheduleTimer ("CancelAnim", 0.2, {anim})
pid = icon_frame_events:ScheduleTimer("CancelAnim", 0.2, {anim})
end
Details.icon_animations.load.in_use [anim] = pid
anim.parent = self
@@ -2996,7 +2996,7 @@ local hide_click_func = function()
--empty
end
function Details:InstanceAlert (msg, icon, time, clickfunc, doflash, forceAlert)
function Details:InstanceAlert (msg, icon, timeInSeconds, clickfunc, doflash, forceAlert)
if (not forceAlert and Details.streamer_config.no_alerts) then
--return
@@ -3059,9 +3059,9 @@ function Details:InstanceAlert (msg, icon, time, clickfunc, doflash, forceAlert)
self.alert.button.func_param = {unpack(clickfunc, 2)}
end
time = time or 15
self.alert_time = time
Details:ScheduleTimer ("InstanceAlertTime", time, self)
timeInSeconds = timeInSeconds or 15
self.alert_time = timeInSeconds
Details:ScheduleTimer("InstanceAlertTime", timeInSeconds, self)
self.alert:SetPoint("bottom", self.baseframe, "bottom", 0, -12)
self.alert:SetPoint("left", self.baseframe, "left", 3, 0)
@@ -3077,7 +3077,6 @@ function Details:InstanceAlert (msg, icon, time, clickfunc, doflash, forceAlert)
end
self.alert:Play()
end
local alert_on_click = function(self, button)
@@ -3090,8 +3089,7 @@ local alert_on_click = function(self, button)
self:GetParent():Hide()
end
local function CreateAlertFrame (baseframe, instancia)
local function CreateAlertFrame(baseframe, instancia)
local frame_upper = CreateFrame("scrollframe", "DetailsAlertFrameScroll" .. instancia.meu_id, baseframe)
frame_upper:SetPoint("bottom", baseframe, "bottom")
frame_upper:SetPoint("left", baseframe, "left", 3, 0)
@@ -3215,7 +3213,7 @@ local function CreateAlertFrame (baseframe, instancia)
end
function alert_bg:DoFlash()
C_Timer.After (0.23, do_flash)
C_Timer.After(0.23, do_flash)
end
alert_bg.text = text
@@ -3247,7 +3245,7 @@ function Details:InstanceMsg (text, icon, textcolor, iconcoords, iconcolor)
self.freeze_texto:SetTextColor(1, 1, 1, 1)
end
if (iconcoords and type (iconcoords) == "table") then
if (iconcoords and type(iconcoords) == "table") then
self.freeze_icon:SetTexCoord(unpack(iconcoords))
else
self.freeze_icon:SetTexCoord(0, 1, 0, 1)
@@ -3267,10 +3265,10 @@ function Details:schedule_hide_anti_overlap (self)
end
local function hide_anti_overlap (self)
if (self.schdule) then
Details:CancelTimer (self.schdule)
Details:CancelTimer(self.schdule)
self.schdule = nil
end
local schdule = Details:ScheduleTimer ("schedule_hide_anti_overlap", 0.3, self)
local schdule = Details:ScheduleTimer("schedule_hide_anti_overlap", 0.3, self)
self.schdule = schdule
end
@@ -3279,7 +3277,7 @@ local function show_anti_overlap (instance, host, side)
local anti_menu_overlap = instance.baseframe.anti_menu_overlap
if (anti_menu_overlap.schdule) then
Details:CancelTimer (anti_menu_overlap.schdule)
Details:CancelTimer(anti_menu_overlap.schdule)
anti_menu_overlap.schdule = nil
end
@@ -3310,7 +3308,7 @@ do
local tooltip_anchor = CreateFrame("frame", "DetailsTooltipAnchor", UIParent,"BackdropTemplate")
tooltip_anchor:SetSize(140, 20)
tooltip_anchor:SetAlpha(0)
tooltip_anchor:SetMovable (false)
tooltip_anchor:SetMovable(false)
tooltip_anchor:SetClampedToScreen (true)
tooltip_anchor.locked = true
tooltip_anchor:SetBackdrop({bgFile = [[Interface\Tooltips\UI-Tooltip-Background]], edgeFile = [[Interface\DialogFrame\UI-DialogBox-Border]], edgeSize = 10, insets = {left = 1, right = 1, top = 2, bottom = 1}})
@@ -3357,7 +3355,7 @@ do
if (self.locked) then
self:SetAlpha(1)
self:EnableMouse(true)
self:SetMovable (true)
self:SetMovable(true)
self:SetFrameStrata("FULLSCREEN")
self.locked = false
tooltip_anchor.alert.animOut:Stop()
@@ -3366,7 +3364,7 @@ do
self:SetAlpha(0)
self:EnableMouse(false)
self:SetFrameStrata("MEDIUM")
self:SetMovable (false)
self:SetMovable(false)
self.locked = true
tooltip_anchor.alert.animIn:Stop()
tooltip_anchor.alert.animOut:Play()
@@ -3409,7 +3407,7 @@ function gump:CriaJanelaPrincipal (ID, instancia, criando)
-- main frames -----------------------------------------------------------------------------------------------------------------------------------------------
--baseframe is the lowest frame in the window architecture
local baseframe = CreateFrame("scrollframe", "DetailsBaseFrame" .. ID, _UIParent, "BackdropTemplate")
local baseframe = CreateFrame("scrollframe", "DetailsBaseFrame" .. ID, UIParent, "BackdropTemplate")
baseframe:SetMovable(true)
baseframe:SetResizable(true)
baseframe:SetUserPlaced(false)
@@ -3463,7 +3461,7 @@ function gump:CriaJanelaPrincipal (ID, instancia, criando)
instancia.windowBackgroundDisplay = backgrounddisplay
--row frame is the parent of rows, it have setallpoints on baseframe
local rowframe = CreateFrame("frame", "DetailsRowFrame"..ID, _UIParent) --row frame
local rowframe = CreateFrame("frame", "DetailsRowFrame"..ID, UIParent) --row frame
rowframe:SetAllPoints(baseframe)
rowframe:SetFrameStrata(baseframe_strata)
rowframe:SetFrameLevel(3)
@@ -3555,7 +3553,7 @@ function gump:CriaJanelaPrincipal (ID, instancia, criando)
--config set
scrollbar:SetOrientation ("VERTICAL")
scrollbar.scrollMax = 0
scrollbar:SetMinMaxValues (0, 0)
scrollbar:SetMinMaxValues(0, 0)
scrollbar:SetValue(0)
scrollbar.ultimo = 0
@@ -3597,7 +3595,7 @@ function gump:CriaJanelaPrincipal (ID, instancia, criando)
baseframe:SetClampedToScreen (true)
baseframe:SetSize(Details.new_window_size.width, Details.new_window_size.height)
baseframe:SetPoint("center", _UIParent)
baseframe:SetPoint("center", UIParent)
baseframe:EnableMouseWheel(false)
baseframe:EnableMouse(true)
@@ -5444,7 +5442,7 @@ function Details:StatusBarAlert(text, icon, color, time)
if (icon or text) then
statusbar:Show()
if (time) then
Details:ScheduleTimer ("StatusBarAlertTime", time, self)
Details:ScheduleTimer("StatusBarAlertTime", time, self)
end
else
statusbar:Hide()
@@ -5541,7 +5539,7 @@ function gump:CriaRodape(baseframe, instancia)
baseframe.DOWNFrame:Show()
baseframe.DOWNFrame:EnableMouse(true)
baseframe.DOWNFrame:SetMovable (true)
baseframe.DOWNFrame:SetMovable(true)
baseframe.DOWNFrame:SetResizable(true)
BGFrame_scripts(baseframe.DOWNFrame, baseframe, instancia)
@@ -6157,7 +6155,7 @@ function Details:SetMenuOwner (self, instance)
local instance_height = instance.baseframe:GetHeight()
if (y + math.max (instance_height, 250) > screen_height) then
if (y + math.max(instance_height, 250) > screen_height) then
GameCooltip:SetOwner(self, "top", "bottom", 0, -10)
else
GameCooltip:SetOwner(self, "bottom", "top", 0, 0)
@@ -6395,7 +6393,7 @@ local buildSegmentTooltip = function(self, deltaTime)
local wasted = totalRealTime - decorrido
--wasted time
gameCooltip:AddLine(Loc["STRING_SEGMENTS_LIST_WASTED_TIME"] .. ":", "|cFFFF3300" .. Details.gump:IntegerToTimer (wasted) .. " (" .. floor (wasted / totalRealTime * 100) .. "%)|r", 2, "white", "white")
gameCooltip:AddLine(Loc["STRING_SEGMENTS_LIST_WASTED_TIME"] .. ":", "|cFFFF3300" .. Details.gump:IntegerToTimer (wasted) .. " (" .. floor(wasted / totalRealTime * 100) .. "%)|r", 2, "white", "white")
gameCooltip:AddStatusBar(100, 2, 0, 0, 0, 0.35, false, false, "Skyline")
gameCooltip:AddLine(Loc["STRING_SEGMENTS_LIST_TOTALTIME"] .. ":", Details.gump:IntegerToTimer (endedAt - startedAt), 2, "white", "white")
@@ -6405,7 +6403,7 @@ local buildSegmentTooltip = function(self, deltaTime)
local wasted = totalRealTime - decorrido
--wasted time
gameCooltip:AddLine(Loc["STRING_SEGMENTS_LIST_WASTED_TIME"] .. ":", "|cFFFF3300" .. Details.gump:IntegerToTimer (wasted) .. " (" .. floor (wasted / totalRealTime * 100) .. "%)|r", 2, "white", "white")
gameCooltip:AddLine(Loc["STRING_SEGMENTS_LIST_WASTED_TIME"] .. ":", "|cFFFF3300" .. Details.gump:IntegerToTimer (wasted) .. " (" .. floor(wasted / totalRealTime * 100) .. "%)|r", 2, "white", "white")
gameCooltip:AddStatusBar(100, 2, 0, 0, 0, 0.35, false, false, "Skyline")
gameCooltip:AddLine(Loc["STRING_SEGMENTS_LIST_TOTALTIME"] .. ":", Details.gump:IntegerToTimer (totalRealTime), 2, "white", "white")
@@ -6687,7 +6685,7 @@ local buildSegmentTooltip = function(self, deltaTime)
gameCooltip:AddLine(Loc["STRING_SEGMENTS_LIST_TIMEINCOMBAT"] .. ":", Details.gump:IntegerToTimer (decorrido), 2, "white", "white")
--wasted time
gameCooltip:AddLine(Loc["STRING_SEGMENTS_LIST_WASTED_TIME"] .. ":", "|cFFFF3300" .. Details.gump:IntegerToTimer (wasted) .. " (" .. floor (wasted / totalRealTime * 100) .. "%)|r", 2, "white", "white")
gameCooltip:AddLine(Loc["STRING_SEGMENTS_LIST_WASTED_TIME"] .. ":", "|cFFFF3300" .. Details.gump:IntegerToTimer (wasted) .. " (" .. floor(wasted / totalRealTime * 100) .. "%)|r", 2, "white", "white")
gameCooltip:AddStatusBar (100, 2, 0, 0, 0, 0.35, false, false, "Skyline")
gameCooltip:AddLine(Loc["STRING_SEGMENTS_LIST_TOTALTIME"] .. ":", Details.gump:IntegerToTimer (endedAt - startedAt) .. " [|cFFFF3300" .. Details.gump:IntegerToTimer (totalRealTime - decorrido) .. "|r]", 2, "white", "white")
@@ -6701,7 +6699,7 @@ local buildSegmentTooltip = function(self, deltaTime)
gameCooltip:AddLine(Loc["STRING_SEGMENTS_LIST_TOTALTIME"] .. ":", Details.gump:IntegerToTimer (totalRealTime), 2, "white", "white")
--wasted time
gameCooltip:AddLine(Loc["STRING_SEGMENTS_LIST_WASTED_TIME"] .. ":", "|cFFFF3300" .. Details.gump:IntegerToTimer (wasted) .. " (" .. floor (wasted / totalRealTime * 100) .. "%)|r", 2, "white", "white")
gameCooltip:AddLine(Loc["STRING_SEGMENTS_LIST_WASTED_TIME"] .. ":", "|cFFFF3300" .. Details.gump:IntegerToTimer (wasted) .. " (" .. floor(wasted / totalRealTime * 100) .. "%)|r", 2, "white", "white")
gameCooltip:AddStatusBar (100, 2, 0, 0, 0, 0.35, false, false, "Skyline")
else
@@ -7319,16 +7317,16 @@ end
--update the window click through state
local updateClickThroughListener = Details:CreateEventListener()
function updateClickThroughListener:EnterCombat()
Details:InstanceCall (function(instance)
C_Timer.After (1.5, function()
Details:InstanceCall(function(instance)
C_Timer.After(1.5, function()
instance:UpdateClickThrough()
end)
end)
end
function updateClickThroughListener:LeaveCombat()
Details:InstanceCall (function(instance)
C_Timer.After (1.5, function()
Details:InstanceCall(function(instance)
C_Timer.After(1.5, function()
instance:UpdateClickThrough()
end)
end)
@@ -7498,25 +7496,25 @@ end
function Details:DelayedCheckCombatAlpha (instance, alpha)
if (UnitAffectingCombat("player") or InCombatLockdown()) then
instance:SetWindowAlphaForCombat (true, true, alpha) --hida a janela
instance:SetWindowAlphaForCombat (true, true, alpha) --hida a janela
instance:SetWindowAlphaForCombat(true, true, alpha) --hida a janela
instance:SetWindowAlphaForCombat(true, true, alpha) --hida a janela
end
end
function Details:DelayedCheckOutOfCombatAlpha (instance, alpha)
if (not UnitAffectingCombat("player") and not InCombatLockdown()) then
instance:SetWindowAlphaForCombat (true, true, alpha) --hida a janela
instance:SetWindowAlphaForCombat (true, true, alpha) --hida a janela
instance:SetWindowAlphaForCombat(true, true, alpha) --hida a janela
instance:SetWindowAlphaForCombat(true, true, alpha) --hida a janela
end
end
function Details:DelayedCheckOutOfCombatAndGroupAlpha (instance, alpha)
if ((Details.zone_type == "raid" or Details.zone_type == "party") and IsInInstance()) then
if (UnitAffectingCombat("player") or InCombatLockdown()) then
instance:SetWindowAlphaForCombat (false, false, alpha) --deshida a janela
instance:SetWindowAlphaForCombat(false, false, alpha) --deshida a janela
else
instance:SetWindowAlphaForCombat (true, true, alpha) --hida a janela
instance:SetWindowAlphaForCombat (true, true, alpha) --hida a janela
instance:SetWindowAlphaForCombat(true, true, alpha) --hida a janela
instance:SetWindowAlphaForCombat(true, true, alpha) --hida a janela
end
end
end
@@ -7543,15 +7541,15 @@ function Details:AdjustAlphaByContext(interacting)
if (self.hide_on_context[3].inverse) then
--while in group
if (Details.in_group) then
self:SetWindowAlphaForCombat (true, true, getAlphaByContext(self, 3)) --hida a janela
self:SetWindowAlphaForCombat (true, true, getAlphaByContext(self, 3)) --hida a janela
self:SetWindowAlphaForCombat(true, true, getAlphaByContext(self, 3)) --hida a janela
self:SetWindowAlphaForCombat(true, true, getAlphaByContext(self, 3)) --hida a janela
hasRuleEnabled = true
end
else
--while not in group
if (not Details.in_group) then
self:SetWindowAlphaForCombat (true, true, getAlphaByContext(self, 3)) --hida a janela
self:SetWindowAlphaForCombat (true, true, getAlphaByContext(self, 3)) --hida a janela
self:SetWindowAlphaForCombat(true, true, getAlphaByContext(self, 3)) --hida a janela
self:SetWindowAlphaForCombat(true, true, getAlphaByContext(self, 3)) --hida a janela
hasRuleEnabled = true
end
end
@@ -7561,8 +7559,8 @@ function Details:AdjustAlphaByContext(interacting)
if (self.hide_on_context[4].enabled) then
local isInInstance = IsInInstance()
if (not isInInstance or (not Details.zone_type == "raid" and not Details.zone_type == "party")) then
self:SetWindowAlphaForCombat (true, true, getAlphaByContext(self, 4)) --hida a janela
self:SetWindowAlphaForCombat (true, true, getAlphaByContext(self, 4)) --hida a janela
self:SetWindowAlphaForCombat(true, true, getAlphaByContext(self, 4)) --hida a janela
self:SetWindowAlphaForCombat(true, true, getAlphaByContext(self, 4)) --hida a janela
hasRuleEnabled = true
end
end
@@ -7571,8 +7569,8 @@ function Details:AdjustAlphaByContext(interacting)
if (self.hide_on_context[5].enabled) then
local isInInstance = IsInInstance()
if (isInInstance or Details.zone_type == "raid" or Details.zone_type == "party") then
self:SetWindowAlphaForCombat (true, true, getAlphaByContext(self, 5)) --hida a janela
self:SetWindowAlphaForCombat (true, true, getAlphaByContext(self, 5)) --hida a janela
self:SetWindowAlphaForCombat(true, true, getAlphaByContext(self, 5)) --hida a janela
self:SetWindowAlphaForCombat(true, true, getAlphaByContext(self, 5)) --hida a janela
hasRuleEnabled = true
end
end
@@ -7580,7 +7578,7 @@ function Details:AdjustAlphaByContext(interacting)
--raid debug (inside instance + out of combat)
if (self.hide_on_context[6].enabled) then
if ((Details.zone_type == "raid" or Details.zone_type == "party") and IsInInstance()) then
Details:ScheduleTimer ("DelayedCheckOutOfCombatAndGroupAlpha", 0.3, self, getAlphaByContext(self, 6))
Details:ScheduleTimer("DelayedCheckOutOfCombatAndGroupAlpha", 0.3, self, getAlphaByContext(self, 6))
end
end
@@ -7600,8 +7598,8 @@ function Details:AdjustAlphaByContext(interacting)
else
--player is not inside an arena
if (self.hide_on_context[contextId].inverse) then
self:SetWindowAlphaForCombat (true, true, getAlphaByContext(self, contextId))
self:SetWindowAlphaForCombat (true, true, getAlphaByContext(self, contextId))
self:SetWindowAlphaForCombat(true, true, getAlphaByContext(self, contextId))
self:SetWindowAlphaForCombat(true, true, getAlphaByContext(self, contextId))
hasRuleEnabled = true
end
end
@@ -7613,10 +7611,10 @@ function Details:AdjustAlphaByContext(interacting)
if (isInInstance and Details.zone_type == "pvp") then
--player is inside a battleground
if (not self.hide_on_context[7].inverse) then
self:SetWindowAlphaForCombat (true, true, getAlphaByContext(self, 7)) --hida a janela
self:SetWindowAlphaForCombat (true, true, getAlphaByContext(self, 7)) --hida a janela
self:SetWindowAlphaForCombat(true, true, getAlphaByContext(self, 7)) --hida a janela
self:SetWindowAlphaForCombat(true, true, getAlphaByContext(self, 7)) --hida a janela
else
self:SetWindowAlphaForCombat (false, false, getAlphaByContext(self, 7)) --deshida a janela
self:SetWindowAlphaForCombat(false, false, getAlphaByContext(self, 7)) --deshida a janela
end
hasRuleEnabled = true
@@ -7624,10 +7622,10 @@ function Details:AdjustAlphaByContext(interacting)
--player is not inside a battleground
if (not self.hide_on_context[7].inverse) then
--there's no inverse rule: do nothing
--self:SetWindowAlphaForCombat (false, false, getAlphaByContext(self, 7)) --deshida a janela
--self:SetWindowAlphaForCombat(false, false, getAlphaByContext(self, 7)) --deshida a janela
else
self:SetWindowAlphaForCombat (true, true, getAlphaByContext(self, 7)) --hida a janela
self:SetWindowAlphaForCombat (true, true, getAlphaByContext(self, 7)) --hida a janela
self:SetWindowAlphaForCombat(true, true, getAlphaByContext(self, 7)) --hida a janela
self:SetWindowAlphaForCombat(true, true, getAlphaByContext(self, 7)) --hida a janela
hasRuleEnabled = true
end
end
@@ -7638,20 +7636,20 @@ function Details:AdjustAlphaByContext(interacting)
if (_G.DetailsMythicPlusFrame and _G.DetailsMythicPlusFrame.IsDoingMythicDungeon) then
--player is inside a dungeon mythic+
if (not self.hide_on_context[8].inverse) then
self:SetWindowAlphaForCombat (true, true, getAlphaByContext(self, 8)) --hida a janela
self:SetWindowAlphaForCombat (true, true, getAlphaByContext(self, 8)) --hida a janela
self:SetWindowAlphaForCombat(true, true, getAlphaByContext(self, 8)) --hida a janela
self:SetWindowAlphaForCombat(true, true, getAlphaByContext(self, 8)) --hida a janela
else
self:SetWindowAlphaForCombat (false, false, getAlphaByContext(self, 8)) --deshida a janela
self:SetWindowAlphaForCombat(false, false, getAlphaByContext(self, 8)) --deshida a janela
end
hasRuleEnabled = true
else
if (not self.hide_on_context[8].inverse) then
--there's no inverse rule: do nothing
--self:SetWindowAlphaForCombat (false, false, getAlphaByContext(self, 8)) --deshida a janela
--self:SetWindowAlphaForCombat(false, false, getAlphaByContext(self, 8)) --deshida a janela
else
self:SetWindowAlphaForCombat (true, true, getAlphaByContext(self, 8)) --hida a janela
self:SetWindowAlphaForCombat (true, true, getAlphaByContext(self, 8)) --hida a janela
self:SetWindowAlphaForCombat(true, true, getAlphaByContext(self, 8)) --hida a janela
self:SetWindowAlphaForCombat(true, true, getAlphaByContext(self, 8)) --hida a janela
hasRuleEnabled = true
end
end
@@ -7659,12 +7657,12 @@ function Details:AdjustAlphaByContext(interacting)
--in combat
if (self.hide_on_context[1].enabled) then
Details:ScheduleTimer ("DelayedCheckCombatAlpha", 0.3, self, getAlphaByContext(self, 1))
Details:ScheduleTimer("DelayedCheckCombatAlpha", 0.3, self, getAlphaByContext(self, 1))
end
--out of combat
if (self.hide_on_context[2].enabled) then
Details:ScheduleTimer ("DelayedCheckOutOfCombatAlpha", 0.3, self, getAlphaByContext(self, 2))
Details:ScheduleTimer("DelayedCheckOutOfCombatAlpha", 0.3, self, getAlphaByContext(self, 2))
end
--if no rule is enabled, show the window
@@ -9456,7 +9454,7 @@ local function click_to_change_segment (instancia, buttontype)
local total_shown = segments_filled+2
local goal = segmento_goal+1
local select_ = math.abs (goal - total_shown)
local select_ = math.abs(goal - total_shown)
GameCooltip:Select(1, select_)
instancia:TrocaTabela(segmento_goal)
@@ -9473,7 +9471,7 @@ local function click_to_change_segment (instancia, buttontype)
local total_shown = segments_filled+2
local goal = segmento_goal+1
local select_ = math.abs (goal - total_shown)
local select_ = math.abs(goal - total_shown)
GameCooltip:Select(1, select_)
instancia:TrocaTabela(segmento_goal)
@@ -9486,7 +9484,7 @@ local function click_to_change_segment (instancia, buttontype)
local total_shown = segments_filled+2
local goal = segmento_goal+1
local select_ = math.abs (goal - total_shown)
local select_ = math.abs(goal - total_shown)
GameCooltip:Select(1, select_)
instancia:TrocaTabela(segmento_goal)
@@ -9587,7 +9585,7 @@ function gump:CriaCabecalho (baseframe, instancia)
baseframe.UPFrame:Show()
baseframe.UPFrame:EnableMouse(true)
baseframe.UPFrame:SetMovable (true)
baseframe.UPFrame:SetMovable(true)
baseframe.UPFrame:SetResizable(true)
BGFrame_scripts(baseframe.UPFrame, baseframe, instancia)
@@ -9598,7 +9596,7 @@ function gump:CriaCabecalho (baseframe, instancia)
baseframe.UPFrameConnect:SetPoint("bottomright", baseframe, "topright", 0, -1)
baseframe.UPFrameConnect:SetHeight(2)
baseframe.UPFrameConnect:EnableMouse(true)
baseframe.UPFrameConnect:SetMovable (true)
baseframe.UPFrameConnect:SetMovable(true)
baseframe.UPFrameConnect:SetResizable(true)
baseframe.UPFrameConnect.is_toolbar = true
@@ -9608,7 +9606,7 @@ function gump:CriaCabecalho (baseframe, instancia)
baseframe.UPFrameLeftPart:SetPoint("bottomleft", baseframe, "topleft", 0, 0)
baseframe.UPFrameLeftPart:SetSize(22, 20)
baseframe.UPFrameLeftPart:EnableMouse(true)
baseframe.UPFrameLeftPart:SetMovable (true)
baseframe.UPFrameLeftPart:SetMovable(true)
baseframe.UPFrameLeftPart:SetResizable(true)
baseframe.UPFrameLeftPart.is_toolbar = true
+4 -4
View File
@@ -15,7 +15,7 @@ function Details:OpenNewsWindow(textToShow, dumpValues, keeptext)
return
end
if (textToShow and type (textToShow) == "table") then
if (textToShow and type(textToShow) == "table") then
DetailsNewsWindowLower:SetSize(450, 5000)
DetailsNewsWindowSlider:SetMinMaxValues(0, 5000)
DetailsNewsWindowText:SetHeight(5000)
@@ -118,7 +118,7 @@ function Details:CreateOrOpenNewsWindow()
slider:SetOrientation ("vertical");
slider:SetSize(16, 499)
slider:SetPoint("topleft", frameUpper, "topright")
slider:SetMinMaxValues (0, 2000)
slider:SetMinMaxValues(0, 2000)
slider:SetValue(0)
slider:SetScript("OnValueChanged", function(self)
frameUpper:SetVerticalScroll (self:GetValue())
@@ -155,7 +155,7 @@ function Details:CreateOrOpenNewsWindow()
local onToggleAutoOpen = function(_, _, state)
Details.auto_open_news_window = state
end
local autoOpenCheckbox = DetailsFramework:CreateSwitch(statusBar, onToggleAutoOpen, Details.auto_open_news_window, _, _, _, _, "AutoOpenCheckbox", _, _, _, _, _, DetailsFramework:GetTemplate ("switch", "OPTIONS_CHECKBOX_BRIGHT_TEMPLATE"))
local autoOpenCheckbox = DetailsFramework:CreateSwitch(statusBar, onToggleAutoOpen, Details.auto_open_news_window, _, _, _, _, "AutoOpenCheckbox", _, _, _, _, _, DetailsFramework:GetTemplate("switch", "OPTIONS_CHECKBOX_BRIGHT_TEMPLATE"))
autoOpenCheckbox:SetAsCheckBox()
autoOpenCheckbox:SetPoint("left", statusBar, "left", 2, 0)
@@ -163,7 +163,7 @@ function Details:CreateOrOpenNewsWindow()
autoOpenText:SetPoint("left", autoOpenCheckbox, "right", 2, 0)
DetailsFramework:ApplyStandardBackdrop(statusBar)
statusBar:SetAlpha (0.8)
statusBar:SetAlpha(0.8)
DetailsFramework:BuildStatusbarAuthorInfo(statusBar, "", "")
statusBar.authorName:SetPoint("left", statusBar, "left", 207, 0)
+10 -11
View File
@@ -7,7 +7,7 @@ local Details = _G.Details
local DF = _G.DetailsFramework
local Loc = _G.LibStub("AceLocale-3.0"):GetLocale("Details")
--local SharedMedia = _G.LibStub:GetLibrary("LibSharedMedia-3.0")
--local LDB = _G.LibStub ("LibDataBroker-1.1", true)
--local LDB = _G.LibStub("LibDataBroker-1.1", true)
--local LDBIcon = LDB and _G.LibStub("LibDBIcon-1.0", true)
--options panel namespace
@@ -22,13 +22,13 @@ local preset_version = 3
Details.preset_version = preset_version
--templates
local options_text_template = DF:GetTemplate ("font", "OPTIONS_FONT_TEMPLATE")
local options_dropdown_template = DF:GetTemplate ("dropdown", "OPTIONS_DROPDOWN_TEMPLATE")
local options_switch_template = DF:GetTemplate ("switch", "OPTIONS_CHECKBOX_TEMPLATE")
local options_slider_template = DF:GetTemplate ("slider", "OPTIONS_SLIDER_TEMPLATE")
local options_text_template = DF:GetTemplate("font", "OPTIONS_FONT_TEMPLATE")
local options_dropdown_template = DF:GetTemplate("dropdown", "OPTIONS_DROPDOWN_TEMPLATE")
local options_switch_template = DF:GetTemplate("switch", "OPTIONS_CHECKBOX_TEMPLATE")
local options_slider_template = DF:GetTemplate("slider", "OPTIONS_SLIDER_TEMPLATE")
local options_button_template = DF:GetTemplate ("button", "OPTIONS_BUTTON_TEMPLATE")
local options_button_template_selected = DF.table.copy({}, DF:GetTemplate ("button", "OPTIONS_BUTTON_TEMPLATE"))
local options_button_template = DF:GetTemplate("button", "OPTIONS_BUTTON_TEMPLATE")
local options_button_template_selected = DF.table.copy({}, DF:GetTemplate("button", "OPTIONS_BUTTON_TEMPLATE"))
options_button_template_selected.backdropbordercolor = {1, .8, .2}
--options
@@ -50,7 +50,6 @@ function Details.options.InitializeOptionsWindow(instance)
f.__icon = [[Interface\Scenarios\ScenarioIcon-Interact]]
_G.DetailsPluginContainerWindow.EmbedPlugin(f, f, true)
f.sectionFramesContainer = {}
Details:FormatBackground(f)
DF:ApplyStandardBackdrop(f)
local titleBar = DF:CreateTitleBar(f, "Options Panel")
@@ -145,7 +144,7 @@ function Details.options.InitializeOptionsWindow(instance)
instanceSelection:SetTemplate(options_dropdown_template)
instanceSelection:SetHook("OnEnter", function()
GameCooltip:Reset()
GameCooltip:Preset (2)
GameCooltip:Preset(2)
GameCooltip:AddLine(Loc ["STRING_MINITUTORIAL_OPTIONS_PANEL1"])
GameCooltip:ShowCooltip(instanceSelection.widget, "tooltip")
end)
@@ -192,7 +191,7 @@ function Details.options.InitializeOptionsWindow(instance)
--change log
local changelog = DF:NewButton(footerFrame, _, "$parentOpenChangeLogButton", nil, 140, 20, _detalhes.OpenNewsWindow, "change_log", nil, nil, Loc ["STRING_OPTIONS_CHANGELOG"], 1)
changelog:SetPoint("left", fillbars, "right", 10, 0)
changelog:SetTemplate (options_button_template)
changelog:SetTemplate(options_button_template)
changelog:SetIcon ("Interface\\AddOns\\Details\\images\\icons", nil, nil, nil, {367/512, 399/512, 43/512, 76/512}, {1, 1, 1, 0.8}, 4, 2)
--search field
@@ -254,7 +253,7 @@ function Details.options.InitializeOptionsWindow(instance)
if (optionName:find(searchingText)) then
if optionData.header ~= lastTab then
if lastTab ~= nil then
options[#options+1] = {type = "label", get = function() return "" end, text_template = DF:GetTemplate ("font", "OPTIONS_FONT_TEMPLATE")} -- blank
options[#options+1] = {type = "label", get = function() return "" end, text_template = DF:GetTemplate("font", "OPTIONS_FONT_TEMPLATE")} -- blank
end
options[#options+1] = {type = "label", get = function() return optionData.header end, text_template = {color = "silver", size = 14, font = DF:GetBestFontForLanguage()}}
lastTab = optionData.header
+97 -97
View File
@@ -31,7 +31,7 @@ local Details = _G.Details
local DF = _G.DetailsFramework
local Loc = _G.LibStub("AceLocale-3.0"):GetLocale("Details")
local SharedMedia = _G.LibStub:GetLibrary("LibSharedMedia-3.0")
local LDB = _G.LibStub ("LibDataBroker-1.1", true)
local LDB = _G.LibStub("LibDataBroker-1.1", true)
local LDBIcon = LDB and _G.LibStub("LibDBIcon-1.0", true)
local _
local unpack = _G.unpack
@@ -46,13 +46,13 @@ local mainHeightSize = 800
local presetVersion = 3
--templates
local options_text_template = DF:GetTemplate ("font", "OPTIONS_FONT_TEMPLATE")
local options_dropdown_template = DF:GetTemplate ("dropdown", "OPTIONS_DROPDOWN_TEMPLATE")
local options_switch_template = DF:GetTemplate ("switch", "OPTIONS_CHECKBOX_TEMPLATE")
local options_slider_template = DF:GetTemplate ("slider", "OPTIONS_SLIDER_TEMPLATE")
local options_button_template = DF:GetTemplate ("button", "OPTIONS_BUTTON_TEMPLATE")
local options_text_template = DF:GetTemplate("font", "OPTIONS_FONT_TEMPLATE")
local options_dropdown_template = DF:GetTemplate("dropdown", "OPTIONS_DROPDOWN_TEMPLATE")
local options_switch_template = DF:GetTemplate("switch", "OPTIONS_CHECKBOX_TEMPLATE")
local options_slider_template = DF:GetTemplate("slider", "OPTIONS_SLIDER_TEMPLATE")
local options_button_template = DF:GetTemplate("button", "OPTIONS_BUTTON_TEMPLATE")
local subSectionTitleTextTemplate = DF:GetTemplate ("font", "ORANGE_FONT_TEMPLATE")
local subSectionTitleTextTemplate = DF:GetTemplate("font", "ORANGE_FONT_TEMPLATE")
local font_select_icon, font_select_texcoord = [[Interface\AddOns\Details\images\icons]], {472/512, 513/512, 186/512, 230/512}
local texture_select_icon, texture_select_texcoord = [[Interface\AddOns\Details\images\icons]], {472/512, 513/512, 186/512, 230/512}
@@ -805,7 +805,7 @@ 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)
instance[key] = Details.CopyTable(value)
else
instance[key] = value
end
@@ -837,7 +837,7 @@ do
if (dataTable) then
--add the new skin
_detalhes.savedStyles [#_detalhes.savedStyles+1] = dataTable
_detalhes:Msg (Loc ["STRING_OPTIONS_SAVELOAD_IMPORT_OKEY"])
_detalhes:Msg(Loc ["STRING_OPTIONS_SAVELOAD_IMPORT_OKEY"])
Details.options.SetCurrentInstanceAndRefresh(currentInstance)
afterUpdate()
else
@@ -916,7 +916,7 @@ do
end
end
_detalhes:Msg (Loc ["STRING_OPTIONS_SAVELOAD_APPLYALL"])
_detalhes:Msg(Loc ["STRING_OPTIONS_SAVELOAD_APPLYALL"])
Details.options.SetCurrentInstanceAndRefresh(currentInstance)
afterUpdate()
end,
@@ -2618,7 +2618,7 @@ do
{--text color
type = "color",
get = function()
local r, g, b = unpack (currentInstance.attribute_text.text_color)
local r, g, b = unpack(currentInstance.attribute_text.text_color)
return {r, g, b, a}
end,
set = function(self, r, g, b, a)
@@ -2819,7 +2819,7 @@ do
{--window color (skin color)
type = "color",
get = function()
local r, g, b = unpack (currentInstance.color)
local r, g, b = unpack(currentInstance.color)
return {r, g, b, 1}
end,
@@ -3109,23 +3109,23 @@ do
local hideLeftButton = sectionFrame.MicroDisplayLeftDropdown.hideLeftMicroFrameButton
if (instance.StatusBar ["left"].options.isHidden) then
hideLeftButton:GetNormalTexture():SetDesaturated (false)
hideLeftButton:GetNormalTexture():SetDesaturated(false)
else
hideLeftButton:GetNormalTexture():SetDesaturated (true)
hideLeftButton:GetNormalTexture():SetDesaturated(true)
end
local hide_center_button = sectionFrame.MicroDisplayCenterDropdown.HideCenterMicroFrameButton
if (instance.StatusBar ["center"].options.isHidden) then
hide_center_button:GetNormalTexture():SetDesaturated (false)
hide_center_button:GetNormalTexture():SetDesaturated(false)
else
hide_center_button:GetNormalTexture():SetDesaturated (true)
hide_center_button:GetNormalTexture():SetDesaturated(true)
end
local hide_right_button = sectionFrame.MicroDisplayRightDropdown.HideRightMicroFrameButton
if (instance.StatusBar ["right"].options.isHidden) then
hide_right_button:GetNormalTexture():SetDesaturated (false)
hide_right_button:GetNormalTexture():SetDesaturated(false)
else
hide_right_button:GetNormalTexture():SetDesaturated (true)
hide_right_button:GetNormalTexture():SetDesaturated(true)
end
local left = instance.StatusBar ["left"].__name
@@ -3169,7 +3169,7 @@ do
{--color
type = "color",
get = function()
local r, g, b = unpack (currentInstance.statusbar_info.overlay)
local r, g, b = unpack(currentInstance.statusbar_info.overlay)
local alpha = currentInstance.statusbar_info.alpha
return {r, g, b, alpha}
end,
@@ -3220,7 +3220,7 @@ do
--dropdown on select option
local onMicroDisplaySelect = function(_, _, micro_display)
local anchor, index = unpack (micro_display)
local anchor, index = unpack(micro_display)
if (index == -1) then
return _detalhes.StatusBar:SetPlugin (currentInstance, -1, anchor)
@@ -3280,16 +3280,16 @@ do
_detalhes.StatusBar:SetPlugin (currentInstance, -1, "left")
end
if (currentInstance.StatusBar ["left"].options.isHidden) then
self:GetNormalTexture():SetDesaturated (false)
self:GetNormalTexture():SetDesaturated(false)
else
self:GetNormalTexture():SetDesaturated (true)
self:GetNormalTexture():SetDesaturated(true)
end
end)
hideLeftMicroFrameButton:SetPoint("left", sectionFrame.MicroDisplayLeftDropdown, "right", 2, 0)
hideLeftMicroFrameButton:SetNormalTexture([[Interface\Buttons\UI-GroupLoot-Pass-Down]])
hideLeftMicroFrameButton:SetPushedTexture([[Interface\Buttons\UI-GroupLoot-Pass-Up]])
hideLeftMicroFrameButton:GetNormalTexture():SetDesaturated (true)
hideLeftMicroFrameButton:GetNormalTexture():SetDesaturated(true)
hideLeftMicroFrameButton.tooltip = Loc ["STRING_OPTIONS_MICRODISPLAYS_SHOWHIDE_TOOLTIP"]
hideLeftMicroFrameButton:SetHook("OnEnter", function(self, capsule)
self:GetNormalTexture():SetBlendMode("ADD")
@@ -3306,15 +3306,15 @@ do
end
if (currentInstance.StatusBar ["center"].options.isHidden) then
self:GetNormalTexture():SetDesaturated (false)
self:GetNormalTexture():SetDesaturated(false)
else
self:GetNormalTexture():SetDesaturated (true)
self:GetNormalTexture():SetDesaturated(true)
end
end)
HideCenterMicroFrameButton:SetPoint("left", sectionFrame.MicroDisplayCenterDropdown, "right", 2, 0)
HideCenterMicroFrameButton:SetNormalTexture([[Interface\Buttons\UI-GroupLoot-Pass-Down]])
HideCenterMicroFrameButton:SetPushedTexture([[Interface\Buttons\UI-GroupLoot-Pass-Up]])
HideCenterMicroFrameButton:GetNormalTexture():SetDesaturated (true)
HideCenterMicroFrameButton:GetNormalTexture():SetDesaturated(true)
HideCenterMicroFrameButton.tooltip = Loc ["STRING_OPTIONS_MICRODISPLAYS_SHOWHIDE_TOOLTIP"]
HideCenterMicroFrameButton:SetHook("OnEnter", function(self, capsule)
self:GetNormalTexture():SetBlendMode("ADD")
@@ -3330,15 +3330,15 @@ do
_detalhes.StatusBar:SetPlugin (currentInstance, -1, "right")
end
if (currentInstance.StatusBar ["right"].options.isHidden) then
self:GetNormalTexture():SetDesaturated (false)
self:GetNormalTexture():SetDesaturated(false)
else
self:GetNormalTexture():SetDesaturated (true)
self:GetNormalTexture():SetDesaturated(true)
end
end)
HideRightMicroFrameButton:SetPoint("left", sectionFrame.MicroDisplayRightDropdown, "right", 2, 0)
HideRightMicroFrameButton:SetNormalTexture([[Interface\Buttons\UI-GroupLoot-Pass-Down]])
HideRightMicroFrameButton:SetPushedTexture([[Interface\Buttons\UI-GroupLoot-Pass-Up]])
HideRightMicroFrameButton:GetNormalTexture():SetDesaturated (true)
HideRightMicroFrameButton:GetNormalTexture():SetDesaturated(true)
HideRightMicroFrameButton.tooltip = Loc ["STRING_OPTIONS_MICRODISPLAYS_SHOWHIDE_TOOLTIP"]
HideRightMicroFrameButton:SetHook("OnEnter", function(self, capsule)
self:GetNormalTexture():SetBlendMode("ADD")
@@ -3424,8 +3424,8 @@ do
if (self.plugin) then
local desc = self.plugin:GetPluginDescription()
if (desc) then
GameCooltip:Preset (2)
GameCooltip:AddLine (desc)
GameCooltip:Preset(2)
GameCooltip:AddLine(desc)
GameCooltip:SetType ("tooltip")
GameCooltip:SetOwner(self, "bottomleft", "topleft", 150, -2)
GameCooltip:Show()
@@ -3433,8 +3433,8 @@ do
end
if (self.hasDesc) then
GameCooltip:Preset (2)
GameCooltip:AddLine (self.hasDesc)
GameCooltip:Preset(2)
GameCooltip:AddLine(self.hasDesc)
GameCooltip:SetType ("tooltip")
GameCooltip:SetOwner(self, "bottomleft", "topleft", 150, -2)
GameCooltip:Show()
@@ -3605,8 +3605,8 @@ do
bframe ["toolbarPluginsLabel3"..i]:SetPoint("topleft", anchorFrame, "topleft", 290, y-4)
bframe ["toolbarPluginsLabel3"..i].color = notInstalledColor
local installButton = DF:CreateButton (bframe, function() Details:CopyPaste (allExistentToolbarPlugins [o] [5]) end, 120, 20, "Install")
installButton:SetTemplate (options_button_template)
local installButton = DF:CreateButton(bframe, function() Details:CopyPaste (allExistentToolbarPlugins [o] [5]) end, 120, 20, "Install")
installButton:SetTemplate(options_button_template)
installButton:SetPoint("topleft", anchorFrame, "topleft", 510, y-0)
i = i + 1
@@ -3743,8 +3743,8 @@ do
bframe ["toolbarPluginsLabel3"..i]:SetPoint("topleft", anchorFrame, "topleft", 290, y-4)
bframe ["toolbarPluginsLabel3"..i].color = notInstalledColor
local installButton = DF:CreateButton (bframe, function() Details:CopyPaste (allExistentRaidPlugins [o] [5]) end, 120, 20, "Install")
installButton:SetTemplate (options_button_template)
local installButton = DF:CreateButton(bframe, function() Details:CopyPaste (allExistentRaidPlugins [o] [5]) end, 120, 20, "Install")
installButton:SetTemplate(options_button_template)
installButton:SetPoint("topleft", anchorFrame, "topleft", 510, y-0)
i = i + 1
@@ -3861,7 +3861,7 @@ do
_detalhes:ApplyProfile (profile_name)
_detalhes:Msg (Loc ["STRING_OPTIONS_PROFILE_LOADED"], profile_name)
_detalhes:Msg(Loc ["STRING_OPTIONS_PROFILE_LOADED"], profile_name)
afterUpdate()
end
local buildProfileMenuForAlwaysUse = function()
@@ -3874,7 +3874,7 @@ do
local selectProfile = function(_, _, profileName)
_detalhes:ApplyProfile(profileName)
_detalhes:Msg (Loc ["STRING_OPTIONS_PROFILE_LOADED"], profileName)
_detalhes:Msg(Loc ["STRING_OPTIONS_PROFILE_LOADED"], profileName)
--Details.options.SetCurrentInstanceAndRefresh(currentInstance)
--afterUpdate()
_G.DetailsOptionsWindow:Hide()
@@ -3941,7 +3941,7 @@ do
local profileName = profileNameString:GetText()
if (profileName == "") then
return _detalhes:Msg (Loc ["STRING_OPTIONS_PROFILE_FIELDEMPTY"])
return _detalhes:Msg(Loc ["STRING_OPTIONS_PROFILE_FIELDEMPTY"])
end
profileNameString:SetText("")
@@ -3953,7 +3953,7 @@ do
afterUpdate()
Details.options.SetCurrentInstanceAndRefresh(currentInstance)
else
return _detalhes:Msg (Loc ["STRING_OPTIONS_PROFILE_NOTCREATED"])
return _detalhes:Msg(Loc ["STRING_OPTIONS_PROFILE_NOTCREATED"])
end
end,
--icontexture = [[Interface\PetBattles\PetBattle-LockIcon]],
@@ -3978,7 +3978,7 @@ do
local profileName = profileDropdown:GetValue()
if (profileName == "") then
return _detalhes:Msg (Loc ["STRING_OPTIONS_PROFILE_FIELDEMPTY"])
return _detalhes:Msg(Loc ["STRING_OPTIONS_PROFILE_FIELDEMPTY"])
end
if (#_detalhes:GetProfileList() == 1) then
@@ -3993,7 +3993,7 @@ do
Details.options.SetCurrentInstanceAndRefresh(currentInstance)
afterUpdate()
_detalhes:Msg (Loc ["STRING_OPTIONS_PROFILE_REMOVEOKEY"])
_detalhes:Msg(Loc ["STRING_OPTIONS_PROFILE_REMOVEOKEY"])
end,
name = Loc ["STRING_OPTIONS_PROFILES_ERASE"],
},
@@ -4017,7 +4017,7 @@ do
type = "execute",
func = function(self)
_detalhes:ShowImportWindow("", function(profileString)
if (type(profileString) ~= "string" or string.len (profileString) < 2) then
if (type(profileString) ~= "string" or string.len(profileString) < 2) then
return
end
@@ -4760,10 +4760,10 @@ do
icon4:SetDrawLayer ("artwork", 1)
icon4:SetTexCoord (0.337890625, 0.5859375, 0.59375+0.0009765625, 0.716796875) --173 304 300 367
icon1:SetVertexColor (.15, .15, .15, 1)
icon2:SetVertexColor (.15, .15, .15, 1)
icon3:SetVertexColor (.15, .15, .15, 1)
icon4:SetVertexColor (.15, .15, .15, 1)
icon1:SetVertexColor(.15, .15, .15, 1)
icon2:SetVertexColor(.15, .15, .15, 1)
icon3:SetVertexColor(.15, .15, .15, 1)
icon4:SetVertexColor(.15, .15, .15, 1)
--corners
local w, h = 20, 20
@@ -4774,7 +4774,7 @@ do
L1:SetTexCoord (0.13671875+0.0009765625, 0.234375, 0.29296875, 0.1953125+0.0009765625)
L1:SetSize(w, h)
L1:SetDrawLayer ("overlay", 2)
L1:SetVertexColor (1, 1, 1, .8)
L1:SetVertexColor(1, 1, 1, .8)
local L2 = sectionFrame:CreateTexture(nil, "overlay")
L2:SetPoint("bottomleft", preview, "bottomleft")
@@ -4782,7 +4782,7 @@ do
L2:SetTexCoord (0.13671875+0.0009765625, 0.234375, 0.1953125+0.0009765625, 0.29296875)
L2:SetSize(w, h)
L2:SetDrawLayer ("overlay", 2)
L2:SetVertexColor (1, 1, 1, .8)
L2:SetVertexColor(1, 1, 1, .8)
local L3 = sectionFrame:CreateTexture(nil, "overlay")
L3:SetPoint("bottomright", preview, "bottomright", 0, 0)
@@ -4790,7 +4790,7 @@ do
L3:SetTexCoord (0.234375, 0.13671875-0.0009765625, 0.1953125+0.0009765625, 0.29296875)
L3:SetSize(w, h)
L3:SetDrawLayer ("overlay", 5)
L3:SetVertexColor (1, 1, 1, .8)
L3:SetVertexColor(1, 1, 1, .8)
local L4 = sectionFrame:CreateTexture(nil, "overlay")
L4:SetPoint("topright", preview, "topright", 0, 0)
@@ -4798,16 +4798,16 @@ do
L4:SetTexCoord (0.234375, 0.13671875-0.0009765625, 0.29296875, 0.1953125+0.0009765625)
L4:SetSize(w, h)
L4:SetDrawLayer ("overlay", 5)
L4:SetVertexColor (1, 1, 1, .8)
L4:SetVertexColor(1, 1, 1, .8)
--update preview
function sectionFrame:UpdateWallpaperInfo()
local wallpaper = currentInstance.wallpaper
preview:SetTexture(wallpaper.texture)
preview:SetTexCoord (unpack (wallpaper.texcoord))
preview:SetVertexColor (unpack (wallpaper.overlay))
preview:SetAlpha (wallpaper.alpha)
preview:SetTexCoord (unpack(wallpaper.texcoord))
preview:SetVertexColor(unpack(wallpaper.overlay))
preview:SetAlpha(wallpaper.alpha)
end
--wallpaper alignment
@@ -4864,8 +4864,8 @@ do
f:SetPoint("center", UIParent, "center")
f:SetFrameStrata("FULLSCREEN")
f:SetSize(550, 170)
f:EnableMouse (true)
f:SetMovable (true)
f:EnableMouse(true)
f:SetMovable(true)
f:SetScript("OnMouseDown", function(self, button)
if (self.isMoving) then
return
@@ -4899,7 +4899,7 @@ do
filename:SetPoint("topleft", f, "topleft", 15, -128)
filename:SetText(Loc ["STRING_OPTIONS_WALLPAPER_LOAD_FILENAME"])
local editbox = DF:NewTextEntry (f, nil, "$parentFileName", "FileName", 160, 20, function() end, nil, nil, nil, nil, options_dropdown_template)
local editbox = DF:NewTextEntry(f, nil, "$parentFileName", "FileName", 160, 20, function() end, nil, nil, nil, nil, options_dropdown_template)
editbox:SetPoint("left", filename, "right", 2, 0)
editbox.tooltip = Loc ["STRING_OPTIONS_WALLPAPER_LOAD_FILENAME_DESC"]
@@ -5058,7 +5058,7 @@ do
for atributo, sub_atributo in ipairs(attributes) do
local icones = sub_atributo.icones
for index, att_name in ipairs(sub_atributo.lista) do
local texture, texcoord = unpack (icones [index])
local texture, texcoord = unpack(icones [index])
tinsert(t, {value = i, label = att_name, onclick = Current_Switch_Func, icon = texture, texcoord = texcoord})
sectionFrame.lastSwitchList [i] = {atributo, index, i}
i = i + 1
@@ -5466,7 +5466,7 @@ do
--[=[]]
local spec1Table = {}
local playerSpecs = DF.ClassSpecIds [select (2, UnitClass("player"))]
local playerSpecs = DF.ClassSpecIds [select(2, UnitClass("player"))]
for specID, _ in pairs(playerSpecs) do
local spec_id, specName, spec_description, spec_icon = GetSpecializationInfoByID(specID)
tinsert(spec1Table, {
@@ -5568,7 +5568,7 @@ do --raid tools
f:SetFrameStrata("FULLSCREEN")
f:EnableMouse()
f:SetMovable (true)
f:SetMovable(true)
f:SetScript("OnMouseDown", function(self, button)
if (button == "RightButton") then
if (f.IsMoving) then
@@ -5615,11 +5615,11 @@ do --raid tools
function f:CreateLabel()
local L = {
icon = DF:CreateImage (f, nil, 16, 16, "overlay", {0.1, 0.9, 0.1, 0.9}),
icon = DF:CreateImage(f, nil, 16, 16, "overlay", {0.1, 0.9, 0.1, 0.9}),
text = DF:CreateLabel(f, "", 10, "white", "GameFontHighlightSmall"),
}
L.switch = DF:CreateSwitch (f, on_switch_func, false)
L.switch = DF:CreateSwitch(f, on_switch_func, false)
L.switch:SetPoint("topleft", f, "topleft", 10, ((#f.labels*20)*-1)-55)
L.icon:SetPoint("left", L.switch, "right", 2, 0)
@@ -5966,7 +5966,7 @@ do
streamerTitleDesc:SetJustifyV ("top")
streamerTitleDesc:SetPoint("topleft", sectionFrame.streamerPluginAnchor, "bottomleft", 0, -4)
local streamerTitleImage = DF:CreateImage (sectionFrame, [[Interface\AddOns\Details\images\icons2.blp]], 268*0.75, 59*0.75, "overlay", {0, 268/512, 454/512, 1})
local streamerTitleImage = DF:CreateImage(sectionFrame, [[Interface\AddOns\Details\images\icons2.blp]], 268*0.75, 59*0.75, "overlay", {0, 268/512, 454/512, 1})
streamerTitleImage:SetPoint("topleft", sectionFrame.streamerPluginAnchor, "bottomleft", 0, -40)
--get the plugin object
@@ -6056,7 +6056,7 @@ do
eventTrackerTitleDesc:SetSize(270, 40)
eventTrackerTitleDesc:SetPoint("topleft", sectionFrame.eventTrackerAnchor, "bottomleft", 0, -4)
local eventTrackerTitleImage = DF:CreateImage (sectionFrame, [[Interface\AddOns\Details\images\icons2]], 256, 50, "overlay", {0.5, 1, 134/512, 184/512})
local eventTrackerTitleImage = DF:CreateImage(sectionFrame, [[Interface\AddOns\Details\images\icons2]], 256, 50, "overlay", {0.5, 1, 134/512, 184/512})
eventTrackerTitleImage:SetPoint("topleft", sectionFrame.eventTrackerAnchor, "bottomleft", 0, -40)
local enableEventTracker = function()
@@ -6098,7 +6098,7 @@ do
currentDPSTitleDesc:SetSize(270, 40)
currentDPSTitleDesc:SetPoint("topleft", sectionFrame.currentDPSAnchor, "bottomleft", 0, -4)
local currentDPSTitleImage = DF:CreateImage (sectionFrame, [[Interface\AddOns\Details\images\icons2]], 256, 32, "overlay", {0/512, 256/512, 421/512, 453/512})
local currentDPSTitleImage = DF:CreateImage(sectionFrame, [[Interface\AddOns\Details\images\icons2]], 256, 32, "overlay", {0/512, 256/512, 421/512, 453/512})
currentDPSTitleImage:SetPoint("topleft", sectionFrame.currentDPSAnchor, "bottomleft", 0, -40)
local enableArenaDPS = function()
@@ -6274,9 +6274,9 @@ do
--add
--add panel
local addframe = DF:NewPanel (sectionFrame, nil, "$parentCustomSpellsAddPanel", "customSpellsAddPanel", 644, 462)
local addframe = DF:NewPanel(sectionFrame, nil, "$parentCustomSpellsAddPanel", "customSpellsAddPanel", 644, 462)
addframe:SetPoint(startX, startY - 40)
addframe:SetFrameLevel (7)
addframe:SetFrameLevel(7)
DF:ApplyStandardBackdrop(addframe)
addframe:Hide()
@@ -6285,7 +6285,7 @@ do
local spellicon = DF:NewLabel(addframe, nil, "$parentSpelliconLabel", "spelliconLabel", Loc ["STRING_OPTIONS_SPELL_ADDICON"])
local spellname_entry_func = function() end
local spellname_entry = DF:NewTextEntry (addframe, nil, "$parentSpellnameEntry", "spellnameEntry", 160, 20, spellname_entry_func, nil, nil, nil, nil, options_dropdown_template)
local spellname_entry = DF:NewTextEntry(addframe, nil, "$parentSpellnameEntry", "spellnameEntry", 160, 20, spellname_entry_func, nil, nil, nil, nil, options_dropdown_template)
spellname_entry:SetPoint("left", spellname, "right", 2, 0)
local spellid_entry_func = function(arg1, arg2, spellid)
@@ -6294,11 +6294,11 @@ do
spellname_entry:SetText(spellname)
addframe.spellIconButton.icon.texture = icon
else
_detalhes:Msg (Loc ["STRING_OPTIONS_SPELL_NOTFOUND"])
_detalhes:Msg(Loc ["STRING_OPTIONS_SPELL_NOTFOUND"])
end
end
local spellid_entry = DF:NewSpellEntry (addframe, spellid_entry_func, 160, 20, nil, nil, "spellidEntry", "$parentSpellidEntry")
spellid_entry:SetTemplate (options_dropdown_template)
spellid_entry:SetTemplate(options_dropdown_template)
spellid_entry:SetPoint("left", spellid, "right", 2, 0)
local icon_button_func = function(texture)
@@ -6317,17 +6317,17 @@ do
local addspell = function()
local id = spellid_entry.text
if (id == "") then
return _detalhes:Msg (Loc ["STRING_OPTIONS_SPELL_IDERROR"])
return _detalhes:Msg(Loc ["STRING_OPTIONS_SPELL_IDERROR"])
end
local name = spellname_entry.text
if (name == "") then
return _detalhes:Msg (Loc ["STRING_OPTIONS_SPELL_NAMEERROR"])
return _detalhes:Msg(Loc ["STRING_OPTIONS_SPELL_NAMEERROR"])
end
local icon = addframe.spellIconButton.icon.texture
id = tonumber (id)
if (not id) then
return _detalhes:Msg (Loc ["STRING_OPTIONS_SPELL_IDERROR"])
return _detalhes:Msg(Loc ["STRING_OPTIONS_SPELL_IDERROR"])
end
_detalhes:UserCustomSpellAdd (id, name, icon)
@@ -6420,7 +6420,7 @@ do
local big_code_editor = DF:NewSpecialLuaEditorEntry (sectionFrame, 683, 422, "bigCodeEditor", "$parentBigCodeEditor")
big_code_editor:SetPoint("topleft", sectionFrame, "topleft", startX, startY - 70)
big_code_editor:SetFrameLevel (sectionFrame:GetFrameLevel()+6)
big_code_editor:SetFrameLevel(sectionFrame:GetFrameLevel()+6)
big_code_editor:SetBackdrop({bgFile = [[Interface\AddOns\Details\images\background]], edgeFile = [[Interface\Buttons\WHITE8X8]], edgeSize = 1,tile = 1, tileSize = 16})
DF:ReskinSlider(big_code_editor.scroll)
big_code_editor:SetBackdropColor(0.5, 0.5, 0.5, 0.95)
@@ -6457,7 +6457,7 @@ do
local func = data [2]
if (type(func) == "function") then
return _detalhes:Msg (Loc ["STRING_OPTIONS_CHART_CODELOADED"])
return _detalhes:Msg(Loc ["STRING_OPTIONS_CHART_CODELOADED"])
end
big_code_editor:SetText(func)
@@ -6490,7 +6490,7 @@ do
local big_code_editor2 = DF:NewSpecialLuaEditorEntry (sectionFrame, 643, 402, "exportEditor", "$parentExportEditor", true)
big_code_editor2:SetPoint("topleft", sectionFrame, "topleft", 7, -70)
big_code_editor2:SetFrameLevel (sectionFrame:GetFrameLevel()+6)
big_code_editor2:SetFrameLevel(sectionFrame:GetFrameLevel()+6)
big_code_editor2:SetBackdrop({bgFile = [[Interface\AddOns\Details\images\background]], edgeFile = [[Interface\Buttons\WHITE8X8]], edgeSize = 1,tile = 1, tileSize = 16})
DF:ReskinSlider(big_code_editor2.scroll)
big_code_editor2:SetBackdropColor(0.5, 0.5, 0.5, 0.95)
@@ -6506,7 +6506,7 @@ do
close_export:SetPoint(10, 18)
close_export:SetIcon ([[Interface\Buttons\UI-CheckBox-Check]])
close_export:SetText(Loc ["STRING_OPTIONS_CHART_CLOSE"])
close_export:SetTemplate (options_button_template)
close_export:SetTemplate(options_button_template)
local export_function = function(index)
local data = _detalhes.savedTimeCaptures [index]
@@ -6589,9 +6589,9 @@ do
panel:Refresh()
--add panel
local addframe = DF:NewPanel (sectionFrame, nil, "$parentUserTimeCapturesAddPanel", "userTimeCaptureAddPanel", 683, 422)
local addframe = DF:NewPanel(sectionFrame, nil, "$parentUserTimeCapturesAddPanel", "userTimeCaptureAddPanel", 683, 422)
addframe:SetPoint("topleft", sectionFrame, "topleft", startX, startY - 70)
addframe:SetFrameLevel (7)
addframe:SetFrameLevel(7)
addframe:Hide()
addframe:SetBackdrop({bgFile = [[Interface\AddOns\Details\images\background]], edgeFile = [[Interface\Buttons\WHITE8X8]], edgeSize = 1,tile = 1, tileSize = 16})
@@ -6600,7 +6600,7 @@ do
--name
local capture_name = DF:NewLabel(addframe, nil, "$parentNameLabel", "nameLabel", Loc ["STRING_OPTIONS_CHART_ADDNAME"])
local capture_name_entry = DF:NewTextEntry (addframe, nil, "$parentNameEntry", "nameEntry", 160, 20, function() end, nil, nil, nil, nil, options_dropdown_template)
local capture_name_entry = DF:NewTextEntry(addframe, nil, "$parentNameEntry", "nameEntry", 160, 20, function() end, nil, nil, nil, nil, options_dropdown_template)
capture_name_entry:SetMaxLetters (16)
capture_name_entry:SetPoint("left", capture_name, "right", 2, 0)
@@ -6627,12 +6627,12 @@ do
--author
local capture_author = DF:NewLabel(addframe, nil, "$parentAuthorLabel", "authorLabel", Loc ["STRING_OPTIONS_CHART_ADDAUTHOR"])
local capture_author_entry = DF:NewTextEntry (addframe, nil, "$parentAuthorEntry", "authorEntry", 160, 20, function() end, nil, nil, nil, nil, options_dropdown_template)
local capture_author_entry = DF:NewTextEntry(addframe, nil, "$parentAuthorEntry", "authorEntry", 160, 20, function() end, nil, nil, nil, nil, options_dropdown_template)
capture_author_entry:SetPoint("left", capture_author, "right", 2, 0)
--version
local capture_version = DF:NewLabel(addframe, nil, "$parentVersionLabel", "versionLabel", Loc ["STRING_OPTIONS_CHART_ADDVERSION"])
local capture_version_entry = DF:NewTextEntry (addframe, nil, "$parentVersionEntry", "versionEntry", 160, 20, function() end, nil, nil, nil, nil, options_dropdown_template)
local capture_version_entry = DF:NewTextEntry(addframe, nil, "$parentVersionEntry", "versionEntry", 160, 20, function() end, nil, nil, nil, nil, options_dropdown_template)
capture_version_entry:SetPoint("left", capture_version, "right", 2, 0)
--open add panel button
@@ -6659,7 +6659,7 @@ do
local font, size, flag = importframe.editbox:GetFont()
importframe.editbox:SetFont (font, 9, flag)
importframe:SetPoint("topleft", sectionFrame, "topleft", startX, startY - 70)
importframe:SetFrameLevel (sectionFrame:GetFrameLevel()+6)
importframe:SetFrameLevel(sectionFrame:GetFrameLevel()+6)
importframe:SetBackdrop({bgFile = [[Interface\AddOns\Details\images\background]], edgeFile = [[Interface\Buttons\WHITE8X8]], edgeSize = 1,tile = 1, tileSize = 16})
DF:ReskinSlider(importframe.scroll)
importframe:SetBackdropColor(0.5, 0.5, 0.5, 0.95)
@@ -6677,21 +6677,21 @@ do
if (type(unserialize) == "table") then
if (unserialize[1] and unserialize[2] and unserialize[3] and unserialize[4] and unserialize[5]) then
local register = _detalhes:TimeDataRegister (unpack (unserialize))
local register = _detalhes:TimeDataRegister (unpack(unserialize))
if (type(register) == "string") then
_detalhes:Msg (register)
_detalhes:Msg(register)
end
else
_detalhes:Msg (Loc ["STRING_OPTIONS_CHART_IMPORTERROR"])
_detalhes:Msg(Loc ["STRING_OPTIONS_CHART_IMPORTERROR"])
end
else
_detalhes:Msg (Loc ["STRING_OPTIONS_CHART_IMPORTERROR"])
_detalhes:Msg(Loc ["STRING_OPTIONS_CHART_IMPORTERROR"])
end
importframe:Hide()
panel:Refresh()
else
_detalhes:Msg (Loc ["STRING_CUSTOM_IMPORT_ERROR"])
_detalhes:Msg(Loc ["STRING_CUSTOM_IMPORT_ERROR"])
return
end
end
@@ -6700,7 +6700,7 @@ do
accept_import:SetIcon ([[Interface\Buttons\UI-CheckBox-Check]])
accept_import:SetPoint(10, 18)
accept_import:SetText(Loc ["STRING_OPTIONS_CHART_IMPORT"])
accept_import:SetTemplate (options_button_template)
accept_import:SetTemplate(options_button_template)
local cancelimport = function()
importframe:ClearFocus()
@@ -6711,7 +6711,7 @@ do
cancel_changes:SetIcon ([[Interface\PetBattles\DeadPetIcon]])
cancel_changes:SetText(Loc ["STRING_OPTIONS_CHART_CANCEL"])
cancel_changes:SetPoint(132, 18)
cancel_changes:SetTemplate (options_button_template)
cancel_changes:SetTemplate(options_button_template)
local import = function()
importframe:Show()
@@ -6739,24 +6739,24 @@ do
local addcapture = function()
local name = capture_name_entry.text
if (name == "") then
return _detalhes:Msg (Loc ["STRING_OPTIONS_CHART_NAMEERROR"])
return _detalhes:Msg(Loc ["STRING_OPTIONS_CHART_NAMEERROR"])
end
local author = capture_author_entry.text
if (author == "") then
return _detalhes:Msg (Loc ["STRING_OPTIONS_CHART_AUTHORERROR"])
return _detalhes:Msg(Loc ["STRING_OPTIONS_CHART_AUTHORERROR"])
end
local icon = addframe.iconButton.iconTexture
local version = capture_version_entry.text
if (version == "") then
return _detalhes:Msg (Loc ["STRING_OPTIONS_CHART_VERSIONERROR"])
return _detalhes:Msg(Loc ["STRING_OPTIONS_CHART_VERSIONERROR"])
end
local func = capture_func_entry:GetText()
if (func == "") then
return _detalhes:Msg (Loc ["STRING_OPTIONS_CHART_FUNCERROR"])
return _detalhes:Msg(Loc ["STRING_OPTIONS_CHART_FUNCERROR"])
end
_detalhes:TimeDataRegister (name, func, nil, author, version, icon, true)
@@ -6789,8 +6789,8 @@ do
addcapturebutton:SetIcon ([[Interface\Buttons\UI-CheckBox-Check]], 18, 18, nil, nil, nil, 4)
closebutton:SetIcon ([[Interface\PetBattles\DeadPetIcon]], 14, 14, nil, nil, nil, 4)
addcapturebutton:SetTemplate (options_button_template)
closebutton:SetTemplate (options_button_template)
addcapturebutton:SetTemplate(options_button_template)
closebutton:SetTemplate(options_button_template)
addcapturebutton:SetPoint("bottomright", addframe, "bottomright", -5, 5)
closebutton:SetPoint("right", addcapturebutton, "left", -4, 0)
+19 -19
View File
@@ -4,7 +4,7 @@ local Details = _G.Details
local DF = _G.DetailsFramework
function Details:InitializePlaterIntegrationWindow()
local DetailsPlaterIntegrationPanel = DF:CreateSimplePanel (UIParent, 700, 480, "Details! Plater Nameplates Integration", "DetailsPlaterIntegrationPanel")
local DetailsPlaterIntegrationPanel = DF:CreateSimplePanel(UIParent, 700, 480, "Details! Plater Nameplates Integration", "DetailsPlaterIntegrationPanel")
DetailsPlaterIntegrationPanel.Frame = DetailsPlaterIntegrationPanel
DetailsPlaterIntegrationPanel.__name = "Plater Nameplates"
DetailsPlaterIntegrationPanel.real_name = "DETAILS_PLATERWINDOW"
@@ -25,15 +25,15 @@ function Details.OpenPlaterIntegrationWindow()
DetailsPlaterIntegrationPanel.Initialized = true
local f = DetailsPlaterIntegrationPanel or DF:CreateSimplePanel (UIParent, 700, 480, "Details! Plater Nameplates Integration", "DetailsPlaterIntegrationPanel")
local f = DetailsPlaterIntegrationPanel or DF:CreateSimplePanel(UIParent, 700, 480, "Details! Plater Nameplates Integration", "DetailsPlaterIntegrationPanel")
--background
f.bg1 = f:CreateTexture(nil, "background")
f.bg1:SetTexture([[Interface\AddOns\Details\images\background]], true)
f.bg1:SetAlpha (0.8)
f.bg1:SetVertexColor (0.27, 0.27, 0.27)
f.bg1:SetVertTile (true)
f.bg1:SetHorizTile (true)
f.bg1:SetAlpha(0.8)
f.bg1:SetVertexColor(0.27, 0.27, 0.27)
f.bg1:SetVertTile(true)
f.bg1:SetHorizTile(true)
f.bg1:SetSize(790, 454)
f.bg1:SetAllPoints()
f:SetBackdrop({edgeFile = [[Interface\Buttons\WHITE8X8]], edgeSize = 1, bgFile = [[Interface\AddOns\Details\images\background]], tileSize = 64, tile = true})
@@ -61,7 +61,7 @@ function Details.OpenPlaterIntegrationWindow()
local menu_table = {
{type = "label", get = function() return "Add Real Time DPS Info in the Nameplate:" end, text_template = DF:GetTemplate ("font", "ORANGE_FONT_TEMPLATE")},
{type = "label", get = function() return "Add Real Time DPS Info in the Nameplate:" end, text_template = DF:GetTemplate("font", "ORANGE_FONT_TEMPLATE")},
--real time dps from all sources
{
@@ -173,7 +173,7 @@ function Details.OpenPlaterIntegrationWindow()
},
{type = "breakline"},
{type = "label", get = function() return "Add Real Time DPS Info Only From You in the Nameplate:" end, text_template = DF:GetTemplate ("font", "ORANGE_FONT_TEMPLATE")},
{type = "label", get = function() return "Add Real Time DPS Info Only From You in the Nameplate:" end, text_template = DF:GetTemplate("font", "ORANGE_FONT_TEMPLATE")},
--real time dps from the player only
{
@@ -285,7 +285,7 @@ function Details.OpenPlaterIntegrationWindow()
},
{type = "breakline"},
{type = "label", get = function() return "Add Total Damage Taken in the Nameplate:" end, text_template = DF:GetTemplate ("font", "ORANGE_FONT_TEMPLATE")},
{type = "label", get = function() return "Add Total Damage Taken in the Nameplate:" end, text_template = DF:GetTemplate("font", "ORANGE_FONT_TEMPLATE")},
--total damage taken from all sources
{
@@ -397,11 +397,11 @@ function Details.OpenPlaterIntegrationWindow()
},
}
local options_text_template = DF:GetTemplate ("font", "OPTIONS_FONT_TEMPLATE")
local options_dropdown_template = DF:GetTemplate ("dropdown", "OPTIONS_DROPDOWN_TEMPLATE")
local options_switch_template = DF:GetTemplate ("switch", "OPTIONS_CHECKBOX_TEMPLATE")
local options_slider_template = DF:GetTemplate ("slider", "OPTIONS_SLIDER_TEMPLATE")
local options_button_template = DF:GetTemplate ("button", "OPTIONS_BUTTON_TEMPLATE")
local options_text_template = DF:GetTemplate("font", "OPTIONS_FONT_TEMPLATE")
local options_dropdown_template = DF:GetTemplate("dropdown", "OPTIONS_DROPDOWN_TEMPLATE")
local options_switch_template = DF:GetTemplate("switch", "OPTIONS_CHECKBOX_TEMPLATE")
local options_slider_template = DF:GetTemplate("slider", "OPTIONS_SLIDER_TEMPLATE")
local options_button_template = DF:GetTemplate("button", "OPTIONS_BUTTON_TEMPLATE")
local titleBackground = CreateFrame("frame", nil, f,"BackdropTemplate")
titleBackground:SetPoint("topleft", f, "topleft", 10, -30)
@@ -411,10 +411,10 @@ function Details.OpenPlaterIntegrationWindow()
--background
titleBackground.bg1 = titleBackground:CreateTexture(nil, "background")
titleBackground.bg1:SetTexture([[Interface\AddOns\Details\images\background]])
titleBackground.bg1:SetAlpha (0.8)
titleBackground.bg1:SetVertexColor (0.27, 0.27, 0.27)
titleBackground.bg1:SetVertTile (true)
titleBackground.bg1:SetHorizTile (true)
titleBackground.bg1:SetAlpha(0.8)
titleBackground.bg1:SetVertexColor(0.27, 0.27, 0.27)
titleBackground.bg1:SetVertTile(true)
titleBackground.bg1:SetHorizTile(true)
titleBackground.bg1:SetSize(790, 454)
titleBackground.bg1:SetAllPoints()
titleBackground:SetBackdrop({edgeFile = [[Interface\Buttons\WHITE8X8]], edgeSize = 1, bgFile = [[Interface\AddOns\Details\images\background]], tileSize = 64, tile = true})
@@ -424,7 +424,7 @@ function Details.OpenPlaterIntegrationWindow()
local platerTitle = DF:CreateLabel(titleBackground, "Plater Nameplates Integration", 16, "white")
local platerDesc1 = DF:CreateLabel(titleBackground, "Add DPS and Damage information directly into the nameplate", 11, "silver")
local platerDesc2 = DF:CreateLabel(titleBackground, "See how much damage the enemy is taking in real time!", 11, "silver")
local platerImage = DF:CreateImage (titleBackground, "Interface\\AddOns\\Details\\images\\plater_image")
local platerImage = DF:CreateImage(titleBackground, "Interface\\AddOns\\Details\\images\\plater_image")
platerImage:SetSize(256, 64)
platerImage:SetPoint("topright", f, "topright", -150, -35)
File diff suppressed because it is too large Load Diff
+1 -1
View File
@@ -153,7 +153,7 @@
line:SetScript("OnClick", lineOnClick)
line:SetBackdrop({bgFile = [[Interface\Tooltips\UI-Tooltip-Background]], tileSize = 64, tile = true, edgeFile = [[Interface\Buttons\WHITE8X8]], edgeSize = 1})
line:SetBackdropColor(unpack (scrollbox_line_backdrop_color))
line:SetBackdropColor(unpack(scrollbox_line_backdrop_color))
line:SetBackdropBorderColor(0, 0, 0, 1)
local specIcon = line:CreateTexture("$parentSpecIcon", "artwork")
+1 -1
View File
@@ -1,6 +1,6 @@
local Details = _G.Details
local L = _G.LibStub ("AceLocale-3.0"):GetLocale( "Details" )
local L = _G.LibStub("AceLocale-3.0"):GetLocale( "Details" )
function Details:OpenProfiler()
+4 -4
View File
@@ -598,7 +598,7 @@ local createDropdown = function(thisFrame)
window.fechar:SetHeight(20)
window.fechar:SetPoint("TOPRIGHT", window, "TOPRIGHT", 0, -3)
window.fechar:Show()
window.fechar:GetNormalTexture():SetDesaturated (true)
window.fechar:GetNormalTexture():SetDesaturated(true)
local recentReportButton = window.recently_report_buttons[10]
recentReportButton:Hide()
@@ -682,8 +682,8 @@ local createDropdown = function(thisFrame)
bg1:SetTexture([[Interface\AddOns\Details\images\background]], true)
bg1:SetAlpha(0.7)
bg1:SetVertexColor(0.27, 0.27, 0.27)
bg1:SetVertTile (true)
bg1:SetHorizTile (true)
bg1:SetVertTile(true)
bg1:SetHorizTile(true)
bg1:SetAllPoints()
tinsert(window.all_widgets, bg1)
@@ -713,7 +713,7 @@ local createDropdown = function(thisFrame)
function Details:DelayUpdateReportWindowRecentlyReported()
if (DetailsReportWindow) then
Details:ScheduleTimer ("UpdateRecentlyReported", 0.5)
Details:ScheduleTimer("UpdateRecentlyReported", 0.5)
end
end
+12 -12
View File
@@ -13,7 +13,7 @@ local panel = Details:CreateWelcomePanel ("DetailsWindowOptionsBarTextEditor", n
panel:SetPoint("center", UIParent, "center")
panel:Hide()
panel:SetFrameStrata("FULLSCREEN")
DF:ApplyStandardBackdrop (panel)
DF:ApplyStandardBackdrop(panel)
DF:CreateTitleBar (panel, "Details! Custom Line Text Editor")
function panel:Open (text, callback, host, default)
@@ -31,11 +31,11 @@ function panel:Open (text, callback, host, default)
end
local y = -32
local buttonTemplate = DF:GetTemplate ("button", "OPTIONS_BUTTON_TEMPLATE")
local buttonTemplate = DF:GetTemplate("button", "OPTIONS_BUTTON_TEMPLATE")
local textentry = DF:NewSpecialLuaEditorEntry (panel, scrollWidth, 555, "editbox", "$parentEntry")
textentry:SetPoint("topleft", panel, "topleft", 10, y)
DF:ApplyStandardBackdrop (textentry)
DF:ApplyStandardBackdrop(textentry)
DF:SetFontSize (textentry.editbox, 14)
DF:ReskinSlider(textentry.scroll)
@@ -45,9 +45,9 @@ local arg3_button = DF:NewButton(panel, nil, "$parentButton3", nil, 80, 20, func
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))
arg1_button:SetTemplate (buttonTemplate)
arg2_button:SetTemplate (buttonTemplate)
arg3_button:SetTemplate (buttonTemplate)
arg1_button:SetTemplate(buttonTemplate)
arg2_button:SetTemplate(buttonTemplate)
arg3_button:SetTemplate(buttonTemplate)
arg1_button.tooltip = Loc ["STRING_OPTIONS_TEXTEDITOR_DATA_TOOLTIP"]
arg2_button.tooltip = Loc ["STRING_OPTIONS_TEXTEDITOR_DATA_TOOLTIP"]
@@ -165,10 +165,10 @@ 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 color_button = DF:NewColorPickButton (panel, "$parentButton5", nil, color_func)
color_button:SetSize(80, 20)
color_button:SetTemplate (buttonTemplate)
color_button:SetTemplate(buttonTemplate)
func_button:SetPoint("topright", panel, "topright", -12, y - (20*3))
func_button:SetTemplate (buttonTemplate)
func_button:SetTemplate(buttonTemplate)
color_button.tooltip = Loc ["STRING_OPTIONS_TEXTEDITOR_COLOR_TOOLTIP"]
func_button.tooltip = Loc ["STRING_OPTIONS_TEXTEDITOR_FUNC_TOOLTIP"]
@@ -179,20 +179,20 @@ local done = function()
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
apply_button:SetTemplate (buttonTemplate)
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)
ok_button.tooltip = Loc ["STRING_OPTIONS_TEXTEDITOR_DONE_TOOLTIP"]
ok_button:SetTemplate (buttonTemplate)
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)
reset_button.tooltip = Loc ["STRING_OPTIONS_TEXTEDITOR_RESET_TOOLTIP"]
reset_button:SetTemplate (buttonTemplate)
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)
cancel_button.tooltip = Loc ["STRING_OPTIONS_TEXTEDITOR_CANCEL_TOOLTIP"]
cancel_button:SetTemplate (buttonTemplate)
cancel_button:SetTemplate(buttonTemplate)
cancel_button:SetPoint("topright", panel, "topright", -14, -172)
+13 -13
View File
@@ -6,7 +6,7 @@ local _
-- ~run ~runcode
function Details:InitializeRunCodeWindow()
local DetailsRunCodePanel = DF:CreateSimplePanel (UIParent, 700, 480, "Details! Run Code", "DetailsRunCodePanel")
local DetailsRunCodePanel = DF:CreateSimplePanel(UIParent, 700, 480, "Details! Run Code", "DetailsRunCodePanel")
DetailsRunCodePanel.Frame = DetailsRunCodePanel
DetailsRunCodePanel.__name = "Auto Run Code"
DetailsRunCodePanel.real_name = "DETAILS_RUNCODEWINDOW"
@@ -30,7 +30,7 @@ function Details.OpenRunCodeWindow()
DetailsRunCodePanel.Initialized = true
local f = DetailsRunCodePanel or DF:CreateSimplePanel (UIParent, 700, 480, "Details! Run Code", "DetailsRunCodePanel")
local f = DetailsRunCodePanel or DF:CreateSimplePanel(UIParent, 700, 480, "Details! Run Code", "DetailsRunCodePanel")
--lua editor
local code_editor = DF:NewSpecialLuaEditorEntry (f, 885, 510, "text", "$parentCodeEditorWindow")
@@ -52,10 +52,10 @@ function Details.OpenRunCodeWindow()
code_editor:SetBackdropBorderColor(0, 0, 0, 1)
code_editor.__background:SetColorTexture (0.2317647, 0.2317647, 0.2317647)
code_editor.__background:SetVertexColor (0.27, 0.27, 0.27)
code_editor.__background:SetAlpha (0.8)
code_editor.__background:SetVertTile (true)
code_editor.__background:SetHorizTile (true)
code_editor.__background:SetVertexColor(0.27, 0.27, 0.27)
code_editor.__background:SetAlpha(0.8)
code_editor.__background:SetVertTile(true)
code_editor.__background:SetHorizTile(true)
code_editor.__background:SetAllPoints()
--code compile error warning
@@ -69,7 +69,7 @@ function Details.OpenRunCodeWindow()
DF:CreateFlashAnimation (errortext_frame)
local errortext_label = DF:CreateLabel(errortext_frame, "", DF:GetTemplate ("font", "ORANGE_FONT_TEMPLATE"))
local errortext_label = DF:CreateLabel(errortext_frame, "", DF:GetTemplate("font", "ORANGE_FONT_TEMPLATE"))
errortext_label.textcolor = "red"
errortext_label:SetPoint("left", errortext_frame, "left", 3, 0)
code_editor.NextCodeCheck = 0.33
@@ -118,10 +118,10 @@ function Details.OpenRunCodeWindow()
return t
end
local code_type_label = DF:CreateLabel(f, "Event:", DF:GetTemplate ("font", "ORANGE_FONT_TEMPLATE"))
local code_type_dropdown = DF:CreateDropDown (f, build_CodeType_dropdown_options, 1, 160, 20, "CodeTypeDropdown", _, DF:GetTemplate ("dropdown", "OPTIONS_DROPDOWN_TEMPLATE"))
local code_type_label = DF:CreateLabel(f, "Event:", DF:GetTemplate("font", "ORANGE_FONT_TEMPLATE"))
local code_type_dropdown = DF:CreateDropDown (f, build_CodeType_dropdown_options, 1, 160, 20, "CodeTypeDropdown", _, DF:GetTemplate("dropdown", "OPTIONS_DROPDOWN_TEMPLATE"))
code_type_dropdown:SetPoint("left", code_type_label, "right", 2, 0)
code_type_dropdown:SetFrameLevel (code_editor:GetFrameLevel() + 10)
code_type_dropdown:SetFrameLevel(code_editor:GetFrameLevel() + 10)
code_type_label:SetPoint("bottomleft", code_editor, "topleft", 0, 8)
--create save button
@@ -142,7 +142,7 @@ function Details.OpenRunCodeWindow()
local button_y = -6
local save_script_button = DF:CreateButton (f, save_script, 120, 20, "Save", -1, nil, nil, nil, nil, nil, DF:GetTemplate ("button", "OPTIONS_BUTTON_TEMPLATE"), DF:GetTemplate ("font", "PLATER_BUTTON"))
local save_script_button = DF:CreateButton(f, save_script, 120, 20, "Save", -1, nil, nil, nil, nil, nil, DF:GetTemplate("button", "OPTIONS_BUTTON_TEMPLATE"), DF:GetTemplate("font", "PLATER_BUTTON"))
save_script_button:SetIcon ([[Interface\BUTTONS\UI-Panel-ExpandButton-Up]], 20, 20, "overlay", {0.1, .9, 0.1, .9})
save_script_button:SetPoint("topright", code_editor, "bottomright", 0, button_y)
@@ -153,7 +153,7 @@ function Details.OpenRunCodeWindow()
code_editor:ClearFocus()
end
local cancel_script_button = DF:CreateButton (f, cancel_script, 120, 20, "Cancel", -1, nil, nil, nil, nil, nil, DF:GetTemplate ("button", "OPTIONS_BUTTON_TEMPLATE"), DF:GetTemplate ("font", "PLATER_BUTTON"))
local cancel_script_button = DF:CreateButton(f, cancel_script, 120, 20, "Cancel", -1, nil, nil, nil, nil, nil, DF:GetTemplate("button", "OPTIONS_BUTTON_TEMPLATE"), DF:GetTemplate("font", "PLATER_BUTTON"))
cancel_script_button:SetIcon ([[Interface\BUTTONS\UI-Panel-MinimizeButton-Up]], 20, 20, "overlay", {0.1, .9, 0.1, .9})
cancel_script_button:SetPoint("topleft", code_editor, "bottomleft", 0, button_y)
@@ -171,7 +171,7 @@ function Details.OpenRunCodeWindow()
end
end
local run_script_button = DF:CreateButton (f, execute_script, 120, 20, "Test Code", -1, nil, nil, nil, nil, nil, DF:GetTemplate ("button", "OPTIONS_BUTTON_TEMPLATE"), DF:GetTemplate ("font", "PLATER_BUTTON"))
local run_script_button = DF:CreateButton(f, execute_script, 120, 20, "Test Code", -1, nil, nil, nil, nil, nil, DF:GetTemplate("button", "OPTIONS_BUTTON_TEMPLATE"), DF:GetTemplate("font", "PLATER_BUTTON"))
run_script_button:SetIcon ([[Interface\BUTTONS\UI-SpellbookIcon-NextPage-Up]], 20, 20, "overlay", {0.05, 0.95, 0.05, 0.95})
run_script_button:SetPoint("bottomright", code_editor, "topright", 0, 3)
+2 -2
View File
@@ -69,7 +69,7 @@ function Details:ScrollDamage()
if (spellTable) then
local line = self:GetLine(i)
local time, token, hidding, sourceSerial, sourceName, sourceFlag, sourceFlag2, targetSerial, targetName, targetFlag, targetFlag2, spellID, spellName, spellType, amount, overKill, school, resisted, blocked, absorbed, isCritical = unpack (spellTable)
local time, token, hidding, sourceSerial, sourceName, sourceFlag, sourceFlag2, targetSerial, targetName, targetFlag, targetFlag2, spellID, spellName, spellType, amount, overKill, school, resisted, blocked, absorbed, isCritical = unpack(spellTable)
local spellName, _, spellIcon
@@ -136,7 +136,7 @@ function Details:ScrollDamage()
line:SetSize(scroll_width - 2, scroll_line_height)
line:SetBackdrop({bgFile = [[Interface\Tooltips\UI-Tooltip-Background]], tileSize = 64, tile = true})
line:SetBackdropColor(unpack (backdrop_color))
line:SetBackdropColor(unpack(backdrop_color))
DF:Mixin(line, DF.HeaderFunctions)
+2 -2
View File
@@ -154,7 +154,7 @@ function Details.Survey.OpenSpellCategoryScreen()
statusBar:SetPoint("bottomleft", detailsSpellCategoryFrame, "bottomleft")
statusBar:SetPoint("bottomright", detailsSpellCategoryFrame, "bottomright")
statusBar:SetHeight(26)
statusBar:SetAlpha (0.8)
statusBar:SetAlpha(0.8)
DF:ApplyStandardBackdrop(statusBar)
--statusbar of the statusbar
@@ -162,7 +162,7 @@ function Details.Survey.OpenSpellCategoryScreen()
statusBar2:SetPoint("topleft", statusBar, "bottomleft")
statusBar2:SetPoint("topright", statusBar, "bottomright")
statusBar2:SetHeight(20)
statusBar2:SetAlpha (0.8)
statusBar2:SetAlpha(0.8)
DF:ApplyStandardBackdrop(statusBar2)
DF:ApplyStandardBackdrop(statusBar2)
local dataInfoLabel = DF:CreateLabel(statusBar2, "This cooldown data is send to people on Details! team and shared in 'Open Raid' library where any weakaura or addon can use it", 12, "silver")
+41 -41
View File
@@ -38,7 +38,7 @@ function Details:OpenRaidHistoryWindow (_raid, _boss, _difficulty, _role, _guild
f:SetFrameStrata("HIGH")
f:SetToplevel (true)
f:SetMovable (true)
f:SetMovable(true)
f:SetWidth(850)
f:SetHeight(500)
tinsert(UISpecialFrames, "DetailsRaidHistoryWindow")
@@ -67,10 +67,10 @@ function Details:OpenRaidHistoryWindow (_raid, _boss, _difficulty, _role, _guild
f.bg1 = f:CreateTexture(nil, "background")
f.bg1:SetTexture([[Interface\AddOns\Details\images\background]], true)
f.bg1:SetAlpha (0.7)
f.bg1:SetVertexColor (0.27, 0.27, 0.27)
f.bg1:SetVertTile (true)
f.bg1:SetHorizTile (true)
f.bg1:SetAlpha(0.7)
f.bg1:SetVertexColor(0.27, 0.27, 0.27)
f.bg1:SetVertTile(true)
f.bg1:SetHorizTile(true)
f.bg1:SetSize(790, 454)
f.bg1:SetAllPoints()
@@ -96,28 +96,28 @@ function Details:OpenRaidHistoryWindow (_raid, _boss, _difficulty, _role, _guild
tutorialFrame.Desc.width = 370
tutorialFrame.Desc:SetPoint("topleft", tutorialFrame, "topleft", 10, -45)
local closeButton = DF:CreateButton (tutorialFrame, function() Details:SetTutorialCVar ("HISTORYPANEL_TUTORIAL", true); tutorialFrame:Hide() end, 80, 20, Loc ["STRING_OPTIONS_CHART_CLOSE"])
local closeButton = DF:CreateButton(tutorialFrame, function() Details:SetTutorialCVar ("HISTORYPANEL_TUTORIAL", true); tutorialFrame:Hide() end, 80, 20, Loc ["STRING_OPTIONS_CHART_CLOSE"])
closeButton:SetPoint("bottom", tutorialFrame, "bottom", 0, 10)
closeButton:SetTemplate (DF:GetTemplate ("button", "OPTIONS_BUTTON_TEMPLATE"))
closeButton:SetTemplate(DF:GetTemplate("button", "OPTIONS_BUTTON_TEMPLATE"))
end
--background
local background = f:CreateTexture("$parentBackgroundImage", "border")
background:SetAlpha (0.3)
background:SetAlpha(0.3)
background:SetPoint("topleft", f, "topleft", 6, -65)
background:SetPoint("bottomright", f, "bottomright", -10, 28)
--separate menu and main list
local div = f:CreateTexture(nil, "artwork")
div:SetTexture([[Interface\ACHIEVEMENTFRAME\UI-Achievement-MetalBorder-Left]])
div:SetAlpha (0.1)
div:SetAlpha(0.1)
div:SetPoint("topleft", f, "topleft", 180, -64)
div:SetHeight(574)
--select history or guild rank
local options_switch_template = DF:GetTemplate ("switch", "OPTIONS_CHECKBOX_TEMPLATE")
local options_text_template = DF:GetTemplate ("font", "OPTIONS_FONT_TEMPLATE")
local options_button_template = DF:GetTemplate ("button", "OPTIONS_BUTTON_TEMPLATE")
local options_switch_template = DF:GetTemplate("switch", "OPTIONS_CHECKBOX_TEMPLATE")
local options_text_template = DF:GetTemplate("font", "OPTIONS_FONT_TEMPLATE")
local options_button_template = DF:GetTemplate("button", "OPTIONS_BUTTON_TEMPLATE")
local selectKillTimeline = function()
f.GuildRankCheckBox:SetValue(false)
@@ -139,7 +139,7 @@ function Details:OpenRaidHistoryWindow (_raid, _boss, _difficulty, _role, _guild
end
--kill timeline
local HistoryCheckBox, HistoryLabel = DF:CreateSwitch (f, selectKillTimeline, false, 18, 18, "", "", "HistoryCheckBox", nil, nil, nil, nil, Loc ["STRING_GUILDDAMAGERANK_SHOWHISTORY"], options_switch_template) --, options_text_template
local HistoryCheckBox, HistoryLabel = DF:CreateSwitch(f, selectKillTimeline, false, 18, 18, "", "", "HistoryCheckBox", nil, nil, nil, nil, Loc ["STRING_GUILDDAMAGERANK_SHOWHISTORY"], options_switch_template) --, options_text_template
HistoryLabel:ClearAllPoints()
HistoryCheckBox:ClearAllPoints()
HistoryCheckBox:SetPoint("topleft", f, "topleft", 100, -34)
@@ -147,7 +147,7 @@ function Details:OpenRaidHistoryWindow (_raid, _boss, _difficulty, _role, _guild
HistoryCheckBox:SetAsCheckBox()
--guildrank
local GuildRankCheckBox, GuildRankLabel = DF:CreateSwitch (f, selectGuildRank, true, 18, 18, "", "", "GuildRankCheckBox", nil, nil, nil, nil, Loc ["STRING_GUILDDAMAGERANK_SHOWRANK"], options_switch_template) --, options_text_template
local GuildRankCheckBox, GuildRankLabel = DF:CreateSwitch(f, selectGuildRank, true, 18, 18, "", "", "GuildRankCheckBox", nil, nil, nil, nil, Loc ["STRING_GUILDDAMAGERANK_SHOWRANK"], options_switch_template) --, options_text_template
GuildRankLabel:ClearAllPoints()
GuildRankCheckBox:ClearAllPoints()
GuildRankCheckBox:SetPoint("topleft", f, "topleft", 240, -34)
@@ -201,7 +201,7 @@ function Details:OpenRaidHistoryWindow (_raid, _boss, _difficulty, _role, _guild
f.WorkingFrame:Show()
f.WorkingAnimation:Play()
C_Timer.NewTicker (10, function(self)
C_Timer.NewTicker(10, function(self)
if (not Details.LastGuildSyncReceived) then
f.GuildSyncButton:Enable()
f.EndAnimationHub:Play()
@@ -214,7 +214,7 @@ function Details:OpenRaidHistoryWindow (_raid, _boss, _difficulty, _role, _guild
end)
end
local GuildSyncButton = DF:CreateButton (f, doGuildSync, 130, 20, Loc ["STRING_GUILDDAMAGERANK_SYNCBUTTONTEXT"], nil, nil, nil, "GuildSyncButton", nil, nil, options_button_template, options_text_template)
local GuildSyncButton = DF:CreateButton(f, doGuildSync, 130, 20, Loc ["STRING_GUILDDAMAGERANK_SYNCBUTTONTEXT"], nil, nil, nil, "GuildSyncButton", nil, nil, options_button_template, options_text_template)
GuildSyncButton:SetPoint("topright", f, "topright", -20, -34)
GuildSyncButton:SetIcon ([[Interface\GLUES\CharacterSelect\RestoreButton]], 12, 12, "overlay", {0.2, .8, 0.2, .8}, nil, 4)
@@ -290,7 +290,7 @@ function Details:OpenRaidHistoryWindow (_raid, _boss, _difficulty, _role, _guild
end
end
local ReportButton = DF:CreateButton (f, f.BuildReport, 130, 20, Loc ["STRING_OPTIONS_REPORT_ANCHOR"]:gsub (":", ""), nil, nil, nil, "ReportButton", nil, nil, options_button_template, options_text_template)
local ReportButton = DF:CreateButton(f, f.BuildReport, 130, 20, Loc ["STRING_OPTIONS_REPORT_ANCHOR"]:gsub (":", ""), nil, nil, nil, "ReportButton", nil, nil, options_button_template, options_text_template)
ReportButton:SetPoint("right", GuildSyncButton, "left", -2, 0)
ReportButton:SetIcon ([[Interface\GLUES\CharacterSelect\RestoreButton]], 12, 12, "overlay", {0.2, .8, 0.2, .8}, nil, 4)
@@ -299,7 +299,7 @@ function Details:OpenRaidHistoryWindow (_raid, _boss, _difficulty, _role, _guild
local instanceId = Details:GetInstanceIdFromEncounterId (encounterId)
if (instanceId) then
local file, L, R, T, B = Details:GetRaidBackground (instanceId)
--print ("file:", file)
--print("file:", file)
--can't get the image, looks to be restricted
--[[
if (file) then
@@ -373,7 +373,7 @@ function Details:OpenRaidHistoryWindow (_raid, _boss, _difficulty, _role, _guild
end
local raid_dropdown = DF:CreateDropDown (f, buildRaidList, 1, dropdownWidth, 20, "select_raid")
local raid_string = DF:CreateLabel(f, Loc ["STRING_GUILDDAMAGERANK_RAID"] .. ":", _, _, "GameFontNormal", "select_raid_label")
raid_dropdown:SetTemplate (DF:GetTemplate ("dropdown", "OPTIONS_DROPDOWN_TEMPLATE"))
raid_dropdown:SetTemplate(DF:GetTemplate("dropdown", "OPTIONS_DROPDOWN_TEMPLATE"))
--select boss:
local on_boss_select = function(_, _, boss)
@@ -384,7 +384,7 @@ function Details:OpenRaidHistoryWindow (_raid, _boss, _difficulty, _role, _guild
end
local boss_dropdown = DF:CreateDropDown (f, build_boss_list, 1, dropdownWidth, 20, "select_boss")
local boss_string = DF:CreateLabel(f, Loc ["STRING_GUILDDAMAGERANK_BOSS"] .. ":", _, _, "GameFontNormal", "select_boss_label")
boss_dropdown:SetTemplate (DF:GetTemplate ("dropdown", "OPTIONS_DROPDOWN_TEMPLATE"))
boss_dropdown:SetTemplate(DF:GetTemplate("dropdown", "OPTIONS_DROPDOWN_TEMPLATE"))
--select difficulty:
local on_diff_select = function(_, _, diff)
@@ -397,7 +397,7 @@ function Details:OpenRaidHistoryWindow (_raid, _boss, _difficulty, _role, _guild
end
local diff_dropdown = DF:CreateDropDown (f, build_diff_list, 1, dropdownWidth, 20, "select_diff")
local diff_string = DF:CreateLabel(f, Loc ["STRING_GUILDDAMAGERANK_DIFF"] .. ":", _, _, "GameFontNormal", "select_diff_label")
diff_dropdown:SetTemplate (DF:GetTemplate ("dropdown", "OPTIONS_DROPDOWN_TEMPLATE"))
diff_dropdown:SetTemplate(DF:GetTemplate("dropdown", "OPTIONS_DROPDOWN_TEMPLATE"))
--select role:
local on_role_select = function(_, _, role)
@@ -411,7 +411,7 @@ function Details:OpenRaidHistoryWindow (_raid, _boss, _difficulty, _role, _guild
end
local role_dropdown = DF:CreateDropDown (f, build_role_list, 1, dropdownWidth, 20, "select_role")
local role_string = DF:CreateLabel(f, Loc ["STRING_GUILDDAMAGERANK_ROLE"] .. ":", _, _, "GameFontNormal", "select_role_label")
role_dropdown:SetTemplate (DF:GetTemplate ("dropdown", "OPTIONS_DROPDOWN_TEMPLATE"))
role_dropdown:SetTemplate(DF:GetTemplate("dropdown", "OPTIONS_DROPDOWN_TEMPLATE"))
--select guild:
local on_guild_select = function(_, _, guild)
@@ -422,7 +422,7 @@ function Details:OpenRaidHistoryWindow (_raid, _boss, _difficulty, _role, _guild
end
local guild_dropdown = DF:CreateDropDown (f, build_guild_list, 1, dropdownWidth, 20, "select_guild")
local guild_string = DF:CreateLabel(f, Loc ["STRING_GUILDDAMAGERANK_GUILD"] .. ":", _, _, "GameFontNormal", "select_guild_label")
guild_dropdown:SetTemplate (DF:GetTemplate ("dropdown", "OPTIONS_DROPDOWN_TEMPLATE"))
guild_dropdown:SetTemplate(DF:GetTemplate("dropdown", "OPTIONS_DROPDOWN_TEMPLATE"))
--select playerbase:
local on_player_select = function(_, _, player)
@@ -436,7 +436,7 @@ function Details:OpenRaidHistoryWindow (_raid, _boss, _difficulty, _role, _guild
end
local player_dropdown = DF:CreateDropDown (f, build_player_list, 1, dropdownWidth, 20, "select_player")
local player_string = DF:CreateLabel(f, Loc ["STRING_GUILDDAMAGERANK_PLAYERBASE"] .. ":", _, _, "GameFontNormal", "select_player_label")
player_dropdown:SetTemplate (DF:GetTemplate ("dropdown", "OPTIONS_DROPDOWN_TEMPLATE"))
player_dropdown:SetTemplate(DF:GetTemplate("dropdown", "OPTIONS_DROPDOWN_TEMPLATE"))
--select player:
local onPlayer2Select = function(_, _, player)
@@ -444,7 +444,7 @@ function Details:OpenRaidHistoryWindow (_raid, _boss, _difficulty, _role, _guild
f:BuildPlayerTable (player)
end
local build_player2_list = function()
local encounterTable, guild, role = unpack (f.build_player2_data or {})
local encounterTable, guild, role = unpack(f.build_player2_data or {})
local t = {}
local alreadyListed = {}
if (encounterTable) then
@@ -466,7 +466,7 @@ function Details:OpenRaidHistoryWindow (_raid, _boss, _difficulty, _role, _guild
end
local player2_dropdown = DF:CreateDropDown (f, build_player2_list, 1, dropdownWidth, 20, "select_player2")
local player2_string = DF:CreateLabel(f, Loc ["STRING_GUILDDAMAGERANK_PLAYERBASE_PLAYER"] .. ":", _, _, "GameFontNormal", "select_player2_label")
player2_dropdown:SetTemplate (DF:GetTemplate ("dropdown", "OPTIONS_DROPDOWN_TEMPLATE"))
player2_dropdown:SetTemplate(DF:GetTemplate("dropdown", "OPTIONS_DROPDOWN_TEMPLATE"))
function f:UpdateDropdowns(DoNotSelectRaid)
@@ -494,7 +494,7 @@ function Details:OpenRaidHistoryWindow (_raid, _boss, _difficulty, _role, _guild
if (difficulty == 14) then
--don't show normal encounters
--tinsert(difficultyList, {value = 14, label = "Normal", icon = icon, onclick = on_diff_select})
--print ("has normal encounter")
--print("has normal encounter")
elseif (difficulty == 15) then
local alreadyHave = false
@@ -581,7 +581,7 @@ function Details:OpenRaidHistoryWindow (_raid, _boss, _difficulty, _role, _guild
if (type(difficulty) == "number") then
if (difficulty == 14) then
--tinsert(difficultyList, {value = 14, label = "Normal", icon = icon, onclick = on_diff_select})
--print ("has normal encounter")
--print("has normal encounter")
elseif (difficulty == 15) then
local alreadyHave = false
for i, t in ipairs(difficultyList) do
@@ -664,10 +664,10 @@ function Details:OpenRaidHistoryWindow (_raid, _boss, _difficulty, _role, _guild
function f:BuildPlayerTable (playerName)
local encounterTable, guild, role = unpack (f.build_player2_data or {})
local encounterTable, guild, role = unpack(f.build_player2_data or {})
local data = {}
if (type(playerName) == "string" and string.len (playerName) > 1) then
if (type(playerName) == "string" and string.len(playerName) > 1) then
for encounterIndex, encounter in ipairs(encounterTable) do
if (encounter.guild == guild) then
@@ -693,12 +693,12 @@ function Details:OpenRaidHistoryWindow (_raid, _boss, _difficulty, _role, _guild
local onenter = function(self)
GameCooltip:Reset()
GameCooltip:SetType ("tooltip")
GameCooltip:Preset (2)
GameCooltip:Preset(2)
GameCooltip:AddLine ("Total Done:", Details:ToK2 (self.data.value), 1, "white")
GameCooltip:AddLine ("Dps:", Details:ToK2 (self.data.value / self.data.elapsed), 1, "white")
GameCooltip:AddLine ("Item Level:", floor (self.data.data [2]), 1, "white")
GameCooltip:AddLine ("Date:", self.data.fulldate:gsub (".*%s", ""), 1, "white")
GameCooltip:AddLine("Total Done:", Details:ToK2 (self.data.value), 1, "white")
GameCooltip:AddLine("Dps:", Details:ToK2 (self.data.value / self.data.elapsed), 1, "white")
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:Show()
@@ -768,19 +768,19 @@ function Details:OpenRaidHistoryWindow (_raid, _boss, _difficulty, _role, _guild
local sortTable = {}
for playerName, t in pairs(playerScore) do
local className = select (2, GetClassInfo (t.class or 0))
local className = select(2, GetClassInfo (t.class or 0))
local classColor = "FFFFFFFF"
if (className) then
classColor = RAID_CLASS_COLORS [className] and RAID_CLASS_COLORS [className].colorStr
end
local playerNameFormated = Details:GetOnlyName (playerName)
local playerNameFormated = Details:GetOnlyName(playerName)
tinsert(sortTable, {
"|c" .. classColor .. playerNameFormated .. "|r",
Details:comma_value (t.ps),
Details:ToK2 (t.total),
DF:IntegerToTimer (t.length),
floor (t.ilvl),
floor(t.ilvl),
t.date,
t.total,
t.ps,
@@ -841,7 +841,7 @@ function Details:OpenRaidHistoryWindow (_raid, _boss, _difficulty, _role, _guild
tinsert(players, player)
players_index [playerName] = #players
--print ("not index", playerName, amt_encounters, date, 2, amt_encounters-1)
--print("not index", playerName, amt_encounters, date, 2, amt_encounters-1)
else
player = players [index]
for i = #player+1, amt_encounters-1 do
@@ -862,9 +862,9 @@ function Details:OpenRaidHistoryWindow (_raid, _boss, _difficulty, _role, _guild
tinsert(playerTable, "")
end
local className = select (2, GetClassInfo (player_class [playerTable [1]] or 0))
local className = select(2, GetClassInfo (player_class [playerTable [1]] or 0))
if (className) then
local playerNameFormated = Details:GetOnlyName (playerTable[1])
local playerNameFormated = Details:GetOnlyName(playerTable[1])
local classColor = RAID_CLASS_COLORS [className] and RAID_CLASS_COLORS [className].colorStr
playerTable [1] = "|c" .. classColor .. playerNameFormated .. "|r"
end
+7 -7
View File
@@ -242,7 +242,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]))
button.texture:SetTexCoord (unpack(Details.sub_atributos [attribute].icones [i] [2]))
tinsert(allDisplaysFrame.buttons [attribute], button)
y = y - 17
end
@@ -532,12 +532,12 @@ function Details.switch:ShowMe(instancia)
index = index - 1
end
local button = gump:CreateButton (Details.switch.frame, segment_switch, 100, 20, "", index)
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")
local boss_texture = gump:CreateImage (button, nil, 16, 16)
local boss_texture = gump:CreateImage(button, nil, 16, 16)
boss_texture:SetPoint("right", s, "left", -2, 0)
local background = button:CreateTexture(nil, "background")
@@ -586,8 +586,8 @@ function Details.switch:ShowMe(instancia)
local window_width, window_height = Details.switch.current_instancia:GetSize()
local horizontal_amt = floor (math.max (window_width / 100, 2))
local vertical_amt = floor ((window_height - y) / 20)
local horizontal_amt = floor(math.max(window_width / 100, 2))
local vertical_amt = floor((window_height - y) / 20)
local size = window_width / horizontal_amt
local frame = Details.switch.frame
@@ -694,7 +694,7 @@ function Details.switch:ShowMe(instancia)
Details.switch.frame:SetPoint("bottomright", instancia.baseframe, "bottomright", 0, 1)
local altura = instancia.baseframe:GetHeight()
local mostrar_quantas = floor (altura / Details.switch.button_height) * 2
local mostrar_quantas = floor(altura / Details.switch.button_height) * 2
local precisa_mostrar = 0
for i = 1, #Details.switch.table do
@@ -932,7 +932,7 @@ function Details.switch:Update()
local button = Details.switch.buttons [i]
if (not button) then
button = Details.switch:NewSwitchButton (Details.switch.frame, i, x, y, jump)
button:SetFrameLevel (Details.switch.frame:GetFrameLevel()+2)
button:SetFrameLevel(Details.switch.frame:GetFrameLevel()+2)
Details.switch.showing = Details.switch.showing + 1
end
+87 -87
View File
@@ -1,5 +1,5 @@
local _detalhes = _G._detalhes
local L = LibStub ("AceLocale-3.0"):GetLocale ( "Details" )
local L = LibStub("AceLocale-3.0"):GetLocale ( "Details" )
--default weaktable
_detalhes.weaktable = {__mode = "v"}
@@ -68,7 +68,7 @@ local text_dispell_prototype = {
["events"] = "COMBAT_LOG_EVENT_UNFILTERED, ENCOUNTER_START",
["use_spellName"] = false,
["use_spellId"] = false,
["custom"] = "function(event, time, token, hidding, who_serial, who_name, who_flags, who_flags2, alvo_serial, alvo_name, alvo_flags, alvo_flags2, spellid, spellname, spelltype, extraSpellID, extraSpellName, extraSchool)\n if (event == \"COMBAT_LOG_EVENT_UNFILTERED\") then\n \n if ((token == \"SPELL_DISPEL\" or token == \"SPELL_STOLEN\") and extraSpellID == 159947) then\n aura_env.dispelled = aura_env.dispelled + 1\n aura_env.dispels_by [who_name] = (aura_env.dispels_by [who_name] or 0) + 1\n \n aura_env.text = aura_env.text .. \"|cffd2e8ff\" .. who_name .. \" (\" .. aura_env.dispels_by [who_name] .. \") \".. \"|r\\n\"\n \n if (select (2, aura_env.text:gsub (\"\\n\", \"\")) == 9) then\n aura_env.text = aura_env.text:gsub (\".-\\n\", \"\", 1)\n end\n return true\n end \n else\n aura_env.text = \"\"\n aura_env.success = 0\n aura_env.dispelled = 0\n wipe (aura_env.dispels_by)\n return true \n end\nend",
["custom"] = "function(event, time, token, hidding, who_serial, who_name, who_flags, who_flags2, alvo_serial, alvo_name, alvo_flags, alvo_flags2, spellid, spellname, spelltype, extraSpellID, extraSpellName, extraSchool)\n if (event == \"COMBAT_LOG_EVENT_UNFILTERED\") then\n \n if ((token == \"SPELL_DISPEL\" or token == \"SPELL_STOLEN\") and extraSpellID == 159947) then\n aura_env.dispelled = aura_env.dispelled + 1\n aura_env.dispels_by [who_name] = (aura_env.dispels_by [who_name] or 0) + 1\n \n aura_env.text = aura_env.text .. \"|cffd2e8ff\" .. who_name .. \" (\" .. aura_env.dispels_by [who_name] .. \") \".. \"|r\\n\"\n \n if (select(2, aura_env.text:gsub (\"\\n\", \"\")) == 9) then\n aura_env.text = aura_env.text:gsub (\".-\\n\", \"\", 1)\n end\n return true\n end \n else\n aura_env.text = \"\"\n aura_env.success = 0\n aura_env.dispelled = 0\n wipe (aura_env.dispels_by)\n return true \n end\nend",
["spellIds"] = {
},
["use_message"] = true,
@@ -1419,7 +1419,7 @@ local glow_prototype = {
function _detalhes:CreateWeakAura (aura_type, spellid, use_spellid, spellname, name, icon_texture, target, stacksize, sound, chat, icon_text, icon_glow, encounter_id, group, icon_size, other_values, in_combat, cooldown_animation)
--print (aura_type, spellid, use_spellid, spellname, name, icon_texture, target, stacksize, sound, chat, icon_text, icon_glow, encounter_id, group, icon_size, other_values)
--print(aura_type, spellid, use_spellid, spellname, name, icon_texture, target, stacksize, sound, chat, icon_text, icon_glow, encounter_id, group, icon_size, other_values)
--check if wa is installed
if (not WeakAuras or not WeakAurasSaved) then
@@ -1466,7 +1466,7 @@ function _detalhes:CreateWeakAura (aura_type, spellid, use_spellid, spellname, n
aura_env.interrupted = aura_env.interrupted + 1
aura_env.text = aura_env.text .. "|cffc5ffc5" .. who_name .. " (" .. aura_env.interrupted .. ") ".. "|r\n"
end
if (select (2, aura_env.text:gsub ("\n", "")) == 9) then
if (select(2, aura_env.text:gsub ("\n", "")) == 9) then
aura_env.text = aura_env.text:gsub (".-\n", "", 1)
end
return true
@@ -1509,7 +1509,7 @@ function _detalhes:CreateWeakAura (aura_type, spellid, use_spellid, spellname, n
aura_env.dispels_by [who_name] = (aura_env.dispels_by [who_name] or 0) + 1
aura_env.text = aura_env.text .. "|cffd2e8ff" .. who_name .. " (" .. aura_env.dispels_by [who_name] .. ") ".. "|r\n"
if (select (2, aura_env.text:gsub ("\n", "")) == 11) then
if (select(2, aura_env.text:gsub ("\n", "")) == 11) then
aura_env.text = aura_env.text:gsub (".-\n", "", 2)
aura_env.text = "@title\n" .. aura_env.text
end
@@ -1566,7 +1566,7 @@ function _detalhes:CreateWeakAura (aura_type, spellid, use_spellid, spellname, n
new_aura.width = icon_size
new_aura.height = icon_size
elseif (aura_type == "aurabar") then
new_aura.width = max (icon_size, 370)
new_aura.width = max(icon_size, 370)
new_aura.height = 38
elseif (aura_type == "text") then
new_aura.fontSize = min (icon_size, 72)
@@ -1580,15 +1580,15 @@ function _detalhes:CreateWeakAura (aura_type, spellid, use_spellid, spellname, n
]]
init_start = init_start:gsub ("@text", icon_text)
init_start = init_start:gsub ("@countdown", floor (stacksize))
new_aura.trigger.remaining = tostring (floor (stacksize))
init_start = init_start:gsub ("@countdown", floor(stacksize))
new_aura.trigger.remaining = tostring (floor(stacksize))
new_aura.actions.init.custom = init_start
if (other_values.dbm_timer_id) then
new_aura.trigger.event = "DBM Timer"
local timerId = tostring (other_values.dbm_timer_id)
--print ("timerId:", other_values.dbm_timer_id, type (other_values.dbm_timer_id), timerId:find ("%s"))
--print("timerId:", other_values.dbm_timer_id, type(other_values.dbm_timer_id), timerId:find ("%s"))
--other_values.spellid
--if (timerId:find ("%s")) then
@@ -1617,8 +1617,8 @@ function _detalhes:CreateWeakAura (aura_type, spellid, use_spellid, spellname, n
local init_start = [[
aura_env.reimaningTime = @countdown
]]
init_start = init_start:gsub ("@countdown", floor (stacksize))
trigger.remaining = tostring (floor (stacksize))
init_start = init_start:gsub ("@countdown", floor(stacksize))
trigger.remaining = tostring (floor(stacksize))
new_aura.actions.init.custom = init_start
if (other_values.dbm_timer_id) then
@@ -1795,7 +1795,7 @@ function _detalhes:CreateWeakAura (aura_type, spellid, use_spellid, spellname, n
--check stack size
if (stacksize and stacksize >= 1) then
stacksize = floor (stacksize)
stacksize = floor(stacksize)
local add = _detalhes.table.copy ({}, stack_prototype)
add.trigger.count = tostring (stacksize)
_detalhes.table.overwrite (new_aura, add)
@@ -1835,7 +1835,7 @@ function _detalhes:CreateWeakAura (aura_type, spellid, use_spellid, spellname, n
end
--using sound
if (sound and type (sound) == "table") then
if (sound and type(sound) == "table") then
local add = _detalhes.table.copy ({}, sound_prototype_custom)
add.actions.start.sound_path = sound.sound_path
add.actions.start.sound_channel = sound.sound_channel or "Master"
@@ -1958,7 +1958,7 @@ local empty_other_values = {}
function _detalhes:OpenAuraPanel (spellid, spellname, spellicon, encounterid, triggertype, auratype, other_values)
if (not spellname) then
spellname = select (1, GetSpellInfo(spellid))
spellname = select(1, GetSpellInfo(spellid))
end
wipe (empty_other_values)
@@ -1984,17 +1984,17 @@ function _detalhes:OpenAuraPanel (spellid, spellname, spellicon, encounterid, tr
f:SetSize(800, 600)
f:SetPoint("center", UIParent, "center", 0, 150)
f:SetFrameStrata("DIALOG")
f:EnableMouse (true)
f:SetMovable (true)
f:EnableMouse(true)
f:SetMovable(true)
f:SetToplevel (true)
--background
f.bg1 = f:CreateTexture(nil, "background")
f.bg1:SetTexture([[Interface\AddOns\Details\images\background]], true)
f.bg1:SetAlpha (0.8)
f.bg1:SetVertexColor (0.27, 0.27, 0.27)
f.bg1:SetVertTile (true)
f.bg1:SetHorizTile (true)
f.bg1:SetAlpha(0.8)
f.bg1:SetVertexColor(0.27, 0.27, 0.27)
f.bg1:SetVertTile(true)
f.bg1:SetHorizTile(true)
f.bg1:SetSize(790, 454)
f.bg1:SetAllPoints()
f:SetBackdrop({edgeFile = [[Interface\Buttons\WHITE8X8]], edgeSize = 1, bgFile = [[Interface\AddOns\Details\images\background]], tileSize = 64, tile = true})
@@ -2002,11 +2002,11 @@ function _detalhes:OpenAuraPanel (spellid, spellname, spellicon, encounterid, tr
f:SetBackdropBorderColor(0, 0, 0, 1)
--register to libwindow
local LibWindow = LibStub ("LibWindow-1.1")
LibWindow.RegisterConfig (f, _detalhes.createauraframe)
LibWindow.RestorePosition (f)
LibWindow.MakeDraggable (f)
LibWindow.SavePosition (f)
local LibWindow = LibStub("LibWindow-1.1")
LibWindow.RegisterConfig(f, _detalhes.createauraframe)
LibWindow.RestorePosition(f)
LibWindow.MakeDraggable(f)
LibWindow.SavePosition(f)
f:SetScript("OnMouseDown", function(self, button)
if (button == "RightButton") then
@@ -2035,7 +2035,7 @@ function _detalhes:OpenAuraPanel (spellid, spellname, spellicon, encounterid, tr
f.Close:GetHighlightTexture():SetDesaturated(true)
f.Close:GetPushedTexture():SetDesaturated(true)
f.Close:SetAlpha (0.7)
f.Close:SetAlpha(0.7)
f.Close:SetScript("OnClick", function() f:Hide() end)
--title
@@ -2045,16 +2045,16 @@ function _detalhes:OpenAuraPanel (spellid, spellname, spellicon, encounterid, tr
local fw = _detalhes:GetFramework()
local text_template = fw:GetTemplate ("font", "OPTIONS_FONT_TEMPLATE")
local dropdown_template = fw:GetTemplate ("dropdown", "OPTIONS_DROPDOWN_TEMPLATE")
local switch_template = fw:GetTemplate ("switch", "OPTIONS_CHECKBOX_TEMPLATE")
local slider_template = fw:GetTemplate ("slider", "OPTIONS_SLIDER_TEMPLATE")
local button_template = fw:GetTemplate ("button", "OPTIONS_BUTTON_TEMPLATE")
local text_template = fw:GetTemplate("font", "OPTIONS_FONT_TEMPLATE")
local dropdown_template = fw:GetTemplate("dropdown", "OPTIONS_DROPDOWN_TEMPLATE")
local switch_template = fw:GetTemplate("switch", "OPTIONS_CHECKBOX_TEMPLATE")
local slider_template = fw:GetTemplate("slider", "OPTIONS_SLIDER_TEMPLATE")
local button_template = fw:GetTemplate("button", "OPTIONS_BUTTON_TEMPLATE")
--aura name
local name_label = fw:CreateLabel(f, "Aura Name: ", nil, nil, "GameFontNormal")
local name_textentry = fw:CreateTextEntry (f, _detalhes.empty_function, 150, 20, "AuraName", "$parentAuraName")
name_textentry:SetTemplate (slider_template)
name_textentry:SetTemplate(slider_template)
name_textentry:SetPoint("left", name_label, "right", 2, 0)
f.name = name_textentry
@@ -2077,13 +2077,13 @@ function _detalhes:OpenAuraPanel (spellid, spellname, spellicon, encounterid, tr
aura_type:SetPoint("left", aura_type_label, "right", 2, 0)
aura_type:Hide()
local Icon_IconAuraType = fw:CreateImage (f, [[Interface\AddOns\Details\images\icons2]], 32, 32, "overlay", {200/512, 232/512, 336/512, 368/512}, nil, nil)
local Icon_IconAuraType = fw:CreateImage(f, [[Interface\AddOns\Details\images\icons2]], 32, 32, "overlay", {200/512, 232/512, 336/512, 368/512}, nil, nil)
Icon_IconAuraType:SetPoint("topleft", aura_type_label, "bottomleft", 10, -16)
local Icon_StatusbarAuraType = fw:CreateImage (f, [[Interface\AddOns\Details\images\icons2]], 92, 12, "overlay", {235/512, 327/512, 336/512, 348/512}, nil, nil)
local Icon_StatusbarAuraType = fw:CreateImage(f, [[Interface\AddOns\Details\images\icons2]], 92, 12, "overlay", {235/512, 327/512, 336/512, 348/512}, nil, nil)
Icon_StatusbarAuraType:SetPoint("topleft", aura_type_label, "bottomleft", 60, -26)
local Icon_TextOnlyAuraType = fw:CreateImage (f, [[Interface\AddOns\Details\images\icons2]], 57, 8, "overlay", {250/512, 306/512, 360/512, 367/512}, nil, nil)
local Icon_TextOnlyAuraType = fw:CreateImage(f, [[Interface\AddOns\Details\images\icons2]], 57, 8, "overlay", {250/512, 306/512, 360/512, 367/512}, nil, nil)
Icon_TextOnlyAuraType:SetPoint("topleft", aura_type_label, "bottomleft", 170, -28)
local AuraTypeSelectedColor = {1, 1, 1, 0.3}
@@ -2106,19 +2106,19 @@ function _detalhes:OpenAuraPanel (spellid, spellname, spellicon, encounterid, tr
f.StatusbarAuraTypeButton:SetBackdropColor(0, 0, 0, 0.05)
f.TextOnlyAuraTypeButton:SetBackdropColor(0, 0, 0, 0.05)
f.IconAuraTypeButton:SetBackdropBorderColor(unpack (AuraTypeBorderColor))
f.StatusbarAuraTypeButton:SetBackdropBorderColor(unpack (AuraTypeBorderColor))
f.TextOnlyAuraTypeButton:SetBackdropBorderColor(unpack (AuraTypeBorderColor))
f.IconAuraTypeButton:SetBackdropBorderColor(unpack(AuraTypeBorderColor))
f.StatusbarAuraTypeButton:SetBackdropBorderColor(unpack(AuraTypeBorderColor))
f.TextOnlyAuraTypeButton:SetBackdropBorderColor(unpack(AuraTypeBorderColor))
if (auraType == "icon") then
f.IconAuraTypeButton:SetBackdropColor(unpack (AuraTypeSelectedColor))
f.IconAuraTypeButton:SetBackdropBorderColor(unpack (AuraTypeBorderSelectedColor))
f.IconAuraTypeButton:SetBackdropColor(unpack(AuraTypeSelectedColor))
f.IconAuraTypeButton:SetBackdropBorderColor(unpack(AuraTypeBorderSelectedColor))
elseif (auraType == "aurabar") then
f.StatusbarAuraTypeButton:SetBackdropColor(unpack (AuraTypeSelectedColor))
f.StatusbarAuraTypeButton:SetBackdropBorderColor(unpack (AuraTypeBorderSelectedColor))
f.StatusbarAuraTypeButton:SetBackdropColor(unpack(AuraTypeSelectedColor))
f.StatusbarAuraTypeButton:SetBackdropBorderColor(unpack(AuraTypeBorderSelectedColor))
elseif (auraType == "text") then
f.TextOnlyAuraTypeButton:SetBackdropColor(unpack (AuraTypeSelectedColor))
f.TextOnlyAuraTypeButton:SetBackdropBorderColor(unpack (AuraTypeBorderSelectedColor))
f.TextOnlyAuraTypeButton:SetBackdropColor(unpack(AuraTypeSelectedColor))
f.TextOnlyAuraTypeButton:SetBackdropBorderColor(unpack(AuraTypeBorderSelectedColor))
end
aura_type:SetValue(auraType)
@@ -2134,25 +2134,25 @@ function _detalhes:OpenAuraPanel (spellid, spellname, spellicon, encounterid, tr
AuraTypeBackground:SetPoint("topleft", f, "topleft", 10, -79)
AuraTypeBackground:SetPoint("topright", f, "topright", -10, -79)
local Icon_IconAuraTypeButton = fw:CreateButton (f, OnSelectAuraType, 46, 46, "", "icon", nil, nil, "IconAuraTypeButton")
local Icon_StatusbarAuraTypeButton = fw:CreateButton (f, OnSelectAuraType, 100, 46, "", "aurabar", nil, nil, "StatusbarAuraTypeButton")
local Icon_TextOnlyAuraTypeButton = fw:CreateButton (f, OnSelectAuraType, 69, 46, "", "text", nil, nil, "TextOnlyAuraTypeButton")
local Icon_IconAuraTypeButton = fw:CreateButton(f, OnSelectAuraType, 46, 46, "", "icon", nil, nil, "IconAuraTypeButton")
local Icon_StatusbarAuraTypeButton = fw:CreateButton(f, OnSelectAuraType, 100, 46, "", "aurabar", nil, nil, "StatusbarAuraTypeButton")
local Icon_TextOnlyAuraTypeButton = fw:CreateButton(f, OnSelectAuraType, 69, 46, "", "text", nil, nil, "TextOnlyAuraTypeButton")
Icon_IconAuraTypeButton:SetPoint("center", Icon_IconAuraType, "center")
Icon_StatusbarAuraTypeButton:SetPoint("center", Icon_StatusbarAuraType, "center")
Icon_TextOnlyAuraTypeButton:SetPoint("center", Icon_TextOnlyAuraType, "center")
Icon_IconAuraTypeButton:SetBackdrop({edgeFile = [[Interface\AddOns\Details\images\dotted]], edgeSize = 1, bgFile = [[Interface\Tooltips\UI-Tooltip-Background]], tileSize = 64, tile = true})
Icon_IconAuraTypeButton:SetBackdropColor(unpack (AuraTypeSelectedColor))
Icon_IconAuraTypeButton:SetBackdropBorderColor(unpack (AuraTypeBorderColor))
Icon_IconAuraTypeButton:SetBackdropColor(unpack(AuraTypeSelectedColor))
Icon_IconAuraTypeButton:SetBackdropBorderColor(unpack(AuraTypeBorderColor))
Icon_StatusbarAuraTypeButton:SetBackdrop({edgeFile = [[Interface\AddOns\Details\images\dotted]], edgeSize = 1, bgFile = [[Interface\Tooltips\UI-Tooltip-Background]], tileSize = 64, tile = true})
Icon_StatusbarAuraTypeButton:SetBackdropColor(0, 0, 0, 0.05)
Icon_StatusbarAuraTypeButton:SetBackdropBorderColor(unpack (AuraTypeBorderColor))
Icon_StatusbarAuraTypeButton:SetBackdropBorderColor(unpack(AuraTypeBorderColor))
Icon_TextOnlyAuraTypeButton:SetBackdrop({edgeFile = [[Interface\AddOns\Details\images\dotted]], edgeSize = 1, bgFile = [[Interface\Tooltips\UI-Tooltip-Background]], tileSize = 64, tile = true})
Icon_TextOnlyAuraTypeButton:SetBackdropColor(0, 0, 0, 0.05)
Icon_TextOnlyAuraTypeButton:SetBackdropBorderColor(unpack (AuraTypeBorderColor))
Icon_TextOnlyAuraTypeButton:SetBackdropBorderColor(unpack(AuraTypeBorderColor))
--trigger list
--target
@@ -2226,8 +2226,8 @@ function _detalhes:OpenAuraPanel (spellid, spellname, spellicon, encounterid, tr
end
for i = 1, #triggerList do
local checkBox = fw:CreateSwitch (f, OnChangeTriggerState, i == 1)
checkBox:SetTemplate (fw:GetTemplate ("switch", "OPTIONS_CHECKBOX_TEMPLATE"))
local checkBox = fw:CreateSwitch(f, OnChangeTriggerState, i == 1)
checkBox:SetTemplate(fw:GetTemplate("switch", "OPTIONS_CHECKBOX_TEMPLATE"))
checkBox:SetAsCheckBox()
checkBox:SetFixedParameter(triggerList [i].value)
@@ -2245,7 +2245,7 @@ function _detalhes:OpenAuraPanel (spellid, spellname, spellicon, encounterid, tr
--spellname
local spellname_label = fw:CreateLabel(f, "Spell Name: ", nil, nil, "GameFontNormal")
local spellname_textentry = fw:CreateTextEntry (f, _detalhes.empty_function, 150, 20, "SpellName", "$parentSpellName")
spellname_textentry:SetTemplate (slider_template)
spellname_textentry:SetTemplate(slider_template)
spellname_textentry:SetPoint("left", spellname_label, "right", 2, 0)
f.spellname = spellname_textentry
spellname_textentry.tooltip = "Spell/Debuff/Buff to be tracked."
@@ -2253,14 +2253,14 @@ function _detalhes:OpenAuraPanel (spellid, spellname, spellicon, encounterid, tr
--spellid
local auraid_label = fw:CreateLabel(f, "Spell Id: ", nil, nil, "GameFontNormal")
local auraid_textentry = fw:CreateTextEntry (f, _detalhes.empty_function, 150, 20, "AuraSpellId", "$parentAuraSpellId")
auraid_textentry:SetTemplate (slider_template)
auraid_textentry:SetTemplate(slider_template)
auraid_textentry:Disable()
auraid_textentry:SetPoint("left", auraid_label, "right", 2, 0)
--use spellid
local usespellid_label = fw:CreateLabel(f, "Use SpellId: ", nil, nil, "GameFontNormal")
local aura_use_spellid = fw:CreateSwitch (f, function(_, _, state) if (state) then auraid_textentry:Enable() else auraid_textentry:Disable() end end, false, nil, nil, nil, nil, "UseSpellId")
aura_use_spellid:SetTemplate (fw:GetTemplate ("switch", "OPTIONS_CHECKBOX_TEMPLATE"))
local aura_use_spellid = fw:CreateSwitch(f, function(_, _, state) if (state) then auraid_textentry:Enable() else auraid_textentry:Disable() end end, false, nil, nil, nil, nil, "UseSpellId")
aura_use_spellid:SetTemplate(fw:GetTemplate("switch", "OPTIONS_CHECKBOX_TEMPLATE"))
aura_use_spellid:SetAsCheckBox()
aura_use_spellid:SetPoint("left", usespellid_label, "right", 2, 0)
@@ -2268,8 +2268,8 @@ function _detalhes:OpenAuraPanel (spellid, spellname, spellicon, encounterid, tr
--in combat only
local incombat_label = fw:CreateLabel(f, "Only in Combat: ", nil, nil, "GameFontNormal")
local aura_incombat = fw:CreateSwitch (f, function(_, _, state) end, true, nil, nil, nil, nil, "UseInCombat")
aura_incombat:SetTemplate (fw:GetTemplate ("switch", "OPTIONS_CHECKBOX_TEMPLATE"))
local aura_incombat = fw:CreateSwitch(f, function(_, _, state) end, true, nil, nil, nil, nil, "UseInCombat")
aura_incombat:SetTemplate(fw:GetTemplate("switch", "OPTIONS_CHECKBOX_TEMPLATE"))
aura_incombat:SetAsCheckBox()
aura_incombat:SetPoint("left", incombat_label, "right", 2, 0)
aura_incombat.tooltip = "Only active when in combat."
@@ -2290,8 +2290,8 @@ function _detalhes:OpenAuraPanel (spellid, spellname, spellicon, encounterid, tr
--is cooldown
local iscooldown_label = fw:CreateLabel(f, "Cooldown Animation: ", nil, nil, "GameFontNormal")
local aura_iscooldown = fw:CreateSwitch (f, function(_, _, state) end, true, nil, nil, nil, nil, "IsCooldown")
aura_iscooldown:SetTemplate (fw:GetTemplate ("switch", "OPTIONS_CHECKBOX_TEMPLATE"))
local aura_iscooldown = fw:CreateSwitch(f, function(_, _, state) end, true, nil, nil, nil, nil, "IsCooldown")
aura_iscooldown:SetTemplate(fw:GetTemplate("switch", "OPTIONS_CHECKBOX_TEMPLATE"))
aura_iscooldown:SetAsCheckBox()
aura_iscooldown:SetPoint("left", iscooldown_label, "right", 2, 0)
aura_iscooldown.tooltip = "Only active when in combat."
@@ -2299,7 +2299,7 @@ function _detalhes:OpenAuraPanel (spellid, spellname, spellicon, encounterid, tr
--stack
local stack_slider = fw:NewSlider (f, f, "$parentStackSlider", "StackSlider", 150, 20, 0, 30, 1, 0, true)
stack_slider.useDecimals = true
stack_slider:SetTemplate (slider_template)
stack_slider:SetTemplate(slider_template)
local stack_label = fw:CreateLabel(f, "Trigger Stack Size: ", nil, nil, "GameFontNormal")
stack_slider:SetPoint("left", stack_label, "right", 2, 0)
stack_slider.tooltip = "Minimum amount of stacks to trigger the aura."
@@ -2397,7 +2397,7 @@ function _detalhes:OpenAuraPanel (spellid, spellname, spellicon, encounterid, tr
return t
end
local sound_effect = fw:CreateDropDown (f, sound_options, 1, 150, 20, "SoundEffectDropdown", "$parentSoundEffectDropdown")
sound_effect:SetTemplate (slider_template)
sound_effect:SetTemplate(slider_template)
local sound_effect_label = fw:CreateLabel(f, "Play Sound: ", nil, nil, "GameFontNormal")
sound_effect:SetPoint("left", sound_effect_label, "right", 2, 0)
sound_effect.tooltip = "Sound played when the aura triggers."
@@ -2405,20 +2405,20 @@ function _detalhes:OpenAuraPanel (spellid, spellname, spellicon, encounterid, tr
--say something
local say_something_label = fw:CreateLabel(f, "/Say on Trigger: ", nil, nil, "GameFontNormal")
local say_something = fw:CreateTextEntry (f, _detalhes.empty_function, 150, 20, "SaySomething", "$parentSaySomething")
say_something:SetTemplate (slider_template)
say_something:SetTemplate(slider_template)
say_something:SetPoint("left", say_something_label, "right", 2, 0)
say_something.tooltip = "Your character /say this phrase when the aura triggers."
--aura text
local aura_text_label = fw:CreateLabel(f, "Aura Text: ", nil, nil, "GameFontNormal")
local aura_text = fw:CreateTextEntry (f, _detalhes.empty_function, 150, 20, "AuraText", "$parentAuraText")
aura_text:SetTemplate (slider_template)
aura_text:SetTemplate(slider_template)
aura_text:SetPoint("left", aura_text_label, "right", 2, 0)
aura_text.tooltip = "Text shown at aura's icon right side."
--apply glow
local useglow_label = fw:CreateLabel(f, "Glow Effect: ", nil, nil, "GameFontNormal")
local useglow = fw:CreateSwitch (f, function(self, _, state)
local useglow = fw:CreateSwitch(f, function(self, _, state)
if (state and self.glow_test) then
self.glow_test:Show()
self.glow_test.animOut:Stop()
@@ -2429,7 +2429,7 @@ function _detalhes:OpenAuraPanel (spellid, spellname, spellicon, encounterid, tr
end
end, false, nil, nil, nil, nil, "UseGlow")
useglow:SetTemplate (fw:GetTemplate ("switch", "OPTIONS_CHECKBOX_TEMPLATE"))
useglow:SetTemplate(fw:GetTemplate("switch", "OPTIONS_CHECKBOX_TEMPLATE"))
useglow:SetAsCheckBox()
useglow:SetPoint("left", useglow_label, "right", 2, 0)
@@ -2443,14 +2443,14 @@ function _detalhes:OpenAuraPanel (spellid, spellname, spellicon, encounterid, tr
--encounter id
local encounterid_label = fw:CreateLabel(f, "Encounter ID: ", nil, nil, "GameFontNormal")
local encounterid = fw:CreateTextEntry (f, _detalhes.empty_function, 150, 20, "EncounterIdText", "$parentEncounterIdText")
encounterid:SetTemplate (slider_template)
encounterid:SetTemplate(slider_template)
encounterid:SetPoint("left", encounterid_label, "right", 2, 0)
encounterid.tooltip = "Only load this aura for this raid encounter."
--size
local icon_size_slider = fw:NewSlider (f, f, "$parentIconSizeSlider", "IconSizeSlider", 150, 20, 8, 256, 1, 64)
local icon_size_label = fw:CreateLabel(f, "Size: ", nil, nil, "GameFontNormal")
icon_size_slider:SetTemplate (slider_template)
icon_size_slider:SetTemplate(slider_template)
icon_size_slider:SetPoint("left", icon_size_label, "right", 2, 0)
icon_size_slider.tooltip = "Icon size, width and height."
@@ -2463,7 +2463,7 @@ function _detalhes:OpenAuraPanel (spellid, spellname, spellicon, encounterid, tr
return t
end
local aura_addon = fw:CreateDropDown (f, addon_options, 1, 150, 20, "AuraAddonDropdown", "$parentAuraAddonDropdown")
aura_addon:SetTemplate (slider_template)
aura_addon:SetTemplate(slider_template)
local aura_addon_label = fw:CreateLabel(f, "Addon: ", nil, nil, "GameFontNormal")
aura_addon:SetPoint("left", aura_addon_label, "right", 2, 0)
@@ -2491,7 +2491,7 @@ function _detalhes:OpenAuraPanel (spellid, spellname, spellicon, encounterid, tr
local weakauras_folder_label = fw:CreateLabel(f, "WeakAuras Group: ", nil, nil, "GameFontNormal")
local weakauras_folder = fw:CreateDropDown (f, weakauras_folder_options, 1, 150, 20, "WeakaurasFolderDropdown", "$parentWeakaurasFolder")
weakauras_folder:SetTemplate (slider_template)
weakauras_folder:SetTemplate(slider_template)
weakauras_folder:SetPoint("left", weakauras_folder_label, "right", 2, 0)
--make new group
@@ -2500,19 +2500,19 @@ function _detalhes:OpenAuraPanel (spellid, spellname, spellicon, encounterid, tr
local weakauras_newgroup_textentry = f.NewWeakaurasGroupTextEntry
if (not WeakAurasSaved or not WeakAurasSaved.displays) then
print ("nop, weakauras not found")
print("nop, weakauras not found")
return
end
local groupName = weakauras_newgroup_textentry.text
if (string.len (groupName) == 0) then
print ("nop, group name is too small")
if (string.len(groupName) == 0) then
print("nop, group name is too small")
return
end
if (WeakAurasSaved.displays [groupName]) then
print ("nop, group already exists")
print("nop, group already exists")
return
end
@@ -2538,14 +2538,14 @@ function _detalhes:OpenAuraPanel (spellid, spellname, spellicon, encounterid, tr
local weakauras_newgroup_label = fw:CreateLabel(f, "New WeakAuras Group: ", nil, nil, "GameFontNormal")
local weakauras_newgroup_textentry = fw:CreateTextEntry (f, create_wa_group, 150, 20, "NewWeakaurasGroupTextEntry", "$parentNewWeakaurasGroup")
weakauras_newgroup_textentry:SetTemplate (slider_template)
weakauras_newgroup_textentry:SetTemplate(slider_template)
weakauras_newgroup_textentry:SetPoint("left", weakauras_newgroup_label, "right", 2, 0)
f.weakauras_newgroup = weakauras_newgroup_textentry
weakauras_newgroup_textentry.tooltip = "Enter the name of the new group"
local weakauras_newgroup_button = fw:CreateButton (f, create_wa_group, 106, 20, "Create Group")
weakauras_newgroup_button:SetTemplate (slider_template)
weakauras_newgroup_button:SetTemplate (_detalhes.gump:GetTemplate ("button", "DETAILS_PLUGIN_BUTTON_TEMPLATE"))
local weakauras_newgroup_button = fw:CreateButton(f, create_wa_group, 106, 20, "Create Group")
weakauras_newgroup_button:SetTemplate(slider_template)
weakauras_newgroup_button:SetTemplate(_detalhes.gump:GetTemplate("button", "DETAILS_PLUGIN_BUTTON_TEMPLATE"))
weakauras_newgroup_button:SetWidth(100)
weakauras_newgroup_button:SetPoint("left", weakauras_newgroup_textentry, "right", 2, 0)
@@ -2580,19 +2580,19 @@ function _detalhes:OpenAuraPanel (spellid, spellname, spellicon, encounterid, tr
if (addon == "WA") then
_detalhes:CreateWeakAura (aura_type_value, spellid, use_spellId, spellname, name, icon, target, stacksize, sound, chat, icon_text, icon_glow, eid, folder, iconsize, f.other_values, incombat, iscooldown)
else
_detalhes:Msg ("No Aura Addon selected. Addons currently supported: WeakAuras 2.")
_detalhes:Msg("No Aura Addon selected. Addons currently supported: WeakAuras 2.")
end
f:Hide()
end
local create_button = fw:CreateButton (f, create_func, 106, 20, L["STRING_CREATEAURA"])
create_button:SetTemplate (slider_template)
create_button:SetTemplate (_detalhes.gump:GetTemplate ("button", "DETAILS_PLUGIN_BUTTON_TEMPLATE"))
local create_button = fw:CreateButton(f, create_func, 106, 20, L["STRING_CREATEAURA"])
create_button:SetTemplate(slider_template)
create_button:SetTemplate(_detalhes.gump:GetTemplate("button", "DETAILS_PLUGIN_BUTTON_TEMPLATE"))
create_button:SetWidth(160)
local cancel_button = fw:CreateButton (f, function() name_textentry:ClearFocus(); f:Hide() end, 106, 20, "Cancel")
cancel_button:SetTemplate (_detalhes.gump:GetTemplate ("button", "DETAILS_PLUGIN_BUTTON_TEMPLATE"))
local cancel_button = fw:CreateButton(f, function() name_textentry:ClearFocus(); f:Hide() end, 106, 20, "Cancel")
cancel_button:SetTemplate(_detalhes.gump:GetTemplate("button", "DETAILS_PLUGIN_BUTTON_TEMPLATE"))
cancel_button:SetWidth(160)
@@ -2762,7 +2762,7 @@ function _detalhes:OpenAuraPanel (spellid, spellname, spellicon, encounterid, tr
DetailsAuraPanel.AuraText:SetText(DetailsAuraPanel.other_values.text or "")
DetailsAuraPanel.SaySomething:SetText("")
if (triggertype and type (triggertype) == "number") then
if (triggertype and type(triggertype) == "number") then
DetailsAuraPanel.AuraOnDropdown:Select(triggertype, true)
DetailsAuraPanel.SetTriggerState (DetailsAuraPanel.TriggerList [triggertype].value) --passed by index not by the trigger ID
else
@@ -2770,7 +2770,7 @@ function _detalhes:OpenAuraPanel (spellid, spellname, spellicon, encounterid, tr
DetailsAuraPanel.SetTriggerState (1)
end
if (auratype and type (auratype) == "number") then
if (auratype and type(auratype) == "number") then
DetailsAuraPanel.AuraTypeDropdown:Select(auratype, true)
DetailsAuraPanel.OnSelectAuraType (nil, nil, auratype)
else
+61 -61
View File
@@ -1,5 +1,5 @@
local _detalhes = _G._detalhes
local Loc = LibStub ("AceLocale-3.0"):GetLocale ( "Details" )
local Loc = LibStub("AceLocale-3.0"):GetLocale ( "Details" )
local SharedMedia = LibStub:GetLibrary("LibSharedMedia-3.0")
local g = _detalhes.gump
@@ -24,7 +24,7 @@ function _detalhes:OpenWelcomeWindow()
window:SetBackdropColor(0, 0, 0, 0.75)
window:SetWidth(612)
window:SetHeight(315)
window:SetMovable (true)
window:SetMovable(true)
window:SetScript("OnMouseDown", function() window:StartMoving() end)
window:SetScript("OnMouseUp", function() window:StopMovingOrSizing() end)
window:SetScript("OnHide", function()
@@ -44,7 +44,7 @@ function _detalhes:OpenWelcomeWindow()
rodape_bg:SetPoint("bottomright", window, "bottomright", -11, 12)
rodape_bg:SetTexture([[Interface\Tooltips\UI-Tooltip-Background]])
rodape_bg:SetHeight(25)
rodape_bg:SetVertexColor (0, 0, 0, 1)
rodape_bg:SetVertexColor(0, 0, 0, 1)
local logotipo = window:CreateTexture(nil, "overlay")
logotipo:SetPoint("topleft", window, "topleft", 16, -20)
@@ -57,12 +57,12 @@ function _detalhes:OpenWelcomeWindow()
cancel:SetWidth(22)
cancel:SetHeight(22)
cancel:SetPoint("bottomleft", window, "bottomleft", 12, 14)
cancel:SetFrameLevel (window:GetFrameLevel()+1)
cancel:SetFrameLevel(window:GetFrameLevel()+1)
cancel:SetPushedTexture([[Interface\Buttons\UI-GroupLoot-Pass-Down]])
cancel:SetHighlightTexture([[Interface\Buttons\UI-GROUPLOOT-PASS-HIGHLIGHT]])
cancel:SetNormalTexture([[Interface\Buttons\UI-GroupLoot-Pass-Up]])
cancel:SetScript("OnClick", function() window:Hide() end)
cancel:GetNormalTexture():SetDesaturated (true)
cancel:GetNormalTexture():SetDesaturated(true)
cancel:Disable()
local cancelText = cancel:CreateFontString (nil, "overlay", "GameFontNormal")
@@ -74,7 +74,7 @@ function _detalhes:OpenWelcomeWindow()
forward:SetWidth(26)
forward:SetHeight(26)
forward:SetPoint("bottomright", window, "bottomright", -14, 13)
forward:SetFrameLevel (window:GetFrameLevel()+1)
forward:SetFrameLevel(window:GetFrameLevel()+1)
forward:SetPushedTexture([[Interface\Buttons\UI-SpellbookIcon-NextPage-Down]])
forward:SetHighlightTexture([[Interface\Buttons\UI-SpellbookIcon-NextPage-Up]])
forward:SetNormalTexture([[Interface\Buttons\UI-SpellbookIcon-NextPage-Up]])
@@ -133,7 +133,7 @@ function _detalhes:OpenWelcomeWindow()
instance.baseframe:SetPoint("left", DetailsWelcomeWindow, "right", 10, 0)
DetailsWelcomeWindow.SetLocTimer = nil
end
DetailsWelcomeWindow.SetLocTimer = _detalhes:ScheduleTimer ("WelcomeSetLoc", 12)
DetailsWelcomeWindow.SetLocTimer = _detalhes:ScheduleTimer("WelcomeSetLoc", 12)
--/script local f=CreateFrame("frame");local g=false;f:SetScript("OnUpdate",function(s,e)if not g then local r=math.random for i=1,2500000 do local a=r(1,1000000);a=a+1 end g=true else print(string.format("cpu: %.3f",e));f:SetScript("OnUpdate",nil)end end)
@@ -151,7 +151,7 @@ function _detalhes:OpenWelcomeWindow()
got = true
elseif (not InCombatLockdown()) then
--print ("process time:", elapsed)
--print("process time:", elapsed)
if (elapsed < 0.295) then
_detalhes.use_row_animations = true
@@ -183,7 +183,7 @@ function _detalhes:OpenWelcomeWindow()
end
--deprecated
--_detalhes:ScheduleTimer ("CalcCpuPower", 10)
--_detalhes:ScheduleTimer("CalcCpuPower", 10)
--detect ElvUI
--[=[ --deprecated
@@ -202,7 +202,7 @@ function _detalhes:OpenWelcomeWindow()
for key, value in pairs(instance) do
if (_detalhes.instance_defaults [key] ~= nil) then
if (type(value) == "table") then
savedObject [key] = Details.CopyTable (value)
savedObject [key] = Details.CopyTable(value)
else
savedObject [key] = value
end
@@ -241,7 +241,7 @@ local window_openned_at = time()
angel:SetTexCoord (0.162109375, 0.591796875, 0, 1)
angel:SetWidth(442)
angel:SetHeight(256)
angel:SetAlpha (.2)
angel:SetAlpha(.2)
local texto1 = window:CreateFontString (nil, "overlay", "GameFontNormal")
texto1:SetPoint("topleft", window, "topleft", 13, -220)
@@ -262,7 +262,7 @@ local window_openned_at = time()
bg55:SetPoint("bottomright", window, "bottomright", -10, 10)
bg55:SetHeight(125*3)
bg55:SetWidth(89*3)
bg55:SetAlpha (.05)
bg55:SetAlpha(.05)
bg55:SetTexCoord (1, 0, 0, 1)
local texto55 = window:CreateFontString (nil, "overlay", "GameFontNormal")
@@ -320,7 +320,7 @@ local window_openned_at = time()
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:SetTemplate(g:GetTemplate("dropdown", "OPTIONS_DROPDOWN_TEMPLATE"))
skin_dropdown.tooltip = Loc ["STRING_WELCOME_58"]
local skin_label = g:NewLabel(window, _, "$parentSkinLabel", "skinLabel", Loc ["STRING_OPTIONS_INSTANCE_SKIN"] .. ":", "GameFontNormal")
@@ -426,7 +426,7 @@ local window_openned_at = time()
g:NewSwitch (window, _, "$parentLatinAlphabetCheckBox", "LatinAlphabetCheckBox", 20, 20, _, _, true)
window.LatinAlphabetCheckBox:SetAsCheckBox()
window.LatinAlphabetCheckBox:SetFixedParameter(1)
window.LatinAlphabetCheckBox:SetTemplate (g:GetTemplate ("switch", "OPTIONS_CHECKBOX_TEMPLATE"))
window.LatinAlphabetCheckBox:SetTemplate(g:GetTemplate("switch", "OPTIONS_CHECKBOX_TEMPLATE"))
window.LatinAlphabetCheckBox.OnSwitch = onSelectAlphabet
window.LatinAlphabetLabel:SetPoint("left", window.LatinAlphabetCheckBox, "right", 2, 0)
@@ -438,7 +438,7 @@ local window_openned_at = time()
g:NewSwitch (window, _, "$parentCyrillicAlphabetCheckBox", "CyrillicAlphabetCheckBox", 20, 20, _, _, false)
window.CyrillicAlphabetCheckBox:SetAsCheckBox()
window.CyrillicAlphabetCheckBox:SetFixedParameter(2)
window.CyrillicAlphabetCheckBox:SetTemplate (g:GetTemplate ("switch", "OPTIONS_CHECKBOX_TEMPLATE"))
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)
@@ -449,7 +449,7 @@ local window_openned_at = time()
g:NewSwitch (window, _, "$parentChinaCheckBox", "ChinaCheckBox", 20, 20, _, _, false)
window.ChinaCheckBox:SetAsCheckBox()
window.ChinaCheckBox:SetFixedParameter(3)
window.ChinaCheckBox:SetTemplate (g:GetTemplate ("switch", "OPTIONS_CHECKBOX_TEMPLATE"))
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)
@@ -460,7 +460,7 @@ local window_openned_at = time()
g:NewSwitch (window, _, "$parentKoreanCheckBox", "KoreanCheckBox", 20, 20, _, _, false)
window.KoreanCheckBox:SetAsCheckBox()
window.KoreanCheckBox:SetFixedParameter(4)
window.KoreanCheckBox:SetTemplate (g:GetTemplate ("switch", "OPTIONS_CHECKBOX_TEMPLATE"))
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)
@@ -471,7 +471,7 @@ local window_openned_at = time()
g:NewSwitch (window, _, "$parentTaiwanCheckBox", "TaiwanCheckBox", 20, 20, _, _, false)
window.TaiwanCheckBox:SetAsCheckBox()
window.TaiwanCheckBox:SetFixedParameter(5)
window.TaiwanCheckBox:SetTemplate (g:GetTemplate ("switch", "OPTIONS_CHECKBOX_TEMPLATE"))
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)
@@ -499,8 +499,8 @@ local window_openned_at = time()
self.MyObject:Disable()
end
local create_window_button = g:CreateButton (window, new_window, buttonWidth, 20, Loc["STRING_WELCOME_79"])
create_window_button:SetTemplate (g:GetTemplate ("dropdown", "OPTIONS_DROPDOWN_TEMPLATE"))
local create_window_button = g:CreateButton(window, new_window, buttonWidth, 20, Loc["STRING_WELCOME_79"])
create_window_button:SetTemplate(g:GetTemplate("dropdown", "OPTIONS_DROPDOWN_TEMPLATE"))
create_window_button:SetIcon ([[Interface\FriendsFrame\UI-FriendsList-Large-Up]], nil, nil, nil, {5/32, 26/32, 6/32, 26/32}, nil, 4, 2)
create_window_button:SetPoint("topright", window, "topright", -100, -137)
@@ -514,7 +514,7 @@ local window_openned_at = time()
local instance = window.editing_window
if (instance.menu_alpha.enabled and a ~= instance.color[4]) then
_detalhes:Msg (Loc ["STRING_OPTIONS_MENU_ALPHAWARNING"])
_detalhes:Msg(Loc ["STRING_OPTIONS_MENU_ALPHAWARNING"])
instance:InstanceColor (r, g, b, instance.menu_alpha.onleave, nil, true)
if (_detalhes.options_group_edit) then
@@ -545,12 +545,12 @@ local window_openned_at = time()
local change_color = function()
window.editing_window = _detalhes:GetInstance(1)
local r, g, b, a = unpack (window.editing_window.color)
local r, g, b, a = unpack(window.editing_window.color)
_detalhes.gump:ColorPick (window, r, g, b, a, windowcolor_callback)
end
local window_color = g:CreateButton (window, change_color, buttonWidth, 20, Loc ["STRING_OPTIONS_CHANGECOLOR"])
window_color:SetTemplate (g:GetTemplate ("dropdown", "OPTIONS_DROPDOWN_TEMPLATE"))
local window_color = g:CreateButton(window, change_color, buttonWidth, 20, Loc ["STRING_OPTIONS_CHANGECOLOR"])
window_color:SetTemplate(g:GetTemplate("dropdown", "OPTIONS_DROPDOWN_TEMPLATE"))
window_color:SetPoint("topleft", create_window_button, "bottomleft", 0, padding)
window_color:SetIcon ([[Interface\AddOns\Details\images\icons]], 14, 14, nil, {434/512, 466/512, 277/512, 307/512}, nil, 4, 2)
@@ -560,7 +560,7 @@ local window_openned_at = time()
--
g:NewSlider (window, _, "$parentBarHeightSpeed", "BarHeightSlider", 160, 20, 8, 24, 1, 14) --parent, container, name, member, w, h, min, max, step, defaultv
window.BarHeightSlider:SetPoint("left", window.BarHeightLabel, "right", 2, 0)
window.BarHeightSlider:SetTemplate (g:GetTemplate ("slider", "OPTIONS_SLIDER_TEMPLATE"))
window.BarHeightSlider:SetTemplate(g:GetTemplate("slider", "OPTIONS_SLIDER_TEMPLATE"))
window.BarHeightSlider:SetHook("OnValueChange", function(self, _, amount)
local instance1 = Details:GetInstance(1)
@@ -580,7 +580,7 @@ local window_openned_at = time()
--
g:NewSlider (window, _, "$parentTextSizeSpeed", "TextSizeSlider", 160, 20, 10, 20, 1, 14) --parent, container, name, member, w, h, min, max, step, defaultv
window.TextSizeSlider:SetPoint("left", window.TextSizeLabel, "right", 2, 0)
window.TextSizeSlider:SetTemplate (g:GetTemplate ("slider", "OPTIONS_SLIDER_TEMPLATE"))
window.TextSizeSlider:SetTemplate(g:GetTemplate("slider", "OPTIONS_SLIDER_TEMPLATE"))
window.TextSizeSlider:SetHook("OnValueChange", function(self, _, amount)
local instance1 = Details:GetInstance(1)
@@ -619,7 +619,7 @@ local window_openned_at = time()
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:SetTemplate(g:GetTemplate("dropdown", "OPTIONS_DROPDOWN_TEMPLATE"))
font_dropdown.tooltip = Loc ["STRING_WELCOME_58"]
local font_label = g:NewLabel(window, _, "$parentFontLabel", "FontLabel", Loc ["STRING_OPTIONS_TEXT_FONT"], "GameFontNormal")
@@ -631,7 +631,7 @@ local window_openned_at = time()
g:NewSwitch (window, _, "$parentShowPercentCheckBox", "ShowPercentCheckBox", 20, 20, _, _, false)
window.ShowPercentCheckBox:SetAsCheckBox()
window.ShowPercentCheckBox:SetFixedParameter(1)
window.ShowPercentCheckBox:SetTemplate (g:GetTemplate ("switch", "OPTIONS_CHECKBOX_TEMPLATE"))
window.ShowPercentCheckBox:SetTemplate(g:GetTemplate("switch", "OPTIONS_CHECKBOX_TEMPLATE"))
window.ShowPercentCheckBox.OnSwitch = function(self, fixedParameter, value)
local instance1 = Details:GetInstance(1)
@@ -669,7 +669,7 @@ local window_openned_at = time()
end
if (DetailsWelcomeWindow.SetLocTimer) then
_detalhes:CancelTimer (DetailsWelcomeWindow.SetLocTimer)
_detalhes:CancelTimer(DetailsWelcomeWindow.SetLocTimer)
DetailsWelcomeWindow.SetLocTimer = nil
_detalhes:WelcomeSetLoc()
end
@@ -696,7 +696,7 @@ local window_openned_at = time()
numeral_image:SetPoint("bottomright", window, "bottomright", -10, 10)
numeral_image:SetHeight(125*3)--125
numeral_image:SetWidth(89*3)--82
numeral_image:SetAlpha (.05)
numeral_image:SetAlpha(.05)
numeral_image:SetTexCoord (1, 0, 0, 1)
g:NewLabel(window, _, "$parentChangeMindNumeralLabel", "changemindNumeralLabel", Loc ["STRING_WELCOME_2"], "GameFontNormal", 9, "orange")
@@ -713,7 +713,7 @@ local window_openned_at = time()
local WesternNumbersCheckbox = g:NewSwitch (window, _, "WesternNumbersCheckbox", "WesternNumbersCheckbox", 20, 20, _, _, true)
WesternNumbersCheckbox:SetAsCheckBox()
WesternNumbersCheckbox:SetFixedParameter(1)
WesternNumbersCheckbox:SetTemplate (g:GetTemplate ("switch", "OPTIONS_CHECKBOX_TEMPLATE"))
WesternNumbersCheckbox:SetTemplate(g:GetTemplate("switch", "OPTIONS_CHECKBOX_TEMPLATE"))
WesternNumbersCheckbox:SetPoint("topleft", window, "topleft", 40, -130)
window.WesternNumbersLabel:SetPoint("left", WesternNumbersCheckbox, "right", 2, 0)
@@ -722,7 +722,7 @@ local window_openned_at = time()
local AsianNumbersCheckbox = g:NewSwitch (window, _, "AsianNumbersCheckbox", "AsianNumbersCheckbox", 20, 20, _, _, true)
AsianNumbersCheckbox:SetAsCheckBox()
AsianNumbersCheckbox:SetFixedParameter(2)
AsianNumbersCheckbox:SetTemplate (g:GetTemplate ("switch", "OPTIONS_CHECKBOX_TEMPLATE"))
AsianNumbersCheckbox:SetTemplate(g:GetTemplate("switch", "OPTIONS_CHECKBOX_TEMPLATE"))
AsianNumbersCheckbox:SetPoint("topleft", window, "topleft", 40, -200)
window.AsianNumbersLabel:SetPoint("left", AsianNumbersCheckbox, "right", 2, 0)
@@ -815,7 +815,7 @@ local window_openned_at = time()
ampulheta:SetPoint("bottomright", window, "bottomright", -10, 10)
ampulheta:SetHeight(125*3)--125
ampulheta:SetWidth(89*3)--82
ampulheta:SetAlpha (.05)
ampulheta:SetAlpha(.05)
ampulheta:SetTexCoord (1, 0, 0, 1)
g:NewLabel(window, _, "$parentChangeMind2Label", "changemind2Label", Loc ["STRING_WELCOME_2"], "GameFontNormal", 9, "orange")
@@ -832,7 +832,7 @@ local window_openned_at = time()
local chronometer = g:NewSwitch (window, _, "WelcomeWindowChronometer", "WelcomeWindowChronometer", 20, 20, _, _, true)
chronometer:SetAsCheckBox()
chronometer:SetFixedParameter(1)
chronometer:SetTemplate (g:GetTemplate ("switch", "OPTIONS_CHECKBOX_TEMPLATE"))
chronometer:SetTemplate(g:GetTemplate("switch", "OPTIONS_CHECKBOX_TEMPLATE"))
window.ChronometerLabel:SetPoint("left", chronometer, "right", 2, 0)
--continuouses checkbox
@@ -840,7 +840,7 @@ local window_openned_at = time()
local continuous = g:NewSwitch (window, _, "WelcomeWindowContinuous", "WelcomeWindowContinuous", 20, 20, _, _, true)
continuous:SetAsCheckBox()
continuous:SetFixedParameter(1)
continuous:SetTemplate (g:GetTemplate ("switch", "OPTIONS_CHECKBOX_TEMPLATE"))
continuous:SetTemplate(g:GetTemplate("switch", "OPTIONS_CHECKBOX_TEMPLATE"))
window.ContinuousLabel:SetPoint("left", continuous, "right", 2, 0)
--on clkich chronomoeter checkbox
@@ -915,7 +915,7 @@ local window_openned_at = time()
pleasewait:Hide()
pleasewait:SetText("")
forward:Enable()
_detalhes:CancelTimer (window.free_frame3_schedule)
_detalhes:CancelTimer(window.free_frame3_schedule)
window.free_frame3_schedule = nil
end
end
@@ -923,7 +923,7 @@ local window_openned_at = time()
if (window_openned_at-10 > time()) then
forward:Disable()
if (window.free_frame3_schedule) then
_detalhes:CancelTimer (window.free_frame3_schedule)
_detalhes:CancelTimer(window.free_frame3_schedule)
window.free_frame3_schedule = nil
end
window.free_frame3_schedule = _detalhes:ScheduleRepeatingTimer ("FreeTutorialFrame3", 1)
@@ -931,7 +931,7 @@ local window_openned_at = time()
end)
free_frame3:SetScript("OnHide", function()
if (window.free_frame3_schedule) then
_detalhes:CancelTimer (window.free_frame3_schedule)
_detalhes:CancelTimer(window.free_frame3_schedule)
window.free_frame3_schedule = nil
pleasewait:SetText("")
pleasewait:Hide()
@@ -955,7 +955,7 @@ local window_openned_at = time()
bg:SetPoint("bottomright", window, "bottomright", -10, 10)
bg:SetHeight(125*3)--125
bg:SetWidth(89*3)--82
bg:SetAlpha (.05)
bg:SetAlpha(.05)
bg:SetTexCoord (1, 0, 0, 1)
g:NewLabel(window, _, "$parentChangeMind4Label", "changemind4Label", Loc ["STRING_WELCOME_11"], "GameFontNormal", 9, "orange")
@@ -992,7 +992,7 @@ local window_openned_at = time()
g:NewSlider (window, _, "$parentSliderUpdateSpeed", "updatespeedSlider", 160, 20, 0.050, 3, 0.050, _detalhes.update_speed, true) --parent, container, name, member, w, h, min, max, step, defaultv
window.updatespeedSlider:SetPoint("left", window.updatespeedLabel, "right", 2, 0)
window.updatespeedSlider:SetTemplate (g:GetTemplate ("slider", "OPTIONS_SLIDER_TEMPLATE"))
window.updatespeedSlider:SetTemplate(g:GetTemplate("slider", "OPTIONS_SLIDER_TEMPLATE"))
window.updatespeedSlider:SetThumbSize (50)
window.updatespeedSlider.useDecimals = true
local updateColor = function(slider, value)
@@ -1027,7 +1027,7 @@ local window_openned_at = time()
_detalhes:SetUseAnimations (value)
end
window.animateSlider:SetTemplate (g:GetTemplate ("switch", "OPTIONS_CHECKBOX_TEMPLATE"))
window.animateSlider:SetTemplate(g:GetTemplate("switch", "OPTIONS_CHECKBOX_TEMPLATE"))
window.animateSlider:SetAsCheckBox()
--window.animateSlider.tooltip = Loc ["STRING_WELCOME_17"] --removed
@@ -1042,7 +1042,7 @@ local window_openned_at = time()
_detalhes:GetInstance(1):FastPSUpdate (value)
end
window.DpsHpsSlider:SetTemplate (g:GetTemplate ("switch", "OPTIONS_CHECKBOX_TEMPLATE"))
window.DpsHpsSlider:SetTemplate(g:GetTemplate("switch", "OPTIONS_CHECKBOX_TEMPLATE"))
window.DpsHpsSlider:SetAsCheckBox()
--window.DpsHpsSlider.tooltip = Loc ["STRING_WELCOME_64"]
@@ -1054,7 +1054,7 @@ local window_openned_at = time()
-- g:NewSlider (window, _, "$parentSlider", "segmentsSlider", 120, 20, 1, 25, 1, _detalhes.segments_amount) -- min, max, step, defaultv
-- window.segmentsSlider:SetPoint("left", window.segmentsLabel, "right", 2, 0)
-- window.segmentsSlider:SetHook("OnValueChange", function(self, _, amount) --slider, fixedValue, sliderValue
-- _detalhes.segments_amount = math.floor (amount)
-- _detalhes.segments_amount = math.floor(amount)
-- end)
-- window.segmentsSlider.tooltip = Loc ["STRING_WELCOME_22"]
@@ -1064,14 +1064,14 @@ local window_openned_at = time()
mech_icon:SetPoint("topright", window, "topright", -15, -15)
mech_icon:SetWidth(128*0.9)
mech_icon:SetHeight(128*0.9)
mech_icon:SetAlpha (0.8)
mech_icon:SetAlpha(0.8)
local mech_icon2 = window:CreateTexture(nil, "overlay")
mech_icon2:SetTexture([[Interface\Vehicles\UI-Vehicles-Trim-Alliance]])
mech_icon2:SetPoint("topright", window, "topright", -10, -151)
mech_icon2:SetWidth(128*1.0)
mech_icon2:SetHeight(128*0.6)
mech_icon2:SetAlpha (0.6)
mech_icon2:SetAlpha(0.6)
mech_icon2:SetTexCoord (0, 1, 40/128, 1)
mech_icon2:SetDrawLayer ("overlay", 2)
@@ -1122,7 +1122,7 @@ local window_openned_at = time()
bg6:SetPoint("bottomright", window, "bottomright", -10, 10)
bg6:SetHeight(125*3)--125
bg6:SetWidth(89*3)--82
bg6:SetAlpha (.1)
bg6:SetAlpha(.1)
bg6:SetTexCoord (1, 0, 0, 1)
local texto5 = window:CreateFontString (nil, "overlay", "GameFontNormal")
@@ -1152,16 +1152,16 @@ local window_openned_at = time()
stretch_frame_alert:SetScript("OnShow", function()
local instance = _detalhes:GetInstance(1)
_detalhes.OnEnterMainWindow(instance)
instance.baseframe.button_stretch:SetAlpha (1)
instance.baseframe.button_stretch:SetAlpha(1)
frame_alert.alert:SetPoint("topleft", instance.baseframe.button_stretch, "topleft", -20, 6)
frame_alert.alert:SetPoint("bottomright", instance.baseframe.button_stretch, "bottomright", 20, -14)
frame_alert.alert.animOut:Stop()
frame_alert.alert.animIn:Play()
if (_detalhes.stopwelcomealert) then
_detalhes:CancelTimer (_detalhes.stopwelcomealert)
_detalhes:CancelTimer(_detalhes.stopwelcomealert)
end
_detalhes.stopwelcomealert = _detalhes:ScheduleTimer ("StopPlayStretchAlert", 30)
_detalhes.stopwelcomealert = _detalhes:ScheduleTimer("StopPlayStretchAlert", 30)
end)
@@ -1180,7 +1180,7 @@ local window_openned_at = time()
bg6:SetPoint("bottomright", window, "bottomright", -10, 10)
bg6:SetHeight(125*3)--125
bg6:SetWidth(89*3)--82
bg6:SetAlpha (.1)
bg6:SetAlpha(.1)
bg6:SetTexCoord (1, 0, 0, 1)
local texto6 = window:CreateFontString (nil, "overlay", "GameFontNormal")
@@ -1216,9 +1216,9 @@ local window_openned_at = time()
frame_alert.alert.animOut:Stop()
frame_alert.alert.animIn:Play()
if (_detalhes.stopwelcomealert) then
_detalhes:CancelTimer (_detalhes.stopwelcomealert)
_detalhes:CancelTimer(_detalhes.stopwelcomealert)
end
_detalhes.stopwelcomealert = _detalhes:ScheduleTimer ("StopPlayStretchAlert", 30)
_detalhes.stopwelcomealert = _detalhes:ScheduleTimer("StopPlayStretchAlert", 30)
end)
pages [#pages+1] = {bg6, texto6, instance_button_image, texto_instance_button, instance_frame_alert}
@@ -1236,7 +1236,7 @@ local window_openned_at = time()
bg7:SetPoint("bottomright", window, "bottomright", -10, 10)
bg7:SetHeight(125*3)--125
bg7:SetWidth(89*3)--82
bg7:SetAlpha (.1)
bg7:SetAlpha(.1)
bg7:SetTexCoord (1, 0, 0, 1)
local texto7 = window:CreateFontString (nil, "overlay", "GameFontNormal")
@@ -1305,7 +1305,7 @@ local window_openned_at = time()
bg77:SetPoint("bottomright", window, "bottomright", -10, 10)
bg77:SetHeight(125*3)--125
bg77:SetWidth(89*3)--82
bg77:SetAlpha (.1)
bg77:SetAlpha(.1)
bg77:SetTexCoord (1, 0, 0, 1)
local texto77 = window:CreateFontString (nil, "overlay", "GameFontNormal")
@@ -1351,7 +1351,7 @@ local window_openned_at = time()
bg88:SetPoint("bottomright", window, "bottomright", -10, 10)
bg88:SetHeight(125*3)--125
bg88:SetWidth(89*3)--82
bg88:SetAlpha (.1)
bg88:SetAlpha(.1)
bg88:SetTexCoord (1, 0, 0, 1)
local texto88 = window:CreateFontString (nil, "overlay", "GameFontNormal")
@@ -1380,7 +1380,7 @@ local window_openned_at = time()
_detalhes.tabela_historico:resetar()
created_test_bars = 0
local current_combat = _detalhes:GetCombat ("current")
local current_combat = _detalhes:GetCombat("current")
local actors_classes = CLASS_SORT_ORDER
local total_damage = 0
local total_heal = 0
@@ -1450,9 +1450,9 @@ local window_openned_at = time()
frame_alert.alert.animOut:Stop()
frame_alert.alert.animIn:Play()
if (_detalhes.stopwelcomealert) then
_detalhes:CancelTimer (_detalhes.stopwelcomealert)
_detalhes:CancelTimer(_detalhes.stopwelcomealert)
end
_detalhes.stopwelcomealert = _detalhes:ScheduleTimer ("StopPlayStretchAlert", 2)
_detalhes.stopwelcomealert = _detalhes:ScheduleTimer("StopPlayStretchAlert", 2)
end)
@@ -1474,7 +1474,7 @@ local window_openned_at = time()
bg11:SetPoint("bottomright", window, "bottomright", -10, 10)
bg11:SetHeight(125*3)--125
bg11:SetWidth(89*3)--82
bg11:SetAlpha (.1)
bg11:SetAlpha(.1)
bg11:SetTexCoord (1, 0, 0, 1)
local texto11 = window:CreateFontString (nil, "overlay", "GameFontNormal")
@@ -1513,7 +1513,7 @@ local window_openned_at = time()
bg8:SetPoint("bottomright", window, "bottomright", -10, 10)
bg8:SetHeight(125*3)--125
bg8:SetWidth(89*3)--82
bg8:SetAlpha (.1)
bg8:SetAlpha(.1)
bg8:SetTexCoord (1, 0, 0, 1)
local texto8 = window:CreateFontString (nil, "overlay", "GameFontNormal")
@@ -1535,7 +1535,7 @@ local window_openned_at = time()
final_frame:Hide()
final_frame:SetScript("OnShow", function()
cancel:Enable()
cancel:GetNormalTexture():SetDesaturated (false)
cancel:GetNormalTexture():SetDesaturated(false)
end)
pages [#pages+1] = {bg8, texto8, texto, final_frame}