Commit 3c46c8a7 authored by Bastien Zigmann's avatar Bastien Zigmann

L'écran suit désormais le point plus rapidemant lors la localisation

parent 0ce2e885
......@@ -24,7 +24,7 @@
</value>
</option>
</component>
<component name="ProjectRootManager" version="2" languageLevel="JDK_1_8" project-jdk-name="1.8" project-jdk-type="JavaSDK">
<component name="ProjectRootManager" version="2" languageLevel="JDK_1_7" project-jdk-name="1.8" project-jdk-type="JavaSDK">
<output url="file://$PROJECT_DIR$/build/classes" />
</component>
<component name="ProjectType">
......
......@@ -1482,7 +1482,9 @@ class Geocropping {
// highway ??
// Requete overpass (actuellement récuépérer les node ayant au moins un tag)
let query = `[out:json];node[~"."~"."](around:${distance},${lat},${lon})->.nodes;/*way(around:${distance},${lat},${lon})->.ways;*/.nodes out meta;/*.ways out geom meta;*/`;
if (!this._app_click_position_actived) {
this._map.setMaxBounds(L.latLngBounds(this._lastUserLocation, this._lastUserLocation));
}
$.ajax({
context: this,
url: this._app_server_interpreter_list[this._app_server_interpreter_index],
......@@ -1545,10 +1547,11 @@ class Geocropping {
//this._map.setMaxBounds(this._geoJSONLayers.getBounds());
//} else {
//this._map.panTo(pos);
if (!this._app_click_position_actived) {
this._map.setMaxBounds(L.latLngBounds(this._lastUserLocation, this._lastUserLocation));
}
// --------------------------- CHANGER ICI ------------------------
// if (!this._app_click_position_actived) {
// this._map.setMaxBounds(L.latLngBounds(this._lastUserLocation, this._lastUserLocation));
// }
// --------------------------- mettre ça au début de la fonction
// Récupérer les notes des élément
//this._updateNoteOfElements();
......
......@@ -799,6 +799,9 @@ var Geocropping = (function () {
var lat = pos.lat, lon = pos.lng;
var distance = this._app_distance_hide < this._app_distance_search ? this._app_distance_hide : this._app_distance_search;
var query = "[out:json];node[~\".\"~\".\"](around:" + distance + "," + lat + "," + lon + ")->.nodes;/*way(around:" + distance + "," + lat + "," + lon + ")->.ways;*/.nodes out meta;/*.ways out geom meta;*/";
if (!this._app_click_position_actived) {
this._map.setMaxBounds(L.latLngBounds(this._lastUserLocation, this._lastUserLocation));
}
$.ajax({
context: this,
url: this._app_server_interpreter_list[this._app_server_interpreter_index],
......@@ -842,9 +845,6 @@ var Geocropping = (function () {
_this._searchInfoElementsOSMAround().then(function (data) {
_this._updateElementsDisplayedAround(data);
});
if (!_this._app_click_position_actived) {
_this._map.setMaxBounds(L.latLngBounds(_this._lastUserLocation, _this._lastUserLocation));
}
}
},
error: function (jqXHR, textStatus, errorThrown) {
......
This source diff could not be displayed because it is too large. You can view the blob instead.
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment