|
LuciadCPillar C# 2025.0.09
|
Handler that translates scroll or click gesture events to a zoom operation. More...
Public Member Functions | |
| ZoomEventHandler () | |
| Creates a new zoom event handler. More... | |
| void | Dispose () |
| override bool | Equals (object obj) |
| override int | GetHashCode () |
| EventResult | OnClickEvent (Luciad.Input.ClickEvent clickEvent, Luciad.Maps.Map map, bool zoomIn, double zoomSpeed=1.0) |
| Zooms towards or from the mouse position of a click. More... | |
| EventResult | OnScrollEvent (Luciad.Input.ScrollEvent scrollEvent, Luciad.Maps.Map map, double zoomSpeed=1.0, bool invertZoomDirection=false) |
| Applies a zoom towards or from the mouse position using the wheel uses the given zoom speed, with 1 being the default zoom speed. More... | |
Handler that translates scroll or click gesture events to a zoom operation.
This is a reusable code block that a controller designer can use in its implementation.
|
inline |
Creates a new zoom event handler.
|
inline |
|
inline |
|
inline |
|
inline |
Zooms towards or from the mouse position of a click.
| clickEvent | a click event, cannot be null. |
| map | the map, cannot be null. |
| zoomIn | true if zooming in, false otherwise. |
| zoomSpeed | the zoom speed. Must be a number greater than 0. Default value is 1.0. |
EventResult.Consumed. | System.ArgumentNullException | when passing null for the map or the event. |
|
inline |
Applies a zoom towards or from the mouse position using the wheel uses the given zoom speed, with 1 being the default zoom speed.
For example: 0.5 zooms twice as slow, 2 zooms twice as much. The direction of the scroll is used to determine the direction of this action.
| scrollEvent | a scroll event, cannot be null. |
| map | the map, cannot be null. |
| zoomSpeed | the zoom speed. Must be a number greater than 0. Default value is 1.0. |
| invertZoomDirection | to invert the zoom direction. By default, this method will zoom in when the verticals scrolling delta is positive, and zoom out when it is negative |
EventResult.Consumed. | System.ArgumentNullException | when passing null for the map or the event. |