diff options.lua @ 98:b5a55c69ef67

Properly switch between profiles.
author Farmbuyer of US-Kilrogg <farmbuyer@gmail.com>
date Fri, 27 Jul 2012 19:09:29 +0000
parents ba5ff82dcf19
children 966d06c8d9c9
line wrap: on
line diff
--- a/options.lua	Fri Jul 27 10:23:12 2012 +0000
+++ b/options.lua	Fri Jul 27 19:09:29 2012 +0000
@@ -703,6 +703,7 @@
 
 -- Clicking an entry on the left tree column.
 local opt_OnGroupSelected_func = function (treeg,event,category)
+	opts = addon.db.profile
 	local catfuncs = controls[category]
 	if not catfuncs then
 		addon:horrible_horrible_error(("Category '%s' has no handler function!"):format(category:gsub('\001','_')))
@@ -730,8 +731,6 @@
 
 -- Clicking the Options tab as a whole (tabs_OnGroupSelected["opt"]).
 local tabs_OGS = function (container, specials)
-	opts = gui.opts
-
 	container:SetLayout("Fill")
 	local left = AceGUI:Create("TreeGroup")
 	left:SetStatusTable(status_for_select)