File tree Expand file tree Collapse file tree 1 file changed +3
-0
lines changed
Expand file tree Collapse file tree 1 file changed +3
-0
lines changed Original file line number Diff line number Diff line change @@ -362,15 +362,18 @@ end
362362
363363function DialogKey :SetClickbuttonBinding (frame , key )
364364 if InCombatLockdown () then return end
365+ self .globalCooldown = true
365366 self .frame :SetAttribute (" clickbutton" , frame )
366367 self :SetOverrideBindings (self .frame , self .frame :GetName (), {key })
368+ RunNextFrame (function () self .globalCooldown = false end )
367369
368370 -- just in case something goes horribly wrong, we do NOT want to get the user stuck in a situation where the keyboard stops working
369371 RunNextFrame (function () self :ClearOverrideBindings (self .frame ) end )
370372end
371373
372374function DialogKey :HandleKey (key )
373375 if not InCombatLockdown () then self .frame :SetPropagateKeyboardInput (true ) end
376+ if self .globalCooldown then return end
374377 local doAction = (key == self .db .keys [1 ] or key == self .db .keys [2 ])
375378 local keynum = doAction and 1 or tonumber (key )
376379 if key == " 0" then
You can’t perform that action at this time.
0 commit comments