Originally Posted by liquidbase
Similar to my function to edit the buttons. However, since Shadowlands every button seems to have an additional field which means .nogrid, that is what caused the problem.
bar3.lua (bar with issue, shares the same code with all other bars)
init.lua (file for loading and creating bars, function to hide Blizzard-Stuff can found on top of the file)
|
Where are you getting that info about .nogrid field ?
I've checked the following files and none have nogrid mentioned anywhere.
https://www.townlong-yak.com/framexm...tionButton.lua
https://www.townlong-yak.com/framexm...onTemplate.xml
https://www.townlong-yak.com/framexm...onBarFrame.xml
https://www.townlong-yak.com/framexm...Controller.lua
Aha .. I think this is it .. A multiactionbar specific value .. but still seems to apply to all 12 buttons unless you override that constant value.
https://www.townlong-yak.com/framexm...ActionBars.lua
Lua Code:
NUM_MULTIBAR_BUTTONS = 12;
function MultiActionBar_ShowAllGrids (reason)
MultiActionBar_UpdateGrid("MultiBarBottomLeft", true, reason);
MultiActionBar_UpdateGrid("MultiBarBottomRight", true, reason);
MultiActionBar_UpdateGrid("MultiBarRight", true, reason);
MultiActionBar_UpdateGrid("MultiBarLeft", true, reason);
end
function MultiActionBar_HideAllGrids (reason)
MultiActionBar_UpdateGrid("MultiBarBottomLeft", false, reason);
MultiActionBar_UpdateGrid("MultiBarBottomRight", false, reason);
MultiActionBar_UpdateGrid("MultiBarRight", false, reason);
MultiActionBar_UpdateGrid("MultiBarLeft", false, reason);
end
function MultiActionBar_UpdateGrid (barName, show, reason)
for i = 1, NUM_MULTIBAR_BUTTONS do
local button = _G[barName.."Button"..i];
if ( show and not button.noGrid) then
button:ShowGrid(reason);
else
button:HideGrid(reason);
end
end
end
function MultiActionBar_UpdateGridVisibility ()
if ( ALWAYS_SHOW_MULTIBARS == "1" or ALWAYS_SHOW_MULTIBARS == 1 ) then
MultiActionBar_ShowAllGrids(ACTION_BUTTON_SHOW_GRID_REASON_CVAR);
else
MultiActionBar_HideAllGrids(ACTION_BUTTON_SHOW_GRID_REASON_CVAR);
end
end