Key Bind Handlers
Wrapping a secure button's OnClick handler is easy enough but there always needs to be extra code to handle the key binds associated with that button. In some cases the overhead involved for processing key binds may actually be greater than the code it is there to support, especially for the primary action bar which its key binds can be redirected to two other action bars.
My suggestion would to be change the key bind handling functions to emulate being clicked rather than directly calling the function normally assigned to their OnClick handlers. So, for example, in ActionButtonDown and ActionButtonUp the line: Code:
SecureActionButton_OnClick(button, "LeftButton") Code:
button:Click("LeftButton") |
The idea you proposed is irrelevant to keybinds and is a simplification on running a button's OnClick handler.
At any rate, your proposition already exists exactly as you described it. See button:Click() |
I think you completely missed the point of the suggestion.
|
If taint is a concern then this should work:
Code:
securecall(button.Click, button, "LeftButton"); Code:
if (issecure()) then |
All times are GMT -6. The time now is 10:14 AM. |
vBulletin © 2024, Jelsoft Enterprises Ltd
© 2004 - 2022 MMOUI