onContextmenu property

Stream<PolyMouseEvent> get onContextmenu

Implementation

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