OnDgsElementScroll
From Multi Theft Auto: Wiki
This event is fired when a DGS element is scrolled ( including scroll bar and scroll bars of scroll pane, grid list, memo and combo box ).
Parameters
element ScrollBar, float ScrollTo, float ScrollFrom
- ScrollBar: The scroll bar that has changed its scroll position.
- ScrollTo: The value of current scroll position
- ScrollFrom: The value of previous scroll position
Source
The source of this event is the dgs element that got scrolled (can be scroll pane, grid list, combo box, memo and scroll bar).
Example
This example outputs a message with the new scroll position and old scroll position when a scrollbar is scrolled.
DGS = exports.dgs function OnScroll(scb,new,old) outputChatBox("The new scroll position is "..new.." ( was:"..old.." )") end addEventHandler("onDgsElementScroll",getRootElement(),OnScroll)
See Also
DGS events
- onDgsArrowListValueChange
- onDgsBlur
- onDgsCheckBoxChange
- onDgsComboBoxStateChange
- onDgsComboBoxSelect
- onDgsCreate
- onDgsDestroy
- onDgsEditPreSwitch
- onDgsEditSwitched
- onDgsEditAccepted
- onDgsElementRender
- onDgsElementMove
- onDgsElementSize
- onDgsFocus
- onDgsGridListItemDoubleClick
- onDgsGridListSelect
- onDgsMouseClick
- onDgsMouseClickDown
- onDgsMouseClickUp
- onDgsMouseDrag
- onDgsMouseDoubleClick
- onDgsMouseDown
- onDgsMouseEnter
- onDgsMouseLeave
- onDgsMouseMove
- onDgsMouseUp
- onDgsMouseWheel
- onDgsRadioButtonChange
- onDgsPositionChange
- onDgsPreRender
- onDgsRender
- onDgsElementScroll
- onDgsSizeChange
- onDgsTabPanelTabSelect
- onDgsTabSelect
- onDgsTextChange
- onDgsWindowClose
Plugin
Media
- onDgsMediaPlay
- onDgsMediaPause
- onDgsMediaStop
- onDgsMediaDurationGet
- onDgsMediaTimeUpdate
- onDgsMediaBrowserReturn
Color Picker
Client event functions
- addEvent
- addEventHandler
- cancelEvent
- cancelLatentEvent
- getEventHandlers
- getLatentEventHandles
- getLatentEventStatus
- removeEventHandler
- triggerEvent
- triggerLatentServerEvent
- triggerServerEvent
- wasEventCancelled