Setting a min/max zoom for Bing maps in Silverlight

前端 未结 1 1815
长发绾君心
长发绾君心 2021-01-19 14:14

I am using the Silverlight sdk for Bing Maps. I have my map, I have my PushPins all mapped out. Now I want to disable the user from zooming out so far they see the whole wor

1条回答
  •  孤城傲影
    2021-01-19 14:51

    public class MyMapMode : Microsoft.Maps.MapControl.Core.MercatorMode
    {
        public Range MapZoomRange = new Range(1.0, 10.0);
        protected override Range GetZoomRange(Location center)
        {
            return this.MapZoomRange;
        }
    }
    

    you can try it!

    0 讨论(0)
提交回复
热议问题