![]() |
The API is no longer being updated here until further notice. |
Returns the widget script handler.
script = ScriptRegion:GetScript(scriptTypeName [, bindingType])
Arguments
- scriptTypeName
- string - Name of the script type, for example "OnShow".
- bindingType
- number? - The intrinsic frame precall/postcall handler.
| Value | Enum | Description |
|---|---|---|
| 0 | LE_SCRIPT_BINDING_TYPE_INTRINSIC_PRECALL | |
| 1 | LE_SCRIPT_BINDING_TYPE_EXTRINSIC | Default |
| 2 | LE_SCRIPT_BINDING_TYPE_INTRINSIC_POSTCALL |
Returns
- script
- function? - The script handler, returns
nilif none is set.
Example
Prints the OnShow script handlers from ChatFrame1.
print(ChatFrame1:GetScript("OnShow")) -- "function: 000001EB64BE3D20"
print(ChatFrame1:GetScript("OnShow", LE_SCRIPT_BINDING_TYPE_INTRINSIC_POSTCALL)) -- "function: 000001EB88AB5800"
