久久久久久久av_日韩在线中文_看一级毛片视频_日本精品二区_成人深夜福利视频_武道仙尊动漫在线观看

<small id='kS0D8'></small><noframes id='kS0D8'>

<i id='kS0D8'><tr id='kS0D8'><dt id='kS0D8'><q id='kS0D8'><span id='kS0D8'><b id='kS0D8'><form id='kS0D8'><ins id='kS0D8'></ins><ul id='kS0D8'></ul><sub id='kS0D8'></sub></form><legend id='kS0D8'></legend><bdo id='kS0D8'><pre id='kS0D8'><center id='kS0D8'></center></pre></bdo></b><th id='kS0D8'></th></span></q></dt></tr></i><div class="qwawimqqmiuu" id='kS0D8'><tfoot id='kS0D8'></tfoot><dl id='kS0D8'><fieldset id='kS0D8'></fieldset></dl></div>
  • <tfoot id='kS0D8'></tfoot>

    1. <legend id='kS0D8'><style id='kS0D8'><dir id='kS0D8'><q id='kS0D8'></q></dir></style></legend>

        <bdo id='kS0D8'></bdo><ul id='kS0D8'></ul>
      1. 我可以防止將傳單地圖平移出世界邊緣嗎?

        Can I prevent panning Leaflet map out of the world#39;s edge?(我可以防止將傳單地圖平移出世界邊緣嗎?)

              <bdo id='IRoiU'></bdo><ul id='IRoiU'></ul>
              <i id='IRoiU'><tr id='IRoiU'><dt id='IRoiU'><q id='IRoiU'><span id='IRoiU'><b id='IRoiU'><form id='IRoiU'><ins id='IRoiU'></ins><ul id='IRoiU'></ul><sub id='IRoiU'></sub></form><legend id='IRoiU'></legend><bdo id='IRoiU'><pre id='IRoiU'><center id='IRoiU'></center></pre></bdo></b><th id='IRoiU'></th></span></q></dt></tr></i><div class="qwawimqqmiuu" id='IRoiU'><tfoot id='IRoiU'></tfoot><dl id='IRoiU'><fieldset id='IRoiU'></fieldset></dl></div>
                <tbody id='IRoiU'></tbody>
                  <legend id='IRoiU'><style id='IRoiU'><dir id='IRoiU'><q id='IRoiU'></q></dir></style></legend>
                  <tfoot id='IRoiU'></tfoot>
                • <small id='IRoiU'></small><noframes id='IRoiU'>

                  本文介紹了我可以防止將傳單地圖平移出世界邊緣嗎?的處理方法,對(duì)大家解決問題具有一定的參考價(jià)值,需要的朋友們下面隨著小編來一起學(xué)習(xí)吧!

                  問題描述

                  限時(shí)送ChatGPT賬號(hào)..

                  有沒有辦法限制平移出世界邊緣?在這張照片上,棕色是世界,灰色是空虛.我想讓它不可能像這樣平移.

                  Is there a way to limit panning out of the world's edge? On this picture, brown is the world, grey is emptiness. I want to make it impossible to pan like this.

                  推薦答案

                  Leaflet 允許您使用 maxBoundsViscosity 選項(xiàng)(值:0 到 1)控制地圖抵抗被拖出邊界的程度.將其設(shè)置為最大值將完全禁用拖出邊界.

                  Leaflet allows you to control how much the map resists being dragged out of bounds with the maxBoundsViscosity option (value: 0 to 1). Setting it to maximum disables dragging out of bounds entirely.

                  var map = new L.Map('map', {
                    center: bounds.getCenter(),
                    zoom: 5,
                    layers: [osm],
                    maxBounds: bounds,
                    maxBoundsViscosity: 1.0
                  });
                  

                  此功能在 1.0.0 中可用.相關(guān)拉取請(qǐng)求 包括 一個(gè)工作示例:

                  This feature is available in 1.0.0. The relevant pull request includes a working example:

                  var osmUrl = 'http://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png',
                    osmAttrib = '&copy; <a >OpenStreetMap</a> contributors',
                    osm1 = L.tileLayer(osmUrl, {
                      maxZoom: 18,
                      attribution: osmAttrib
                    }),
                    osm2 = L.tileLayer(osmUrl, {
                      maxZoom: 18,
                      attribution: osmAttrib
                    }),
                    bounds = new L.LatLngBounds(new L.LatLng(49.5, -11.3), new L.LatLng(61.2, 2.5));
                  
                  var map1 = new L.Map('map1', {
                    center: bounds.getCenter(),
                    zoom: 5,
                    layers: [osm1],
                    maxBounds: bounds,
                    maxBoundsViscosity: 0.75
                  });
                  
                  var map2 = new L.Map('map2', {
                    center: bounds.getCenter(),
                    zoom: 5,
                    layers: [osm2],
                    maxBounds: bounds,
                    maxBoundsViscosity: 1.0
                  });
                  
                  var latlngs = L.rectangle(bounds).getLatLngs();
                  L.polyline(latlngs[0].concat(latlngs[0][0])).addTo(map1);
                  L.polyline(latlngs[0].concat(latlngs[0][0])).addTo(map2);

                  html,
                  body,
                  #map {
                    margin: 0;
                    padding: 0;
                    width: 100%;
                    height: 100%;
                  }

                  <link rel="stylesheet"  />
                  <script src="https://unpkg.com/leaflet@1.0.0/dist/leaflet.js"></script>
                  
                  <h1>Left: Bouncy maxBounds. Right: Not bouncy.</h1>
                  
                  <div id="map1" style="float: left; width:45%; height: 80%;"></div>
                  <div id="map2" style="float: left; width:45%; height: 80%;"></div>

                  這篇關(guān)于我可以防止將傳單地圖平移出世界邊緣嗎?的文章就介紹到這了,希望我們推薦的答案對(duì)大家有所幫助,也希望大家多多支持html5模板網(wǎng)!

                  【網(wǎng)站聲明】本站部分內(nèi)容來源于互聯(lián)網(wǎng),旨在幫助大家更快的解決問題,如果有圖片或者內(nèi)容侵犯了您的權(quán)益,請(qǐng)聯(lián)系我們刪除處理,感謝您的支持!

                  相關(guān)文檔推薦

                  Browserify, Babel 6, Gulp - Unexpected token on spread operator(Browserify,Babel 6,Gulp - 傳播運(yùn)算符上的意外令牌)
                  Is it possible to pass a flag to Gulp to have it run tasks in different ways?(是否可以將標(biāo)志傳遞給 Gulp 以使其以不同的方式運(yùn)行任務(wù)?)
                  Why do we need to install gulp globally and locally?(為什么我們需要在全局和本地安裝 gulp?)
                  How to run Gulp tasks sequentially one after the other(如何一個(gè)接一個(gè)地依次運(yùn)行 Gulp 任務(wù))
                  Visual Studio 2015 crashes when opening Javascript files(打開 Javascript 文件時(shí) Visual Studio 2015 崩潰)
                  Detect FLASH plugin crashes(檢測(cè) FLASH 插件崩潰)
                • <small id='R3RRY'></small><noframes id='R3RRY'>

                      <bdo id='R3RRY'></bdo><ul id='R3RRY'></ul>

                      <tfoot id='R3RRY'></tfoot>

                      <legend id='R3RRY'><style id='R3RRY'><dir id='R3RRY'><q id='R3RRY'></q></dir></style></legend>

                        <tbody id='R3RRY'></tbody>

                          <i id='R3RRY'><tr id='R3RRY'><dt id='R3RRY'><q id='R3RRY'><span id='R3RRY'><b id='R3RRY'><form id='R3RRY'><ins id='R3RRY'></ins><ul id='R3RRY'></ul><sub id='R3RRY'></sub></form><legend id='R3RRY'></legend><bdo id='R3RRY'><pre id='R3RRY'><center id='R3RRY'></center></pre></bdo></b><th id='R3RRY'></th></span></q></dt></tr></i><div class="qwawimqqmiuu" id='R3RRY'><tfoot id='R3RRY'></tfoot><dl id='R3RRY'><fieldset id='R3RRY'></fieldset></dl></div>

                            主站蜘蛛池模板: 综合激情av | 亚洲国产精品一区二区三区 | 中文字幕一区二区三区日韩精品 | 狠狠色网 | 伊人久久大香线 | 精品在线一区二区 | 国产九九九 | 九色在线 | 久久精品99国产精品 | 成人精品毛片国产亚洲av十九禁 | 第四色播日韩第一页 | 亚洲欧美日本在线 | 日韩在线观看视频一区 | 久久久精品一区二区 | 久久久综合精品 | 国产欧美日韩一区 | 欧美精品一区二区在线观看 | 午夜男人天堂 | 精品视频在线一区 | 中文字幕欧美一区二区 | 91精品综合久久久久久五月天 | 色综合天天天天做夜夜夜夜做 | 亚洲电影第三页 | 91麻豆精品国产91久久久久久 | 99这里只有精品视频 | 亚洲视频欧美视频 | 久久国产亚洲 | 91精品国产美女在线观看 | 91麻豆精品国产91久久久更新资源速度超快 | www.成人.com| 国产成人精品一区二 | 亚洲欧美国产精品久久 | 国产精品久久久久久久模特 | 夜夜夜夜夜夜曰天天天 | 综合久久av | 特级毛片爽www免费版 | 少妇精品亚洲一区二区成人 | 欧美日韩成人一区二区 | 亚洲一区二区av | 日韩成人一区 | 成人免费网站 |