@Command @NotifyChange({"miceData", "firstMarkersvm", "secondMarkersvm", "infovm"}) public void infoChangeEvent(@ContextParam(ContextType.BIND_CONTEXT) BindContext ctx) { InfoChangeEvent event = (InfoChangeEvent) ctx.getTriggerEvent(); _mapsvm.setMiceData(event); Ginfo info = event.getInfo(); if (info instanceof Gmarker) _markersvmMap.get(info.getId()).setOpen(false); else _infovm.setOpen(false); }
@Command @NotifyChange({"mmeData", "firstMarkersvm", "secondMarkersvm"}) public void mapMouseEvent(@ContextParam(ContextType.BIND_CONTEXT) BindContext ctx) { MapMouseEvent event = (MapMouseEvent) ctx.getTriggerEvent(); _mapsvm.setMmeData(event); if ("onMapClick".equals(event.getName()) && (event.getReference() instanceof Gmarker)) { GmarkersVM vm = _markersvmMap.get(((Gmarker) event.getReference()).getId()); if (!vm.getOpen()) vm.setOpen(true); } }
@Command @NotifyChange({"mdeData", "firstMarkersvm", "secondMarkersvm"}) public void mapDropEvent(@ContextParam(ContextType.BIND_CONTEXT) BindContext ctx) { MapDropEvent event = (MapDropEvent) ctx.getTriggerEvent(); _mapsvm.setMdeData(event); if (event.getDragged() instanceof Gmarker) { GmarkersVM vm = _markersvmMap.get(((Gmarker) event.getDragged()).getId()); vm.setLat(event.getLat()); vm.setLng(event.getLng()); } }
public Map<?, ?> getMiceData() { return _mapsvm.getMiceData(); }
@Command @NotifyChange("mzeData") public void mapZoomEvent(@ContextParam(ContextType.BIND_CONTEXT) BindContext ctx) { _mapsvm.setMzeData((MapZoomEvent) ctx.getTriggerEvent()); }