Mera and his damn requests :P
Repooc [11-28-16 - 10:06]
Mera and his damn requests :P
diff --git a/ElvUI_SLE/modules/Armory/Config.lua b/ElvUI_SLE/modules/Armory/Config.lua
index 1aecc1e..714b453 100644
--- a/ElvUI_SLE/modules/Armory/Config.lua
+++ b/ElvUI_SLE/modules/Armory/Config.lua
@@ -778,10 +778,24 @@ local function LoadArmoryConfigTable()
end,
disabled = function() return E.db.sle.Armory.Inspect.Enable == false end
},
+ CurrentClassColor = {
+ type = 'toggle',
+ name = L["Use Inspected Unit Class Color"],
+ order = 2,
+ get = function() return E.db.sle.Armory.Inspect.Gradation.CurrentClassColor end,
+ set = function(_, value)
+ E.db.sle.Armory.Inspect.Gradation.CurrentClassColor = value
+
+ if _G["InspectArmory"] and _G["InspectArmory"].LastDataSetting then
+ _G["InspectArmory"]:InspectFrame_DataSetting(_G["InspectArmory"].CurrentInspectData)
+ end
+ end,
+ disabled = function() return E.db.sle.Armory.Inspect.Enable == false end
+ },
Color = {
type = 'color',
name = L["Gradient Texture Color"],
- order = 2,
+ order = 3,
get = function()
return E.db.sle.Armory.Inspect.Gradation.Color[1],
E.db.sle.Armory.Inspect.Gradation.Color[2],
@@ -795,7 +809,7 @@ local function LoadArmoryConfigTable()
_G["InspectArmory"]:InspectFrame_DataSetting(_G["InspectArmory"].CurrentInspectData)
end
end,
- disabled = function() return E.db.sle.Armory.Inspect.Enable == false or E.db.sle.Armory.Inspect.Gradation.Display == false end
+ disabled = function() return E.db.sle.Armory.Inspect.Enable == false or E.db.sle.Armory.Inspect.Gradation.Display == false or E.db.sle.Armory.Inspect.Gradation.CurrentClassColor == true end
},
}
},
diff --git a/ElvUI_SLE/modules/Armory/InspectArmory/InspectArmory.lua b/ElvUI_SLE/modules/Armory/InspectArmory/InspectArmory.lua
index 16f9167..fe1cb52 100644
--- a/ElvUI_SLE/modules/Armory/InspectArmory/InspectArmory.lua
+++ b/ElvUI_SLE/modules/Armory/InspectArmory/InspectArmory.lua
@@ -2162,6 +2162,9 @@ function IA:InspectFrame_DataSetting(DataTable)
if ErrorDetected and E.db.sle.Armory.Inspect.NoticeMissing then
Slot.Gradation.Texture:SetVertexColor(1, 0, 0)
Slot.Gradation.Texture:Show()
+ elseif E.db.sle.Armory.Inspect.Gradation.CurrentClassColor then
+ curR, curG, curB = RAID_CLASS_COLORS[IA.CurrentInspectData.Class].r, RAID_CLASS_COLORS[IA.CurrentInspectData.Class].g, RAID_CLASS_COLORS[IA.CurrentInspectData.Class].b
+ Slot.Gradation.Texture:SetVertexColor(curR, curG, curB)
else
Slot.Gradation.Texture:SetVertexColor(T.unpack(E.db.sle.Armory.Inspect.Gradation.Color))
end
diff --git a/ElvUI_SLE/modules/Armory/InspectArmory/Profile.lua b/ElvUI_SLE/modules/Armory/InspectArmory/Profile.lua
index 4dd60ed..4c7b84b 100644
--- a/ElvUI_SLE/modules/Armory/InspectArmory/Profile.lua
+++ b/ElvUI_SLE/modules/Armory/InspectArmory/Profile.lua
@@ -18,7 +18,8 @@ P.sle.Armory.Inspect = {
Gradation = {
Display = true,
- Color = { .41, .83, 1 }
+ Color = { .41, .83, 1 },
+ CurrentClassColor = false
},
Level = {