diff classes/Bar.lua @ 171:fe0c7be6f6ef

Convert GridProxy to LibShowGrid
author Flick <flickerstreak@gmail.com>
date Tue, 19 Oct 2010 20:22:59 +0000
parents 8cc187143acd
children df68b5a40490
line wrap: on
line diff
--- a/classes/Bar.lua	Tue Oct 19 20:07:55 2010 +0000
+++ b/classes/Bar.lua	Tue Oct 19 20:22:59 2010 +0000
@@ -6,7 +6,8 @@
 local fmod = math.fmod
 local format = string.format
 
-local KB = LibStub("LibKeyBound-1.0")
+local LKB = LibStub("LibKeyBound-1.0")
+local LSG = LibStub("LibShowGrid-1.0")
 
 ---- Secure snippets ----
 local _reaction_init = 
@@ -221,7 +222,7 @@
   f:Show()
   f:EnableMouse(false)
   f:SetClampedToScreen(true)
-  ReAction.gridProxy:AddFrame(f)
+  LSG:AddFrame(f)
 
   -- secure handlers
   f:Execute(_reaction_init)
@@ -245,9 +246,9 @@
   self:SetKeybindMode(ReAction:GetKeybindMode())
 
   ReAction.RegisterCallback(self, "OnConfigModeChanged")
-  KB.RegisterCallback(self, "LIBKEYBOUND_ENABLED")
-  KB.RegisterCallback(self, "LIBKEYBOUND_DISABLED")
-  KB.RegisterCallback(self, "LIBKEYBOUND_MODE_COLOR_CHANGED","LIBKEYBOUND_ENABLED")
+  LKB.RegisterCallback(self, "LIBKEYBOUND_ENABLED")
+  LKB.RegisterCallback(self, "LIBKEYBOUND_DISABLED")
+  LKB.RegisterCallback(self, "LIBKEYBOUND_MODE_COLOR_CHANGED","LIBKEYBOUND_ENABLED")
 
   return self
 end
@@ -257,8 +258,8 @@
   f:UnregisterAllEvents()
   self:ShowControls(false)
   ReAction.UnregisterAllCallbacks(self)
-  KB.UnregisterAllCallbacks(self)
-  ReAction.gridProxy:RemoveFrame(f)
+  LKB.UnregisterAllCallbacks(self)
+  LSG:RemoveFrame(f)
   f:SetParent(UIParent)
   f:ClearAllPoints()
   f:Hide()