Class DoubleClickTrigger
java.lang.Object
com.vaadin.flow.component.trigger.internal.Trigger
com.vaadin.flow.component.trigger.internal.DomEventTrigger
com.vaadin.flow.component.trigger.internal.MouseEventTrigger
com.vaadin.flow.component.trigger.internal.DoubleClickTrigger
- All Implemented Interfaces:
Serializable
Fires on the host component's
dblclick DOM event. The event's
coordinates and modifier-key state are available as static
Action.Input sources on MouseEventTrigger.EventData (also
reachable as DoubleClickTrigger.EventData through inheritance).
Example — on double-click, mirror the viewport X coordinate into a field's
value property:
DoubleClickTrigger dbl = new DoubleClickTrigger(panel);
dbl.triggers(new SetPropertyAction<>(field, "value",
DoubleClickTrigger.EventData.clientX));
For internal use only. May be renamed or removed in a future release.
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from class com.vaadin.flow.component.trigger.internal.MouseEventTrigger
MouseEventTrigger.EventData -
Constructor Summary
ConstructorsConstructorDescriptionDoubleClickTrigger(Component host) Creates a double-click trigger on the given host component's root element. -
Method Summary
Methods inherited from class com.vaadin.flow.component.trigger.internal.DomEventTrigger
install
-
Constructor Details
-
DoubleClickTrigger
Creates a double-click trigger on the given host component's root element.- Parameters:
host- the component to listen on, notnull
-