Provides data for the ItemClicked, ItemDoubleClicked, ItemLeftClicked, ItemLeftDoubleClicked, ItemRightClicked and ItemRightDoubleClicked events.
Type Parameters
- T
- The type of the item this event carries.
Type Details
- yfiles module
- view-table
- yfiles-umd modules
- view-table, view
- Legacy UMD name
- yfiles.input.TableItemClickedEventArgs
Constructors
TableItemClickedEventArgs
(item: T, region: StripeSubregion, tableNode: INode, context: IInputModeContext, location: Point, modifiers: ModifierKeys, mouseButtons: MouseButtons, clickCount: number)Initializes a new instance of the TableItemClickedEventArgs<T> class.
Parameters
A map of options to pass to the method.
- item - T
- The item which is the subject of the event.
- region - StripeSubregion
- The specific region on a stripe where the click has occurred.
- tableNode - INode
- The table node where
item
is associated. - context - IInputModeContext
- The context in which the click or tap occurred.
- location - Point
- The location.
- modifiers - ModifierKeys
- State of the modifiers.
- mouseButtons - MouseButtons
- The mouse button(s) that have changed.
- clickCount - number
- The number of clicks.
Properties
Gets the number of clicks associated with this event.
Remarks
Defined in
Gets the context for the current event.
Defined in
Gets or sets a value indicating whether this ClickEventArgs have been handled.
Remarks
Client code that is triggered by the event and does not want the event to become handled by other handles should set this property to true
to stop propagation of the event.
Note that this property needs to be set before the function synchronously returns. This means that setting the value in an async
function after the first await
or in an asynchronous callback, it cannot not be seen by the emitter of the event and the sender will consider the event as not being handled.
// wrong:
mode.addItemClickedListener(async (sender, args) => {
await something()
args.handled = true // will be set *after* all other event listeners have been invoked, only
})
// correct:
mode.addItemClickedListener(async (sender, args) => {
args.handled = true // will be set immediately and 'mode' will see the change
await something()
})
See Also
Defined in
Gets the item that is the subject of the event.
Defined in
Gets the location of the click.
Defined in
Gets the state of the modifiers at the time of the click.
Defined in
Gets the mouseButtons that have changed for this event.
Defined in
Gets the last input event.
Defined in
The specific region on a stripe where the click has occurred.