Commit Graph

72 Commits

Author SHA1 Message Date
Vladimir Agafonkin
4e44e12ecf add basic marker click test 2015-03-02 19:33:39 +02:00
Yohan Boniface
5b3ba078bf Do not try to remove drag class if marker as no icon
Since 4c46abe781 it's possible
to have a marker off the map with dragging still enabled.
We want to be able to disable it in this situation too.
2015-02-13 17:53:23 +01:00
John Firebaugh
21701a6fae Remove test specific to old zoom code 2015-02-06 16:36:43 -08:00
Vladimir Agafonkin
d145b1fdba fix a bunch of eslint warnings in the spec suite 2015-01-28 19:32:27 +02:00
Stefan Sydow
4c46abe781 preserve dragable state on layer deactivation 2015-01-19 19:07:04 +01:00
John Firebaugh
bad49e7612 Add autoClose option to Popup
Fixes #2716
Fixes #1853
2014-11-12 12:52:50 -08:00
John Firebaugh
d2871e68e5 Add test for #3008 2014-11-12 10:53:26 -08:00
John Firebaugh
68f86d85d3 Better fix for tile pruning
Need to always prune in _addTiles, otherwise tiles can
get stranded.
2014-11-07 16:27:42 -08:00
Jeff Smale
c6dea37d86 Preserve marker draggability on setIcon (fixes #2578) 2014-11-05 18:12:21 -08:00
John Firebaugh
e6d857eb70 jshint 2014-11-05 15:22:49 -08:00
John Firebaugh
ea2c397523 No-op bringToFront/Back when Path is not on a map (fixes #2439) 2014-11-05 15:13:28 -08:00
Vladimir Agafonkin
0c70dcb581 remove slow tests 2014-10-29 17:20:06 +02:00
Yohan Boniface
1ddac9361a Fix array of array of LatLngs toGeoJSON edge case 2014-10-26 21:00:56 +01:00
Vladimir Agafonkin
2ff2c42847 move some GridLayer tests, add createTile stub 2014-10-23 12:58:29 +03:00
Tom MacWright
74133f49f0 Fix MarkerSpec in retina browsers. 2014-10-21 12:21:29 +03:00
bennlich
4eb033c719 Included leaflet.css in html instead of TileLayerSpec.js 2014-07-31 23:43:14 -06:00
bennlich
abfcd9ea59 Added TileLayerSpec.js tests for loading events 2014-07-31 15:38:21 -06:00
Vladimir Agafonkin
1a7b12604b run view reset before load, fix #2510 2014-03-05 23:27:32 +02:00
danzel
8cc7404f53 This should be oldLatLng, even if latlng is wrong, let's have this be right. refs #2412 #1423 2014-01-29 14:51:55 +13:00
danzel
e2d9a97836 Add oldLatlng parameter to Marker move event, will allow MarkerCluster to support moving markers. 2014-01-29 11:33:08 +13:00
Vladimir Agafonkin
dab0cbfc14 update tests to reflect no clamping near poles 2014-01-03 17:37:28 +02:00
Vladimir Agafonkin
7ff0fa9c72 approximate Circle with ellipse 2014-01-03 00:37:34 +02:00
Vladimir Agafonkin
6d1142a978 only propagate events if given true to fire, #2311 2013-12-18 23:23:22 -05:00
Vladimir Agafonkin
33e23a69e7 fix specs for polygon holes 2013-12-18 12:03:22 -05:00
Vladimir Agafonkin
dc5151b81a fix GeoJSON roundtripping 2013-12-18 12:03:22 -05:00
John Firebaugh
af9302ce19 Make GridLayer methods safe to call pre-setView 2013-12-13 18:01:06 -05:00
John Firebaugh
c1654c4626 Add hasLayer tests 2013-12-13 17:51:37 -05:00
Vladimir Agafonkin
04c95e1af9 basic GridLayer spec, move TileLayer spec 2013-12-02 19:18:08 +02:00
Vladimir Agafonkin
91c039b7aa jshinting and major clean up of specs code, ref #2151 2013-11-07 23:54:33 +02:00
Vladimir Agafonkin
5d6641360b merge GeoJSON altitude pull with some tweaks #1822 2013-11-06 23:17:14 +02:00
Alexander Parshin
f5de36e229 Add holes support to L.Polygon.setLatLngs(). Fixes #1518 2013-10-13 20:17:12 +04:00
Tom MacWright
befc5eb992 Add support for layers lacking Events mixin. Fixes #1962 2013-09-17 17:36:05 -04:00
Vladimir Agafonkin
a086b336b2 fix images 404 warnings in specs 2013-09-12 13:14:00 +03:00
Vladimir Agafonkin
5e30c51f85 add GeoJSON rountripping of GeometryCollection and MultiPoint, close #1956 2013-08-28 12:43:04 +03:00
Vladimir Agafonkin
75c133082c fix Map min/maxZoom not overriding TileLayer-derived min/max, close #1848 2013-07-12 15:05:59 +03:00
danzel
ec3b9e0ff2 Add a few more featuregroup tests and fix regression of removeLayer. 2013-07-12 10:13:25 +12:00
Hans Kristian Flaatten
46885de00d Adds support for altitude and 3D GeoJSON
This commit adds a third parameter to the L.LatLon class for specifying
altitude. This is in turn stored in the `.latitude` property for the LatLng
instance. Latitude property will only be set if the latitude parameter is not
undefined, this is done in order to ensure backwards compability.

```javascript
var latlng = new L.LatLng(10, 20, 30);
console.log(latlng.altitude); // prints '30' to the console
```

Similar functionality has been added to L.GeoJSON coordsToLatLng() and
latLngToCoords() methods in order to handle import and export of 3D GeoJSON.

```javascript
var geoJSON = {
  type: 'Feature'
  ,properties: {}
  ,geometry: {
    type: 'Point'
    ,coordinates: [20, 10, 30]
  }
}
var layer = new L.GeoJSON();
layer.addData(geoJSON);
console.log(layer.getLayers()[0].getLatLng().altitude);
```

`NB` It is important to notice that no logic has been added in order to prevent
latitude and longitude to change without appropirate change in altitude – this
must be handled by the application.
2013-07-03 10:13:00 +02:00
John Firebaugh
475e736346 Revert "Consistent mouse event propagation in Marker and Path"
This reverts commit 4015f49615.
2013-06-28 16:22:20 -04:00
John Firebaugh
4015f49615 Consistent mouse event propagation in Marker and Path
Marker was missing mouseup and mousemove.
Path was missing mouseup.
2013-06-28 14:44:10 -04:00
Vladimir Agafonkin
cdc65c6c6b add Circle & CircleMarker toGeoJSON 2013-06-25 12:43:22 -04:00
John Firebaugh
2c22d13ab8 Fix test 2013-06-24 14:39:23 -04:00
John Firebaugh
e7d0fb1b37 Normalize all toGeoJSON output to Features 2013-06-24 14:30:24 -04:00
danzel
19d49e027f Add another test for marker/shadow reuse 2013-06-24 08:54:40 +12:00
Paul Bonaud
1af9769ed0 Toggle the display of a marker s popup on click 2013-06-16 22:13:31 +02:00
danzel
1a1cfb2e60 Make Marker setIcon unit tests better. 2013-06-12 16:18:20 +12:00
danzel
fa45913505 Make Icon/DivIcon reuse not try reuse the wrong dom element type. 2013-06-12 16:05:42 +12:00
danzel
7f2eff363b Add support to DivIcon for reusing a div. Fixes #1753. Still issues remain (Can't change a marker with a DivIcon to have an image Icon or vice versa) 2013-06-12 15:55:03 +12:00
John Firebaugh
ade9c943ff Popup-specific closeOnClick option 2013-05-10 15:22:03 -07:00
John Firebaugh
c9e2453eed Bounds-check array access in Polygon#initialize 2013-05-02 16:17:04 -07:00
Vladimir Agafonkin
7cb7993571 simplify popup methods, merge #738 2013-04-20 16:58:42 +03:00