Content:MirLua/NamedEvents: Difference between revisions
Jump to navigation
Jump to search
(+note & todo) |
No edit summary |
||
Line 21: | Line 21: | ||
{{Documentation | {{Documentation | ||
|link box = off | |link box = off | ||
|content = {{Important|This was made to test how things from Plugin:MirLua subpages will look as a table. It's not ready to use yet.}}{{Todo|Not to forget to use it when creating multilingual content for MirLua (sub)pages.}} | |content = {{Important|This was made to test how things from Plugin:MirLua subpages will look as a table. It's not ready to use yet.}}{{Todo|(1) Not to forget to use it when creating multilingual content for MirLua (sub)pages; (2) column "Setting" should be renamed to "Parameters".}} | ||
Automatic, localized <span style="color:red;font-weight:bold">test table</span> for MirLua named event functions of m_core module. | Automatic, localized <span style="color:red;font-weight:bold">test table</span> for MirLua named event functions of m_core module. | ||
}} | }} | ||
</noinclude> | </noinclude> |
Revision as of 16:32, 13 December 2015
Function | Description | Extended description | Settings | Example |
---|---|---|---|---|
CreateHookableEvent | Creates a hookable event. | name
|
local hEvent = m.CreateHookableEvent('MyEvent') |
|
HookEvent | Sets a callback function ("trap") to react to event call. | Traps are called one by one in the order they were added to the sequence. Trap signature: |
name
hook
|
local hHook = m.HookEvent('MyEvent', function(w, l)
print('MyEvent is raised!')
end) |
UnhookEvent | Removes "trap" from event call sequence. | hEvent
|
m.UnhookEvent(hHook) |
|
NotifyEventHooks | Calls all "traps" of event call sequence one by one. | hEvent
wParam
|
m.NotifyEventHooks(hEvent) |
Documentation
<translate> Important</translate>
This was made to test how things from Plugin:MirLua subpages will look as a table. It's not ready to use yet.
This was made to test how things from Plugin:MirLua subpages will look as a table. It's not ready to use yet.
Todo: (1) Not to forget to use it when creating multilingual content for MirLua (sub)pages; (2) column "Setting" should be renamed to "Parameters".
Automatic, localized test table for MirLua named event functions of m_core module.