Skip to content

Commit

Permalink
Base updates for 7.0/Legion - Lib update
Browse files Browse the repository at this point in the history
Updated Ace3 libs
  • Loading branch information
ShaunaGordon committed Aug 18, 2016
1 parent 2406157 commit a7becf0
Show file tree
Hide file tree
Showing 14 changed files with 156 additions and 106 deletions.
22 changes: 11 additions & 11 deletions Libs/AceConfig-3.0/AceConfigDialog-3.0/AceConfigDialog-3.0.lua
@@ -1,10 +1,10 @@
--- AceConfigDialog-3.0 generates AceGUI-3.0 based windows based on option tables.
-- @class file
-- @name AceConfigDialog-3.0
-- @release $Id: AceConfigDialog-3.0.lua 1113 2014-09-11 20:18:16Z nevcairiel $
-- @release $Id: AceConfigDialog-3.0.lua 1139 2016-07-03 07:43:51Z nevcairiel $

local LibStub = LibStub
local MAJOR, MINOR = "AceConfigDialog-3.0", 59
local MAJOR, MINOR = "AceConfigDialog-3.0", 61
local AceConfigDialog, oldminor = LibStub:NewLibrary(MAJOR, MINOR)

if not AceConfigDialog then return end
Expand Down Expand Up @@ -542,16 +542,16 @@ local function OptionOnMouseOver(widget, event)
if descStyle and descStyle ~= "tooltip" then return end
GameTooltip:SetText(name, 1, .82, 0, 1)
GameTooltip:SetText(name, 1, .82, 0, true)
if opt.type == "multiselect" then
GameTooltip:AddLine(user.text,0.5, 0.5, 0.8, 1)
GameTooltip:AddLine(user.text, 0.5, 0.5, 0.8, true)
end
if type(desc) == "string" then
GameTooltip:AddLine(desc, 1, 1, 1, 1)
GameTooltip:AddLine(desc, 1, 1, 1, true)
end
if type(usage) == "string" then
GameTooltip:AddLine("Usage: "..usage, NORMAL_FONT_COLOR.r, NORMAL_FONT_COLOR.g, NORMAL_FONT_COLOR.b, 1)
GameTooltip:AddLine("Usage: "..usage, NORMAL_FONT_COLOR.r, NORMAL_FONT_COLOR.g, NORMAL_FONT_COLOR.b, true)
end
GameTooltip:Show()
Expand Down Expand Up @@ -1092,7 +1092,7 @@ local function FeedOptions(appName, options,container,rootframe,path,group,inlin
local imageCoords = GetOptionsMemberValue("imageCoords",v, options, path, appName)
local image, width, height = GetOptionsMemberValue("image",v, options, path, appName)
if type(image) == "string" then
if type(image) == "string" or type(image) == "number" then
control = gui:Create("Icon")
if not width then
width = GetOptionsMemberValue("imageWidth",v, options, path, appName)
Expand Down Expand Up @@ -1154,7 +1154,7 @@ local function FeedOptions(appName, options,container,rootframe,path,group,inlin
local image = GetOptionsMemberValue("image", v, options, path, appName)
local imageCoords = GetOptionsMemberValue("imageCoords", v, options, path, appName)
if type(image) == "string" then
if type(image) == "string" or type(image) == "number" then
if type(imageCoords) == "table" then
control:SetImage(image, unpack(imageCoords))
else
Expand Down Expand Up @@ -1354,7 +1354,7 @@ local function FeedOptions(appName, options,container,rootframe,path,group,inlin
local imageCoords = GetOptionsMemberValue("imageCoords",v, options, path, appName)
local image, width, height = GetOptionsMemberValue("image",v, options, path, appName)
if type(image) == "string" then
if type(image) == "string" or type(image) == "number" then
if not width then
width = GetOptionsMemberValue("imageWidth",v, options, path, appName)
end
Expand Down Expand Up @@ -1448,10 +1448,10 @@ local function TreeOnButtonEnter(widget, event, uniquevalue, button)
GameTooltip:SetPoint("LEFT",button,"RIGHT")
end
GameTooltip:SetText(name, 1, .82, 0, 1)
GameTooltip:SetText(name, 1, .82, 0, true)
if type(desc) == "string" then
GameTooltip:AddLine(desc, 1, 1, 1, 1)
GameTooltip:AddLine(desc, 1, 1, 1, true)
end
GameTooltip:Show()
Expand Down
Expand Up @@ -8,8 +8,8 @@
-- :IterateOptionsTables() (and :GetOptionsTable() if only given one argument) return a function reference that the requesting config handling addon must call with valid "uiType", "uiName".
-- @class file
-- @name AceConfigRegistry-3.0
-- @release $Id: AceConfigRegistry-3.0.lua 1105 2013-12-08 22:11:58Z nevcairiel $
local MAJOR, MINOR = "AceConfigRegistry-3.0", 15
-- @release $Id: AceConfigRegistry-3.0.lua 1139 2016-07-03 07:43:51Z nevcairiel $
local MAJOR, MINOR = "AceConfigRegistry-3.0", 16
local AceConfigRegistry = LibStub:NewLibrary(MAJOR, MINOR)

if not AceConfigRegistry then return end
Expand Down Expand Up @@ -57,6 +57,7 @@ local istable={["table"]=true, _="table"}
local ismethodtable={["table"]=true,["string"]=true,["function"]=true, _="methodname, funcref or table"}
local optstring={["nil"]=true,["string"]=true, _="string"}
local optstringfunc={["nil"]=true,["string"]=true,["function"]=true, _="string or funcref"}
local optstringnumberfunc={["nil"]=true,["string"]=true,["number"]=true,["function"]=true, _="string, number or funcref"}
local optnumber={["nil"]=true,["number"]=true, _="number"}
local optmethod={["nil"]=true,["string"]=true,["function"]=true, _="methodname or funcref"}
local optmethodfalse={["nil"]=true,["string"]=true,["function"]=true,["boolean"]={[false]=true}, _="methodname, funcref or false"}
Expand All @@ -82,7 +83,7 @@ local basekeys={
dialogHidden=optmethodbool,
dropdownHidden=optmethodbool,
cmdHidden=optmethodbool,
icon=optstringfunc,
icon=optstringnumberfunc,
iconCoords=optmethodtable,
handler=opttable,
get=optmethodfalse,
Expand All @@ -95,7 +96,7 @@ local basekeys={
local typedkeys={
header={},
description={
image=optstringfunc,
image=optstringnumberfunc,
imageCoords=optmethodtable,
imageHeight=optnumber,
imageWidth=optnumber,
Expand All @@ -112,7 +113,7 @@ local typedkeys={
childGroups=optstring,
},
execute={
image=optstringfunc,
image=optstringnumberfunc,
imageCoords=optmethodtable,
imageHeight=optnumber,
imageWidth=optnumber,
Expand All @@ -127,7 +128,7 @@ local typedkeys={
},
toggle={
tristate=optbool,
image=optstringfunc,
image=optstringnumberfunc,
imageCoords=optmethodtable,
},
tristate={
Expand Down
9 changes: 5 additions & 4 deletions Libs/AceDB-3.0/AceDB-3.0.lua
Expand Up @@ -10,6 +10,7 @@
-- * **race** Race-specific data. All of the players characters of the same race share this database.
-- * **faction** Faction-specific data. All of the players characters of the same faction share this database.
-- * **factionrealm** Faction and realm specific data. All of the players characters on the same realm and of the same faction share this database.
-- * **locale** Locale specific data, based on the locale of the players game client.
-- * **global** Global Data. All characters on the same account share this database.
-- * **profile** Profile-specific data. All characters using the same profile share this database. The user can control which profile should be used.
--
Expand Down Expand Up @@ -39,8 +40,8 @@
-- end
-- @class file
-- @name AceDB-3.0.lua
-- @release $Id: AceDB-3.0.lua 1115 2014-09-21 11:52:35Z kaelten $
local ACEDB_MAJOR, ACEDB_MINOR = "AceDB-3.0", 25
-- @release $Id: AceDB-3.0.lua 1142 2016-07-11 08:36:19Z nevcairiel $
local ACEDB_MAJOR, ACEDB_MINOR = "AceDB-3.0", 26
local AceDB, oldminor = LibStub:NewLibrary(ACEDB_MAJOR, ACEDB_MINOR)

if not AceDB then return end -- No upgrade needed
Expand Down Expand Up @@ -263,7 +264,7 @@ local factionrealmKey = factionKey .. " - " .. realmKey
local localeKey = GetLocale():lower()
local regionTable = { "US", "KR", "EU", "TW", "CN" }
local regionKey = _G["GetCurrentRegion"] and regionTable[GetCurrentRegion()] or string.sub(GetCVar("realmList"), 1, 2):upper()
local regionKey = regionTable[GetCurrentRegion()]
local factionrealmregionKey = factionrealmKey .. " - " .. regionKey
-- Actual database initialization function
Expand Down Expand Up @@ -303,7 +304,7 @@ local function initdb(sv, defaults, defaultProfile, olddb, parent)
["factionrealm"] = factionrealmKey,
["factionrealmregion"] = factionrealmregionKey,
["profile"] = profileKey,
["locale"] = localeKey,
["locale"] = localeKey,
["global"] = true,
["profiles"] = true,
}
Expand Down

0 comments on commit a7becf0

Please sign in to comment.