public GmarkersVM getSecondMarkersvm() { if (_markersvmTwo == null) { _markersvmTwo = new GmarkersVM(); _markersvmTwo.setId("secondMarker"); _markersvmTwo.setLat(23.1); _markersvmTwo.setLng(121.1); _markersvmTwo.setContent("test test second marker"); _markersvmMap.put("secondMarker", _markersvmTwo); } return _markersvmTwo; }
@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 GmarkersVM getFirstMarkersvm() { if (_markersvmOne == null) { _markersvmOne = new GmarkersVM(); _markersvmOne.setId("firstMarker"); _markersvmOne.setLat(23); _markersvmOne.setLng(121); _markersvmOne.setMinzoom(9); _markersvmOne.setMaxzoom(11); _markersvmOne.setIconImage("/img/Briefcase-16x16.png"); _markersvmOne.setIconAnchorX(0); _markersvmOne.setIconAnchorY(0); _markersvmOne.setIconHeight(50); _markersvmOne.setIconWidth(50); _markersvmOne.setIconShadow("/img/QuestionmarkButton-16x16.png"); _markersvmOne.setIconShadowHeight(80); _markersvmOne.setIconShadowWidth(80); _markersvmOne.setContent("test test one"); _markersvmOne.setOpen(true); _markersvmOne.setDraggingEnabled(true); _markersvmMap.put("firstMarker", _markersvmOne); } return _markersvmOne; }