diff Bar.lua @ 279:5b9c0164a491

Fixed a number of problems with drag corners in config mode - Fixed button resizing via dragging not updating until a reload - Fixed pet/stance/vehicle buttons not always displaying in config mode - Fixed error spam when making too many pet/bag buttons
author Flick
date Wed, 11 May 2011 16:19:17 -0700
parents 36a29870bf34
children f2ed8a8e2320 0ea325e616ab
line wrap: on
line diff
--- a/Bar.lua	Wed May 11 11:27:36 2011 -0700
+++ b/Bar.lua	Wed May 11 16:19:17 2011 -0700
@@ -351,6 +351,9 @@
   if w > 0 and h > 0 then
     self.config.btnWidth = w
     self.config.btnHeight = h
+    for _, b in pairs(self.buttons) do
+      b:Refresh()
+    end
   end
 end
 
@@ -403,6 +406,7 @@
     b:ShowGridTemp(mode)
     b:UpdateActionIDLabel(mode)
   end
+  self.buttonClass:SetupBar(self) -- force a full refresh
 end
 
 function Bar:SetKeybindMode(mode)
@@ -667,10 +671,10 @@
   end
   if enable then
     if not self.unitwatch then
-      RegisterUnitWatch(self:GetFrame(),true)
+      RegisterUnitWatch(f,true)
     end
   elseif self.unitwatch then
-    UnregisterUnitWatch(self:GetFrame())
+    UnregisterUnitWatch(f)
   end
   self.unitwatch = enable
   self:RefreshSecureState()