I use the global actionbar name and the IsShown() widget.
What I use for oUF_Diablo
lua Code:
--code
if MultiBarBottomRight:IsShown() then
t:SetTexture("Interface\\AddOns\\rTextures\\bar3")
elseif MultiBarBottomLeft:IsShown() then
t:SetTexture("Interface\\AddOns\\rTextures\\bar2")
else
t:SetTexture("Interface\\AddOns\\rTextures\\bar1")
end
MultiBarBottomRight:HookScript("OnShow", function() t:SetTexture("Interface\\AddOns\\rTextures\\bar3") end)
MultiBarBottomRight:HookScript("OnHide", function() t:SetTexture("Interface\\AddOns\\rTextures\\bar2") end)
MultiBarBottomLeft:HookScript("OnShow", function() t:SetTexture("Interface\\AddOns\\rTextures\\bar2") end)
MultiBarBottomLeft:HookScript("OnHide", function() t:SetTexture("Interface\\AddOns\\rTextures\\bar1") end)