onClick property

Stream<KmlMouseEvent> get onClick

Implementation

Stream<KmlMouseEvent> get onClick {
  late StreamController<KmlMouseEvent> sc; // ignore: close_sinks
  late MapsEventListener mapsEventListener;
  void start() => mapsEventListener = Event.addListener(
        this,
        'click',
        (KmlMouseEvent kmlClickEvent) => sc.add(kmlClickEvent),
      );
  void stop() => mapsEventListener.remove();
  sc = StreamController<KmlMouseEvent>(
    onListen: start,
    onCancel: stop,
    onResume: start,
    onPause: stop,
  );
  return sc.stream;
}