Merge pull request #5166 from fredj/simplify_measure_example

Remove jquery dependency from measure example
This commit is contained in:
Frédéric Junod committed 2016-04-04 16:31:45 +02:00
commit e36ffca838
2 files changed
+3 -5

No files matched your search

-2
View File
@@ -5,8 +5,6 @@ shortdesc: Example of using the ol.interaction.Draw interaction to create a simp
docs: >
<p><i>NOTE: By default, length and area are calculated using the projected coordinates. This is not accurate for projections like Mercator where the projected meters do not correspond to meters on the ground. To get a standarized measurement across all projections, use the geodesic measures.</i></p>
tags: "draw, edit, measure, vector"
resources:
- https://code.jquery.com/jquery-1.11.2.min.js
---
<div id="map" class="map"></div>
<form class="form-inline">
+3 -3
View File
@@ -117,7 +117,7 @@ var pointerMoveHandler = function(evt) {
helpTooltipElement.innerHTML = helpMsg;
helpTooltip.setPosition(evt.coordinate);
$(helpTooltipElement).removeClass('hidden');
helpTooltipElement.classList.remove('hidden');
};
@@ -132,8 +132,8 @@ var map = new ol.Map({
map.on('pointermove', pointerMoveHandler);
$(map.getViewport()).on('mouseout', function() {
$(helpTooltipElement).addClass('hidden');
map.getViewport().addEventListener('mouseout', function() {
helpTooltipElement.classList.add('hidden');
});
var typeSelect = document.getElementById('type');