@@ -216,10 +216,12 @@ local SkillsTabClass = newClass("SkillsTab", "UndoHandler", "ControlHost", "Cont
216216 self .controls .imbuedSupportLabel = new (" LabelControl" , { " LEFT" , self .controls .includeInFullDPS , " RIGHT" }, { 12 , 0 , 0 , 16 }, colorCodes .POSITIVE .. " Imbued Support:" )
217217 self .controls .imbuedSupport = new (" GemSelectControl" , { " LEFT" , self .controls .imbuedSupportLabel , " RIGHT" }, { 8 , 0 , 250 , 20 }, self , 1 , function (gemData , _ , _ , slotName ) -- slotName used on Import
218218 if gemData and (type (gemData ) == " string" or gemData .id ) then
219- self .imbuedSupportBySlot [slotName or self .displayGroup .slot ] = data .gems [gemData .id or gemData ].grantedEffect
219+ local gem = data .gems [gemData .id or gemData ]
220+ self .imbuedSupportBySlot [slotName or self .displayGroup .slot ] = gem .grantedEffect
220221 if self .displayGroup then
221- self .displayGroup .imbuedSupport = data . gems [ gemData . id or gemData ] .name
222+ self .displayGroup .imbuedSupport = gem .name
222223 end
224+ self .controls .imbuedSupport :SetText (data .skillColorMap [gem .grantedEffect .color ].. gem .name ) -- hacky way to set gem color on gemSelect
223225 self .build .buildFlag = true
224226 else
225227 self .imbuedSupportBySlot [slotName or self .displayGroup .slot ] = nil
@@ -236,14 +238,15 @@ local SkillsTabClass = newClass("SkillsTab", "UndoHandler", "ControlHost", "Cont
236238 self .controls .imbuedSupportLabel .shown = function () -- don't show imbued for skills from items
237239 return not self .displayGroup .source
238240 end
239- self .controls .imbuedSupportClear = new (" ButtonControl" , { " LEFT" , self .controls .imbuedSupportLabel , " RIGHT" }, { 264 , 0 , 80 , 20 }, " Clear " , function ()
241+ self .controls .imbuedSupportClear = new (" ButtonControl" , { " LEFT" , self .controls .imbuedSupportLabel , " RIGHT" }, { 260 , 0 , 20 , 20 }, " x " , function ()
240242 self .controls .imbuedSupport .gemId = nil
241243 self .controls .imbuedSupport :SetText (" " )
242244 self .displayGroup .imbuedSupport = nil
243245 self .imbuedSupportBySlot [self .displayGroup .slot ] = nil
244246
245247 self .build .buildFlag = true
246248 end )
249+ self .controls .imbuedSupportClear .tooltipText = " Remove this imbued support."
247250
248251 self .controls .groupCountLabel = new (" LabelControl" , { " LEFT" , self .controls .includeInFullDPS , " RIGHT" }, { 16 , 0 , 0 , 16 }, " Count:" )
249252 self .controls .groupCountLabel .shown = function ()
@@ -514,7 +517,7 @@ function SkillsTabClass:Draw(viewPort, inputEvents)
514517 self .controls .scrollBarH .y = viewPort .y + viewPort .height - 18
515518
516519 do
517- local maxX = self .controls .gemCountHeader :GetPos () + self .controls .gemCountHeader :GetSize () + 15
520+ local maxX = self .controls .gemCountHeader :GetPos () + self .controls .gemCountHeader :GetSize () + 350
518521 local contentWidth = maxX - self .x
519522 self .controls .scrollBarH :SetContentDimension (contentWidth , viewPort .width )
520523 end
@@ -689,7 +692,6 @@ function SkillsTabClass:CreateGemSlot(index)
689692 slot .enableGlobal1 .state = true
690693 slot .enableGlobal2 .state = true
691694 slot .count :SetText (gemInstance .count )
692- -- slot.imbued.state = false
693695 elseif gemId == gemInstance .gemId then
694696 if addUndo then
695697 self :AddUndoState ()
@@ -1065,8 +1067,9 @@ function SkillsTabClass:SetDisplayGroup(socketGroup)
10651067 self .controls .includeInFullDPS .state = socketGroup .includeInFullDPS and socketGroup .enabled
10661068 self .controls .groupCount :SetText (socketGroup .groupCount or 1 )
10671069 if socketGroup .imbuedSupport then
1068- self .controls .imbuedSupport .gemId = data .gems [data .gemForBaseName [socketGroup .imbuedSupport :lower ().. " support" ]]
1069- self .controls .imbuedSupport :SetText (socketGroup .imbuedSupport )
1070+ local gemId = data .gems [data .gemForBaseName [socketGroup .imbuedSupport :lower ().. " support" ]]
1071+ self .controls .imbuedSupport .gemId = gemId
1072+ self .controls .imbuedSupport :SetText (data .skillColorMap [gemId .grantedEffect .color ].. socketGroup .imbuedSupport )
10701073 else
10711074 self .controls .imbuedSupport .gemId = nil
10721075 self .controls .imbuedSupport :SetText (" " )
0 commit comments