OnClientGUIAccepted: Difference between revisions
Jump to navigation
Jump to search
mNo edit summary |
mNo edit summary |
||
Line 10: | Line 10: | ||
==Source== | ==Source== | ||
The [[event system#Event source|source]] of this event is always the [[getRootElement|root]] element. | |||
==Example== | ==Example== | ||
Line 28: | Line 28: | ||
===Client event functions=== | ===Client event functions=== | ||
{{Client_event_functions}} | {{Client_event_functions}} | ||
Revision as of 17:08, 2 June 2008
This event is fired when enter is pressed on an editbox.
Parameters
element editBox
- editBox: The editbox which had focus.
Source
The source of this event is always the root element.
Example
This example creates an editbox and prints a message when enter is pressed.
editBox = guiCreateEdit ( 0.3, 0.1, 0.4, 0.1, "", true ) addEventHandler( "onClientGUIAccepted", editBox, function( theElement ) outputChatBox( guiGetText( theElement ) ) end )
See Also
GUI events
Input
GUI
- onClientGUIAccepted
- onClientGUIBlur
- onClientGUIChanged
- onClientGUIClick
- onClientGUIComboBoxAccepted
- onClientGUIDoubleClick
- onClientGUIFocus
- onClientGUIMouseDown
- onClientGUIMouseUp
- onClientGUIMove
- onClientGUIScroll
- onClientGUISize
- onClientGUITabSwitched
- onClientMouseEnter
- onClientMouseLeave
- onClientMouseMove
- onClientMouseWheel
Client event functions
- triggerLatentServerEvent
- triggerServerEvent
- Shared
- addEvent
- addEventHandler
- cancelEvent
- cancelLatentEvent
- getEventHandlers
- getLatentEventHandles
- getLatentEventStatus
- removeEventHandler
- triggerEvent
- wasEventCancelled