Back to Home

ESO Lua File v100029

ingame/actionbar/quickslotactionbutton.lua

[◄ back to folders ]
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
QuickslotActionButton = ActionButton:Subclass()
function QuickslotActionButton:New(...)
    local newB = ActionButton.New(self, ...)
    newB.button.tooltip = ItemTooltip
    return newB
end
function QuickslotActionButton:GetSlot()
    local slotNum = GetCurrentQuickslot()
    return slotNum
end
function QuickslotActionButton:OnRelease()
    if self.itemQtyFailure then
        PlaySound(SOUNDS.QUICKSLOT_USE_EMPTY)
    end
    ActionButton.OnRelease(self)
end
function QuickslotActionButton:ApplyStyle(template)
    ActionButton.ApplyStyle(self, template)
    local cooldownPercent = 1
    if IsInGamepadPreferredMode() and self.showingCooldown then
        cooldownPercent = self.icon.percentComplete
    end
    self:SetCooldownHeight(cooldownPercent)
    self:SetCooldownIconAnchors(self.showingCooldown)
end