# HG changeset patch # User Flick # Date 1301002076 25200 # Node ID 8bde290d300c64f8083337995a8a6915f3e9e1ef # Parent 704f4a05a1d7ce2990e563ef0f2f98ad6bda26c9 Chase away Lua errors when clicking 4.0 flyout actions (e.g. call pet, teleport) diff -r 704f4a05a1d7 -r 8bde290d300c classes/ActionButton.lua --- a/classes/ActionButton.lua Thu Mar 24 13:11:30 2011 -0700 +++ b/classes/ActionButton.lua Thu Mar 24 14:27:56 2011 -0700 @@ -123,7 +123,7 @@ local _onReceiveDrag = -- function(self, button, kind, value, ...) [[ - if kind ~= "spell" and kind ~= "item" and kind ~= "macro" then + if kind ~= "spell" and kind ~= "item" and kind ~= "macro" and kind ~= "flyout" then return kind, value, ... else if showgrid_event and showgrid_event > 0 then @@ -237,6 +237,8 @@ f:RegisterEvent(evt) end + f.action = config.actionID -- need this to support silly ActionButton_UpdateFlyout. Should not taint anything anymore. + -- secure handlers f:SetAttribute("_childupdate", _childupdate) f:SetAttribute("_childupdate-showgrid",_childupdate_showgrid) @@ -684,6 +686,8 @@ if attr ~= "statehidden" then self:UpdateAction() end + local f = self:GetFrame() + f.action = f:GetAttribute("action") -- support ActionButton_UpdateFlyout end function Action:PostClick( )