- Fixed an issue where some options combinations was making the window unlock after /reload.

- Framework update.
- Localization updates.
This commit is contained in:
Tercioo
2019-02-19 21:56:21 -03:00
parent c018f4db29
commit 02fa9a5c6b
7 changed files with 66 additions and 25 deletions
+29 -1
View File
@@ -1,5 +1,5 @@
local dversion = 136
local dversion = 139
local major, minor = "DetailsFramework-1.0", dversion
local DF, oldminor = LibStub:NewLibrary (major, minor)
@@ -87,6 +87,9 @@ local embed_functions = {
"GetNpcIdFromGuid",
"ShowFeedbackPanel",
"SetAsOptionsPanel",
"GetPlayerRole",
"GetCharacterTalents",
"GetCharacterPvPTalents",
"CreateDropDown",
"CreateButton",
@@ -2762,11 +2765,36 @@ DF.CLEncounterID = {
{ID = 2122, Name = "G'huun"},
}
function DF:GetPlayerRole()
local assignedRole = UnitGroupRolesAssigned ("player")
if (assignedRole == "NONE") then
local spec = GetSpecialization()
return spec and GetSpecializationRole (spec) or "NONE"
end
return assignedRole
end
function DF:GetCLEncounterIDs()
return DF.CLEncounterID
end
------------------------------------------------------------------------------------------------------------------------------------------------------------------------
--> delta seconds reader
if (not DetailsFrameworkDeltaTimeFrame) then
CreateFrame ("frame", "DetailsFrameworkDeltaTimeFrame", UIParent)
end
local deltaTimeFrame = DetailsFrameworkDeltaTimeFrame
deltaTimeFrame:SetScript ("OnUpdate", function (self, deltaTime)
self.deltaTime = deltaTime
end)
function GetWorldDeltaSeconds()
return deltaTimeFrame.deltaTime
end
------------------------------------------------------------------------------------------------------------------------------------------------------------------------
--> debug
+12 -2
View File
@@ -97,7 +97,8 @@ local BarMetaFunctions = _G [DF.GlobalWidgetControlNames ["normal_bar"]]
end
--> left color
local gmember_color = function (_object)
return _object._texture.original_colors
local r, g, b, a = _object._texture:GetVertexColor()
return r, g, b, a
end
--> icon
local gmember_icon = function (_object)
@@ -208,7 +209,7 @@ local BarMetaFunctions = _G [DF.GlobalWidgetControlNames ["normal_bar"]]
--> color
local smember_color = function (_object, _value)
local _value1, _value2, _value3, _value4 = DF:ParseColors (_value)
_object.statusbar:SetStatusBarColor (_value1, _value2, _value3, _value4)
_object._texture.original_colors = {_value1, _value2, _value3, _value4}
_object.timer_texture:SetVertexColor (_value1, _value2, _value3, _value4)
@@ -348,8 +349,15 @@ local BarMetaFunctions = _G [DF.GlobalWidgetControlNames ["normal_bar"]]
function BarMetaFunctions:Hide()
self.statusbar:Hide()
end
--> return color
function BarMetaFunctions:GetVertexColor()
return self._texture:GetVertexColor()
end
--> set value (status bar)
function BarMetaFunctions:SetValue (value)
if (not value) then
value = 0
@@ -768,6 +776,8 @@ function DF:NewBar (parent, container, name, member, w, h, value, texture_name)
--> create widgets
BarObject.statusbar = CreateFrame ("statusbar", name, parent)
DF:Mixin (BarObject.statusbar, DF.WidgetFunctions)
build_statusbar (BarObject.statusbar)
BarObject.widget = BarObject.statusbar
+8 -5
View File
@@ -6147,7 +6147,7 @@ function DF:OpenLoadConditionsPanel (optionsTable, callback, frameOptions)
--create radio group for mythic+ affixes
local affixes = {}
for i = 2, 50 do
for i = 2, 1000 do
local affixName, desc, texture = C_ChallengeMode.GetAffixInfo (i)
if (affixName) then
tinsert (affixes, {
@@ -7322,7 +7322,7 @@ DF.CastFrameFunctions = {
--colour the castbar statusbar by the type of the cast
Colors = {
Casting = DF:CreateColorTable (1, 0.73, .1, 1),
Channeling = DF:CreateColorTable (0, 1, 0, 1),
Channeling = DF:CreateColorTable (1, 0.73, .1, 1),
Finished = DF:CreateColorTable (0, 1, 0, 1),
NonInterruptible = DF:CreateColorTable (.7, .7, .7, 1),
Failed = DF:CreateColorTable (.4, .4, .4, 1),
@@ -7883,12 +7883,12 @@ DF.CastFrameFunctions = {
UNIT_SPELLCAST_CHANNEL_START = function (self, unit, ...)
local name, text, texture, startTime, endTime, isTradeSkill, notInterruptible, spellID = UnitChannelInfo (unit)
--> is valid?
if (not self:IsValid (unit, name, isTradeSkill, true)) then
return
end
--> setup cast
self.casting = nil
self.channeling = true
@@ -8465,6 +8465,10 @@ end
else
self.border:Hide()
end
if (not self.Settings.ShowUnitName) then
self.unitName:Hide()
end
else
self:UnregisterEvents()
self.healthBar:SetUnit (nil)
@@ -8605,7 +8609,6 @@ end
--> misc
UpdateName = function (self)
if (not self.Settings.ShowUnitName) then
self.unitName:Hide()
return
end
+1
View File
@@ -246,6 +246,7 @@ function DF:NewImage (parent, texture, w, h, layer, coords, member, name)
ImageObject.image = parent:CreateTexture (name, layer or "OVERLAY")
ImageObject.widget = ImageObject.image
DF:Mixin (ImageObject.image, DF.WidgetFunctions)
if (not APIImageFunctions) then
APIImageFunctions = true