dojo.connect(map, "onZoomEnd", catchZoom2); dojo.connect(map, "onZoomStart", catchZoom);
//catch bad zooms//get map extent at the start of the zoom function catchZoom(extent,zoomFactor) { oldExtent = new esri.geometry.Extent(); oldExtent = extent; } //if the zoomfactor is too big, assume it is an error and go back to the original function catchZoom2(extent, zoomFactor) { console.debug(zoomFactor) if (zoomFactor > 400) { map.setExtent(startExtent); }
サインインしたメンバーは投稿、更新のフォローなどができます。初めてですか?無料アカウントを登録してください。
Find useful guides, FAQs, and documents to help you navigate and make the most of Esri Community.