- Added option to select the title bar icons
This commit is contained in:
@@ -4,8 +4,8 @@
|
||||
_ = nil
|
||||
_detalhes = LibStub("AceAddon-3.0"):NewAddon("_detalhes", "AceTimer-3.0", "AceComm-3.0", "AceSerializer-3.0", "NickTag-1.0")
|
||||
|
||||
_detalhes.build_counter = 7935
|
||||
_detalhes.alpha_build_counter = 7935 --if this is higher than the regular counter, use it instead
|
||||
_detalhes.build_counter = 7938
|
||||
_detalhes.alpha_build_counter = 7938 --if this is higher than the regular counter, use it instead
|
||||
_detalhes.game_version = "v9.0.1"
|
||||
_detalhes.userversion = "v9.0.1." .. _detalhes.build_counter
|
||||
_detalhes.realversion = 143 --core version, this is used to check API version for scripts and plugins (see alias below)
|
||||
@@ -28,6 +28,8 @@ do
|
||||
local Loc = _G.LibStub("AceLocale-3.0"):GetLocale( "Details" )
|
||||
|
||||
local news = {
|
||||
{"v9.0.1.7938.142", "October 29th, 2020"},
|
||||
"Added option to select the icon buttons in the title bar.",
|
||||
{"v9.0.1.7739.142", "August 18th, 2020"},
|
||||
"More development on the new plugin Cast Timeline.",
|
||||
"More development on Details! Scroll Damage.",
|
||||
|
||||
@@ -1896,20 +1896,37 @@ do
|
||||
return fontTable
|
||||
end
|
||||
|
||||
--> attribute text font
|
||||
local on_select_attribute_font = function (self, instance, fontName)
|
||||
editInstanceSetting(currentInstance, "AttributeMenu", nil, nil, nil, fontName)
|
||||
afterUpdate()
|
||||
end
|
||||
|
||||
local build_font_menu = function()
|
||||
local fonts = {}
|
||||
for name, fontPath in pairs (SharedMedia:HashTable ("font")) do
|
||||
fonts [#fonts+1] = {value = name, label = name, icon = font_select_icon, texcoord = font_select_texcoord, onclick = on_select_attribute_font, font = fontPath, descfont = name, desc = "Our thoughts strayed constantly\nAnd without boundary\nThe ringing of the division bell had began."}
|
||||
end
|
||||
table.sort (fonts, function (t1, t2) return t1.label < t2.label end)
|
||||
return fonts
|
||||
--> attribute text font
|
||||
local on_select_attribute_font = function (self, instance, fontName)
|
||||
editInstanceSetting(currentInstance, "AttributeMenu", nil, nil, nil, fontName)
|
||||
afterUpdate()
|
||||
end
|
||||
|
||||
local build_font_menu = function()
|
||||
local fonts = {}
|
||||
for name, fontPath in pairs (SharedMedia:HashTable ("font")) do
|
||||
fonts [#fonts+1] = {value = name, label = name, icon = font_select_icon, texcoord = font_select_texcoord, onclick = on_select_attribute_font, font = fontPath, descfont = name, desc = "Our thoughts strayed constantly\nAnd without boundary\nThe ringing of the division bell had began."}
|
||||
end
|
||||
table.sort (fonts, function (t1, t2) return t1.label < t2.label end)
|
||||
return fonts
|
||||
end
|
||||
|
||||
--> icon set menu
|
||||
local on_select_icon_set = function(self, instance, texturePath)
|
||||
editInstanceSetting(currentInstance, "toolbar_icon_file", texturePath)
|
||||
editInstanceSetting(currentInstance, "ChangeSkin")
|
||||
afterUpdate()
|
||||
end
|
||||
|
||||
local buildIconStyleMenu = function()
|
||||
local iconMenu = {
|
||||
{value = "Interface\\AddOns\\Details\\images\\toolbar_icons", label = "Set 1", icon = "Interface\\AddOns\\Details\\images\\toolbar_icons", texcoord = {0, 0.125, 0, 1}, onclick = on_select_icon_set},
|
||||
{value = "Interface\\AddOns\\Details\\images\\toolbar_icons_shadow", label = "Set 2", icon = "Interface\\AddOns\\Details\\images\\toolbar_icons_shadow", texcoord = {0, 0.125, 0, 1}, onclick = on_select_icon_set},
|
||||
{value = "Interface\\AddOns\\Details\\images\\toolbar_icons_2", label = "Set 3", icon = "Interface\\AddOns\\Details\\images\\toolbar_icons_2", texcoord = {0, 0.125, 0, 1}, onclick = on_select_icon_set},
|
||||
{value = "Interface\\AddOns\\Details\\images\\toolbar_icons_2_shadow", label = "Set 4", icon = "Interface\\AddOns\\Details\\images\\toolbar_icons_2_shadow", texcoord = {0, 0.125, 0, 1}, onclick = on_select_icon_set},
|
||||
}
|
||||
return iconMenu
|
||||
end
|
||||
|
||||
local buttonWidth = 25
|
||||
|
||||
@@ -2008,6 +2025,16 @@ do
|
||||
icontexcoords = {160/256, 192/256, 0, 1},
|
||||
},
|
||||
|
||||
{--icon set icon style
|
||||
type = "select",
|
||||
get = function() return currentInstance.toolbar_icon_file end,
|
||||
values = function()
|
||||
return buildIconStyleMenu()
|
||||
end,
|
||||
name = "Icon Set",
|
||||
desc = "Icon Set",
|
||||
},
|
||||
|
||||
{--title bar icons size
|
||||
type = "range",
|
||||
get = function() return currentInstance.menu_icons_size end,
|
||||
@@ -2065,17 +2092,6 @@ do
|
||||
desc = Loc ["STRING_OPTIONS_MENU_X_DESC"],
|
||||
},
|
||||
|
||||
{--icon shadows
|
||||
type = "toggle",
|
||||
get = function() return currentInstance.menu_icons.shadow end,
|
||||
set = function (self, fixedparam, value)
|
||||
editInstanceSetting(currentInstance, "ToolbarMenuSetButtonsOptions", nil, value)
|
||||
afterUpdate()
|
||||
end,
|
||||
name = Loc ["STRING_OPTIONS_MENUS_SHADOW"],
|
||||
desc = Loc ["STRING_OPTIONS_MENUS_SHADOW_DESC"],
|
||||
},
|
||||
|
||||
{--icons desaturated
|
||||
type = "toggle",
|
||||
get = function() return currentInstance.desaturated_menu end,
|
||||
|
||||
+1
-1
@@ -1793,7 +1793,7 @@ local _
|
||||
1, -- [3]
|
||||
1, -- [4]
|
||||
},
|
||||
["toolbar_icon_file"] = "Interface\\AddOns\\Details\\images\\toolbar_icons",
|
||||
["toolbar_icon_file"] = "Interface\\AddOns\\Details\\images\\toolbar_icons_2",
|
||||
["bars_sort_direction"] = 1,
|
||||
["fontstrings_width"] = 35,
|
||||
["tooltip"] = {
|
||||
|
||||
Binary file not shown.
Binary file not shown.
Reference in New Issue
Block a user