Drives the map camera from a RouteLayer and exposes the next instruction. Does not draw the route. More...
Inherits Finalizable.
Public Member Functions | |
| void | setMode (GuidanceCameraMode mode) |
| Sets Free / Following / Overview. | |
| GuidanceCameraMode | mode () |
| Current mode. | |
| void | set2DMode (bool enabled) |
| Forces a top-down camera (tilt 0) in Following and Overview. When false, Following uses a fixed forward tilt. | |
| bool | is2DMode () |
| Returns true when top-down guidance is enabled. | |
| void | setActive (bool active) |
| When false, the camera is not moved. Instructions still update. | |
| bool | isActive () |
| Returns true when this controller may move the camera. | |
| RouteInstruction | instruction () |
| Latest next instruction, or null. | |
| void | addListener (GuidanceListener listener) |
| Adds a listener for mode and instruction changes. | |
| void | removeListener (GuidanceListener listener) |
| Removes a previously added listener. | |
| bool | isValid () |
Drives the map camera from a RouteLayer and exposes the next instruction. Does not draw the route.
Overview uses the window focus rect, so set LocationWindow.focusRect for chrome (floor selector, banner) before switching to OVERVIEW.
Referenced from NavigineSdk.
Definition at line 30 of file guidance_camera.dart.
| void GuidanceCamera.addListener | ( | GuidanceListener | listener | ) |
Adds a listener for mode and instruction changes.
Dart apps implement GuidanceListener and pass it to addListener.
| RouteInstruction GuidanceCamera.instruction | ( | ) |
Latest next instruction, or null.
Dart code snippet:
| bool GuidanceCamera.is2DMode | ( | ) |
Returns true when top-down guidance is enabled.
| bool GuidanceCamera.isActive | ( | ) |
Returns true when this controller may move the camera.
| bool GuidanceCamera.isValid | ( | ) |
| GuidanceCameraMode GuidanceCamera.mode | ( | ) |
Current mode.
Dart code snippet:
| void GuidanceCamera.removeListener | ( | GuidanceListener | listener | ) |
Removes a previously added listener.
| void GuidanceCamera.set2DMode | ( | bool | enabled | ) |
Forces a top-down camera (tilt 0) in Following and Overview. When false, Following uses a fixed forward tilt.
Dart code snippet:
| void GuidanceCamera.setActive | ( | bool | active | ) |
When false, the camera is not moved. Instructions still update.
| void GuidanceCamera.setMode | ( | GuidanceCameraMode | mode | ) |
Sets Free / Following / Overview.
Dart code snippet: