View Single Post
01-29-13, 12:43 PM   #3
Mayron
A Frostmaul Preserver
 
Mayron's Avatar
AddOn Author - Click to view addons
Join Date: Jan 2010
Posts: 275
Sorry for the delayed reply. I am pressing a button I made using KgPanels:

OnClick:
Code:
if InCombatLockdown() then return end

if pressed then
	if IsAddOnLoaded("Grid") then
		Grid.db:SetProfile("MayronUIH2")
	end
end
Also that last script I posted works very well except I can no longer set the Solo Layout to anything besides none as it does not show so I can't set up my Grid frames while out of a group or raid. I want to add something to fix this so I've looked into the GridLayout.lua but I couldn't find anything that would help me.

All I want to do is to be able to click my button and the Grid profiles change but show up instantly because without that code, if I am in an instance then there is either a very large delay or I need to reload the UI. I cannot use this button while out of combat which is good otherwise I would expect some sort of error. Also I have noticed that sometimes if I press the button then the profiles change and the Grid frames are showing even if I am on my own and the solo layout is set to none so they should not be there but they are. So this code I came up with corrects these two issues but now I cannot use the solo layout to configure the frames.

I was thinking I could add something that checks the grid solo layout and shows if the layout is set to something besides none else it does what the code already says. I am very bad with lua so not sure if that is possible or not. Thank you for reading!
  Reply With Quote