changeset 43:dc898780fea8

handle profile resets
author Flick <flickerstreak@gmail.com>
date Thu, 03 Apr 2008 23:15:32 +0000
parents 11ddb9610770
children 2232b8336903
files ReAction.lua modules/ReAction_HideBlizzard/ReAction_HideBlizzard.lua
diffstat 2 files changed, 5 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/ReAction.lua	Thu Apr 03 21:36:26 2008 +0000
+++ b/ReAction.lua	Thu Apr 03 23:15:32 2008 +0000
@@ -142,6 +142,7 @@
     -- default profile is character-specific
   )
   self.db.RegisterCallback(self,"OnProfileChanged")
+  self.db.RegisterCallback(self,"OnProfileReset","OnProfileChanged")
   self.callbacks = LibStub("CallbackHandler-1.0"):New(self)
   self:RegisterChatCommand("reaction", SlashHandler)
   self:RegisterChatCommand("rxn", SlashHandler)
@@ -216,6 +217,9 @@
   if not m then
     LoadAddOn(("ReAction_%s"):format(modulename))
     m = self:GetModule(modulename,true)
+    if m then
+      dbprint(("succesfully loaded LOD module: %s"):format(modulename))
+    end
   end
   if m then
     if type(m) == "table" and type(m[method]) == "function" then
--- a/modules/ReAction_HideBlizzard/ReAction_HideBlizzard.lua	Thu Apr 03 21:36:26 2008 +0000
+++ b/modules/ReAction_HideBlizzard/ReAction_HideBlizzard.lua	Thu Apr 03 23:15:32 2008 +0000
@@ -25,6 +25,7 @@
     }
   )
   self.db.RegisterCallback(self,"OnProfileChanged")
+  self.db.RegisterCallback(self,"OnProfileReset","OnProfileChanged")
 
   self.hiddenFrame = CreateFrame("Frame")
   self.hiddenFrame:Hide()