onClick

open fun onClick(@NonNull mapboxCarMapSurface: MapboxCarMapSurface, x: Float, y: Float)

Allows you to implement or observe the map click handler. The surface is onAttached before this can be triggered.

See also

for instructions to enable.

Parameters

mapboxCarMapSurface

loaded and ready car map surface

x

the horizontal screen coordinate of the click in pixels

y

the vertical screen coordinate of the click in pixels