Package com.luciad.controllers
Class PanEventHandler
java.lang.Object
com.luciad.controllers.PanEventHandler
- All Implemented Interfaces:
AutoCloseable
Basic gesture handler dedicated to translate drag gesture events to a pan operation.
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
close()
protected void
finalize()
onDragEvent
(DragEvent dragEvent, Map map) Moves the map's camera following the drag direction.
-
Constructor Details
-
Method Details
-
finalize
protected void finalize() -
close
public void close()- Specified by:
close
in interfaceAutoCloseable
-
onDragEvent
@NotNull public EventResult onDragEvent(@NotNull DragEvent dragEvent, @NotNull Map map) throws NullPointerException Moves the map's camera following the drag direction.The drag event is consumed only if the sequence of events is the following : a
EventStatus#Start
event, 0 or moreEventStatus#InProgress
event and finally aEventStatus#End
event. If the sequence is not correct, this method returnsEventResult#NotConsumed
.- Parameters:
dragEvent
- a drag event. Cannot benull
.map
- the map. Cannot benull
.- Returns:
- whether the drag event was consumed or not.
- Throws:
NullPointerException
- when passingnull
for the map or the event.
-