properly hide the LBF Backdrop and Gloss on empty buttons (thanks to jjsheets for the API)
This commit is contained in:
+18
@@ -245,6 +245,15 @@ end
|
||||
function PetButtonPrototype:ShowButton()
|
||||
self.pushedTexture:SetTexture(self.textureCache.pushed)
|
||||
self.highlightTexture:SetTexture(self.textureCache.highlight)
|
||||
if LBF then
|
||||
local backdrop, gloss = LBF:GetBackdropLayer(self), LBF:GetGlossLayer(self)
|
||||
if backdrop then
|
||||
backdrop:Show()
|
||||
end
|
||||
if gloss then
|
||||
gloss:Show()
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
function PetButtonPrototype:HideButton()
|
||||
@@ -253,6 +262,15 @@ function PetButtonPrototype:HideButton()
|
||||
|
||||
self.pushedTexture:SetTexture("")
|
||||
self.highlightTexture:SetTexture("")
|
||||
if LBF then
|
||||
local backdrop, gloss = LBF:GetBackdropLayer(self), LBF:GetGlossLayer(self)
|
||||
if backdrop then
|
||||
backdrop:Hide()
|
||||
end
|
||||
if gloss then
|
||||
gloss:Hide()
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
function PetButtonPrototype:ShowGrid()
|
||||
|
||||
Reference in New Issue
Block a user