MapEventObserver

Lifecycle and interaction callbacks for objects attached to the map pipeline (layers, controls, etc.).

com.xweather.mapsgl.layers.tile.MapLayer implements this interface so hosts can react to visibility, camera moves, and teardown consistently with the Mapbox-backed controller.

Inheritors

Functions

Link copied to clipboard
abstract fun onAdd()

Called when the observer is attached with no tile-layer context (simple registration).

abstract fun onAdd(context: RenderContext<Any>, tileLayer: TileLayer, controller: MapboxMapController)

Called when the observer is attached with render context and owning tile layer / controller.

Link copied to clipboard
abstract fun onClick()

Map tap / click routed from the gestures plugin.

Link copied to clipboard
abstract fun onHidden()

Observer or host layer became hidden.

Link copied to clipboard
abstract suspend fun onMove()

Invoked while the map camera is moving (per frame or throttled).

Link copied to clipboard
abstract suspend fun onMoveEnd()

Invoked once when a camera movement settles.

Link copied to clipboard
abstract fun onMoveStart()

First callback when a gesture or programmatic camera change begins.

Link copied to clipboard
abstract fun onRemove()

Called when the observer is removed from the map; release GL or listeners here.

Link copied to clipboard
abstract fun onResize()

Host view size or map drawable size changed.

Link copied to clipboard
abstract fun onVisible()

Observer or host layer became visible.

Link copied to clipboard
abstract suspend fun update()

Periodic or explicit update tick (animation, data refresh hooks).