WoW:API RunBinding: Difference between revisions

m
Move page script moved page API RunBinding to WoW:API RunBinding without leaving a redirect
No edit summary
m (Move page script moved page API RunBinding to WoW:API RunBinding without leaving a redirect)
 
(4 intermediate revisions by 4 users not shown)
Line 1: Line 1:
<center>'''RunBinding''' ''-Documentation by [[user:Lego|Lego]]-''</center>
{{wowapi}}


<!-- Describe the purpose of the function, exhausting detail can be saved for a later section -->
<!-- Describe the purpose of the function, exhausting detail can be saved for a later section -->
Line 9: Line 9:
=== Arguments ===
=== Arguments ===
<!-- List each argument, together with its type -->
<!-- List each argument, together with its type -->
:("command" {,"up"})
:("command" [,"up"])


:;command : String - Name of the key binding to be executed
:;command : String - Name of the key binding to be executed
Line 24: Line 24:


The "command" argument must match one of the (usually capitalized) binding names in a Bindings.xml file. This can be a name that appears in the Blizzard FrameXML Bindings.xml, or one that is specified in an AddOn.
The "command" argument must match one of the (usually capitalized) binding names in a Bindings.xml file. This can be a name that appears in the Blizzard FrameXML Bindings.xml, or one that is specified in an AddOn.
RunBinding cannot be used to call a [[:Category:World of Warcraft API/Protected Functions|Protected Function]] from an unsigned addon.


By default, the key binding is executed as if the key was pressed down, in other words the keystate variable will have value "down" during the binding's execution. By specifying the optional second argument (the actual string "up"), the binding is instead executed as if the key was released, in other words the keystate variable will have value "up" during the binding's execution.
By default, the key binding is executed as if the key was pressed down, in other words the keystate variable will have value "down" during the binding's execution. By specifying the optional second argument (the actual string "up"), the binding is instead executed as if the key was released, in other words the keystate variable will have value "up" during the binding's execution.
Line 29: Line 31:
----
----
__NOTOC__
__NOTOC__
{{Template:WoW API}}
Anonymous user