leaflet-rails 0.7.5 → 0.7.7

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: a2eb78713472675e95e253b537d1546f4544ebd9
4
- data.tar.gz: e35af587a0284da1b5c60143fb8970864c547d1a
3
+ metadata.gz: bf01f44ecedf015f090bdba9dbff3406f05ecfae
4
+ data.tar.gz: a0607e4587fd7e71c7eb8927ed486a6589c8e3f6
5
5
  SHA512:
6
- metadata.gz: a644f995dedb93ce3a620f8688c3cfb078b14030ee50b53b5794660761fbeed0d7de8bdcbe4c9ce56f068c0d3197b94da50a538c2a41989a651b6b496a0e7d66
7
- data.tar.gz: 2fbda3b24c04f36bbdac8aed3b05f72fa8ad576996fe3f19c6ec79a409a01fdd0a5fbf258560d4c91499512f0b12a26f7443e71b63dcd42e217605ce6cb028db
6
+ metadata.gz: f5557c3697b9aa7d5deca1e57a2b80ce5f81ee884be32e10ed6881ba1aebd6994c566b5baa83aceabda319b421918d50fa4a2a87adc802f5c53baeff0ca5c190
7
+ data.tar.gz: 6f0a93e1719f7b1567803dbb0fed12a8c6109197c338275ce789e02accd3dd56ae3b639c02cd0084615f97c88a2cc6ab10055dbc5b25218c761230852825d7f2
@@ -1,11 +1,12 @@
1
+ sudo: false
1
2
  language: ruby
2
3
  rvm:
3
- - 1.9.3
4
- - jruby-19mode
5
- - rbx-19mode
6
4
  - ruby-head
7
5
  - jruby-head
8
6
  - 2.0.0
7
+ - 2.1.8
8
+ - 2.2.4
9
+ - 2.3.0
9
10
  matrix:
10
11
  allow_failures:
11
12
  - rvm: ruby-head
data/README.md CHANGED
@@ -26,15 +26,6 @@ After that, open your application-wide Javascript file (typically `app/assets/ja
26
26
 
27
27
  At this point, you may skip the first two steps of the [Leaflet Quick Start guide](http://leafletjs.com/examples/quick-start.html) and start at the third step (adding the map `div` to a view).
28
28
 
29
- *Rails 4.1+*
30
-
31
- If you are using Rails 4.1+ you will need to open your application-wide CSS file (`app/assets/stylesheets/application.css`) and add the following lines at the top:
32
-
33
- ```
34
- //= depend_on_asset "layers.png"
35
- //= depend_on_asset "layers-2x.png"
36
- ```
37
-
38
29
 
39
30
  Version Parity
40
31
  ==============
@@ -45,6 +36,8 @@ leaflet-rails tries to keep version parity with leaflet.js. However, this isn't
45
36
  | ------------- | ------------- | ------|
46
37
  | 0.7.4 | 0.7.3 | Requested in #33 because of large gap between master and rubygems.org.|
47
38
  | 0.7.5 | 0.7.5 | leaflet.js 0.7.4 was reverted. |
39
+ | 0.7.6 | ---- | Skipped to sync with upstream. |
40
+ | 0.7.7 | 0.7.7 | Sync version numbers with upstream. |
48
41
 
49
42
 
50
43
  Helpers
@@ -1,5 +1,5 @@
1
1
  module Leaflet
2
2
  module Rails
3
- VERSION = "0.7.5"
3
+ VERSION = "0.7.7"
4
4
  end
5
5
  end
@@ -12,7 +12,7 @@
12
12
  var oldL = window.L,
13
13
  L = {};
14
14
 
15
- L.version = '0.7.5';
15
+ L.version = '0.7.7';
16
16
 
17
17
  // define Leaflet for Node module pattern loaders, including Browserify
18
18
  if (typeof module === 'object' && typeof module.exports === 'object') {
@@ -525,7 +525,7 @@ L.Mixin.Events.fire = L.Mixin.Events.fireEvent;
525
525
 
526
526
  mobile = typeof orientation !== undefined + '',
527
527
  msPointer = !window.PointerEvent && window.MSPointerEvent,
528
- pointer = (window.PointerEvent && window.navigator.pointerEnabled && window.navigator.maxTouchPoints) ||
528
+ pointer = (window.PointerEvent && window.navigator.pointerEnabled) ||
529
529
  msPointer,
530
530
  retina = ('devicePixelRatio' in window && window.devicePixelRatio > 1) ||
531
531
  ('matchMedia' in window && window.matchMedia('(min-resolution:144dpi)') &&
@@ -4392,7 +4392,9 @@ L.FeatureGroup = L.LayerGroup.extend({
4392
4392
  layer = this._layers[layer];
4393
4393
  }
4394
4394
 
4395
- layer.off(L.FeatureGroup.EVENTS, this._propagateEvent, this);
4395
+ if ('off' in layer) {
4396
+ layer.off(L.FeatureGroup.EVENTS, this._propagateEvent, this);
4397
+ }
4396
4398
 
4397
4399
  L.LayerGroup.prototype.removeLayer.call(this, layer);
4398
4400
 
@@ -4712,7 +4714,7 @@ L.Path = L.Path.extend({
4712
4714
  },
4713
4715
 
4714
4716
  _fireMouseEvent: function (e) {
4715
- if (!this.hasEventListeners(e.type)) { return; }
4717
+ if (!this._map || !this.hasEventListeners(e.type)) { return; }
4716
4718
 
4717
4719
  var map = this._map,
4718
4720
  containerPoint = map.mouseEventToContainerPoint(e),
@@ -7170,8 +7172,9 @@ L.extend(L.DomEvent, {
7170
7172
  pointers = this._pointers;
7171
7173
 
7172
7174
  var cb = function (e) {
7173
-
7174
- L.DomEvent.preventDefault(e);
7175
+ if (e.pointerType !== 'mouse' && e.pointerType !== e.MSPOINTER_TYPE_MOUSE) {
7176
+ L.DomEvent.preventDefault(e);
7177
+ }
7175
7178
 
7176
7179
  var alreadyInArray = false;
7177
7180
  for (var i = 0; i < pointers.length; i++) {
@@ -8942,11 +8945,13 @@ L.Map.include(!L.DomUtil.TRANSITION ? {} : {
8942
8945
 
8943
8946
  L.DomUtil.removeClass(this._mapPane, 'leaflet-zoom-anim');
8944
8947
 
8945
- this._resetView(this._animateToCenter, this._animateToZoom, true, true);
8948
+ L.Util.requestAnimFrame(function () {
8949
+ this._resetView(this._animateToCenter, this._animateToZoom, true, true);
8946
8950
 
8947
- if (L.Draggable) {
8948
- L.Draggable._disabled = false;
8949
- }
8951
+ if (L.Draggable) {
8952
+ L.Draggable._disabled = false;
8953
+ }
8954
+ }, this);
8950
8955
  }
8951
8956
  });
8952
8957
 
@@ -24,6 +24,7 @@
24
24
  .leaflet-container {
25
25
  overflow: hidden;
26
26
  -ms-touch-action: none;
27
+ touch-action: none;
27
28
  }
28
29
  .leaflet-tile,
29
30
  .leaflet-marker-icon,
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: leaflet-rails
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.7.5
4
+ version: 0.7.7
5
5
  platform: ruby
6
6
  authors:
7
7
  - Akshay Joshi