highlightHoveredMapLabel method

GemError highlightHoveredMapLabel(
  1. Point<int> screenPosition, {
  2. bool selectMapObject = false,
})

Highlight the hovered map label under the given screen coordinates.

To turn off the hover highlight call the function with (0, 0) screen position

A recommended implementation is to call highlightHoveredMapLabel( ..., selectMapObjects = false) in order to check if a label is hovered (and eventually update tracking device cursor shape etc) and if the cursor position is stationary for a reasonable time period (e.g. 500 ms) call highlightHoveredMapLabel( ..., selectMapObjects = true) to retrieve the hovered map object data

Parameters

** IN** screenPosition The hovered screen point ** IN** selectMapObject If true and a label is hovered, map objects attached to label are returned via IMapViewListener.onHoveredMapLabelHighlighted If false, no call to onHoveredMapLabelHighlighted is issued.

** Returns**

Throws

  • An exception if it fails.

Implementation

GemError highlightHoveredMapLabel(
  final Point<int> screenPosition, {
  final bool selectMapObject = false,
}) {
  final OperationResult resultString = objectMethod(
    _pointerId,
    'MapView',
    'highlightHoveredMapLabel',
    args: <String, Object>{
      'pt': XyType<int>.fromPoint(screenPosition),
      'selectMapObjects': selectMapObject,
    },
  );

  return GemErrorExtension.fromCode(resultString['result']);
}