Round of Fixes

This commit is contained in:
Tercio Jose
2022-11-28 13:00:11 -03:00
parent 06faed2fb0
commit 8f6cfe4d69
6 changed files with 83 additions and 42 deletions
-4
View File
@@ -2,8 +2,4 @@
## Title: Lib: LibDFramework-1.0
## Notes: Base Framework for many Addons
#@no-lib-strip@
embeds.xml
#@end-no-lib-strip@
load.xml
+2 -2
View File
@@ -6,8 +6,8 @@
local addonName, Details222 = ...
local version, build, date, tocversion = GetBuildInfo()
_detalhes.build_counter = 10301
_detalhes.alpha_build_counter = 10301 --if this is higher than the regular counter, use it instead
_detalhes.build_counter = 10302
_detalhes.alpha_build_counter = 10302 --if this is higher than the regular counter, use it instead
_detalhes.dont_open_news = true
_detalhes.game_version = version
_detalhes.userversion = version .. " " .. _detalhes.build_counter
+5 -5
View File
@@ -1606,21 +1606,21 @@
GameCooltip:SetOption("SparkTexture", [[Interface\Buttons\WHITE8X8]])
GameCooltip:SetOption("SparkWidth", 1)
GameCooltip:SetOption("SparkHeight", 20)
GameCooltip:SetOption("SparkColor", "gray")
GameCooltip:SetOption("SparkColor", Details.tooltip.divisor_color)
GameCooltip:SetOption("SparkAlpha", 0.15)
GameCooltip:SetOption("SparkPositionXOffset", 5)
--GameCooltip:SetOption("SparkAlpha", 0.3)
--GameCooltip:SetOption("SparkPositionXOffset", -2)
value = value or 100
if (not side) then
local r, g, b, a = unpack(Details.tooltip.background)
GameCooltip:AddStatusBar (value, 1, r, g, b, a, useSpark, {value = 100, color = {.21, .21, .21, 0.8}, texture = [[Interface\AddOns\Details\images\bar_serenity]]})
local r, g, b, a = unpack(Details.tooltip.bar_color)
local rBG, gBG, bBG, aBG = unpack(Details.tooltip.background)
GameCooltip:AddStatusBar (value, 1, r, g, b, a, useSpark, {value = 100, color = {rBG, gBG, bBG, aBG}, texture = [[Interface\AddOns\Details\images\bar_serenity]]})
else
GameCooltip:AddStatusBar (value, 2, unpack(Details.tooltip.background))
GameCooltip:AddStatusBar (value, 2, unpack(Details.tooltip.bar_color))
end
end
+3 -3
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, 455, Loc ["STRING_OPTIONS_CLASSCOLOR_MODIFY"], "DetailsClassColorManager")
local panel = _G.DetailsClassColorManager
DF:ApplyStandardBackdrop(panel)
@@ -191,10 +191,10 @@ function Details:OpenClassColorsConfig()
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)
DetailsFramework:BuildMenu(panel, deathLogOptions, 5, -315, 700, true, options_text_template, options_dropdown_template, options_switch_template, true, options_slider_template, options_button_template)
local deathLogColorsLabel = DF:CreateLabel(panel, "Colors on Death Log:", 12, "yellow")
deathLogColorsLabel:SetPoint("topleft", panel, "topleft", 5, -265)
deathLogColorsLabel:SetPoint("topleft", panel, "topleft", 5, -295)
end
for class, button in pairs(_G.DetailsClassColorManager.buttons) do
+67 -24
View File
@@ -574,6 +574,9 @@ do
name = Loc ["STRING_OPTIONS_WC_CREATE"],
desc = Loc ["STRING_OPTIONS_WC_CREATE_DESC"],
},
{type = "blank"},
{--class colors
type = "execute",
func = function(self)
@@ -4259,6 +4262,32 @@ do
desc = Loc ["STRING_OPTIONS_TOOLTIPS_FONTSHADOW_DESC"],
},
{--text size
type = "range",
get = function() return _detalhes.tooltip.fontsize end,
set = function(self, fixedparam, value)
_detalhes.tooltip.fontsize = value
afterUpdate()
end,
min = 5,
max = 32,
step = 1,
name = Loc ["STRING_OPTIONS_TEXT_SIZE"],
desc = Loc ["STRING_OPTIONS_TEXT_SIZE_DESC"],
},
{--text font
type = "select",
get = function() return _detalhes.tooltip.fontface end,
values = function()
return buildTooltipFontOptions()
end,
name = Loc ["STRING_OPTIONS_TEXT_FONT"],
desc = Loc ["STRING_OPTIONS_TEXT_FONT_DESC"],
},
{type = "blank"},
{type = "label", get = function() return Loc["STRING_OPTIONS_TOOLTIPS_FONTCOLOR"] end},
{--text color left
@@ -4315,33 +4344,27 @@ do
desc = Loc ["STRING_OPTIONS_TOOLTIPS_ANCHORCOLOR"],
},
{--text size
type = "range",
get = function() return _detalhes.tooltip.fontsize end,
set = function(self, fixedparam, value)
_detalhes.tooltip.fontsize = value
afterUpdate()
end,
min = 5,
max = 32,
step = 1,
name = Loc ["STRING_OPTIONS_TEXT_SIZE"],
desc = Loc ["STRING_OPTIONS_TEXT_SIZE_DESC"],
},
{--text font
type = "select",
get = function() return _detalhes.tooltip.fontface end,
values = function()
return buildTooltipFontOptions()
end,
name = Loc ["STRING_OPTIONS_TEXT_FONT"],
desc = Loc ["STRING_OPTIONS_TEXT_FONT_DESC"],
},
{type = "blank"},
{type = "label", get = function() return Loc ["STRING_OPTIONS_MENU_ATTRIBUTESETTINGS_ANCHOR"] end, text_template = subSectionTitleTextTemplate},
{--bar color
type = "color",
get = function()
local r, g, b, a = unpack(_detalhes.tooltip.bar_color)
return {r, g, b, a}
end,
set = function(self, r, g, b, a)
local color = _detalhes.tooltip.bar_color
color[1] = r
color[2] = g
color[3] = b
color[4] = a
afterUpdate()
end,
name = "Bar Color",
desc = "Bar Color",
},
{--background color
type = "color",
get = function()
@@ -4360,6 +4383,26 @@ do
desc = Loc ["STRING_OPTIONS_TOOLTIPS_BACKGROUNDCOLOR"],
},
{--divisor color
type = "color",
get = function()
local r, g, b, a = unpack(_detalhes.tooltip.divisor_color)
return {r, g, b, a}
end,
set = function(self, r, g, b, a)
local color = _detalhes.tooltip.divisor_color
color[1] = r
color[2] = g
color[3] = b
color[4] = a
afterUpdate()
end,
name = "Divisor Color",
desc = "Divisor Color",
},
{type = "blank"},
{--show amount
type = "toggle",
get = function() return _detalhes.tooltip.show_amount end,
+6 -4
View File
@@ -853,9 +853,9 @@ local default_profile = {
--0.2000,
--0.4980,
--0.5764,
0.20000001788139,
0.57647061347961,
0.49803924560547,
0.2000,
0.5764,
0.4980,
},
},
@@ -1103,7 +1103,9 @@ local default_profile = {
fontcolor = {1, 1, 1, 1},
fontcolor_right = {1, 0.7, 0, 1}, --{1, 0.9254, 0.6078, 1}
fontshadow = false,
background = {0.1960, 0.1960, 0.1960, 0.8697},
bar_color = {0.3960, 0.3960, 0.3960, 0.8700},
background = {0.0941, 0.0941, 0.0941, 0.8},
divisor_color = {1, 1, 1, 1},
abbreviation = 2, -- 2 = ToK I Upper 5 = ToK I Lower -- was 8
maximize_method = 1,
show_amount = false,