From e8a0d0aff0a5f28e9d014ba45a0020fc8e756fea Mon Sep 17 00:00:00 2001 From: Jack Reed Date: Sun, 19 Jul 2015 22:03:30 -0700 Subject: [PATCH 1/7] update to leaflet v1.0.0-beta1 --- examples/example.html | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/examples/example.html b/examples/example.html index c02be0f..a650e08 100644 --- a/examples/example.html +++ b/examples/example.html @@ -1,9 +1,9 @@ - + - + From 1bc48e4b88cd627b6ef4e8fbe0dc2cb192cc0808 Mon Sep 17 00:00:00 2001 From: Jack Reed Date: Sun, 19 Jul 2015 22:54:56 -0700 Subject: [PATCH 2/7] update to support leaflet-v1.0.0-beta1 --- leaflet-iiif.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/leaflet-iiif.js b/leaflet-iiif.js index 8f589eb..348adb6 100644 --- a/leaflet-iiif.js +++ b/leaflet-iiif.js @@ -35,7 +35,7 @@ L.TileLayer.Iiif = L.TileLayer.extend({ var _this = this, x = coords.x, y = (coords.y), - zoom = _this._map.getZoom(), + zoom = _this._getZoomForUrl(), scale = Math.pow(2, _this.maxNativeZoom - zoom), tileBaseSize = _this.options.tileSize * scale, minx = (x * tileBaseSize), @@ -193,9 +193,9 @@ L.TileLayer.Iiif = L.TileLayer.extend({ _templateUrl: function() { return this._infoToBaseUrl() + '{region}/{size}/{rotation}/{quality}.{format}'; }, - _tileShouldBeLoaded: function(coords) { + _isValidTile: function(coords) { var _this = this, - zoom = _this._map.getZoom(), + zoom = _this._getZoomForUrl(), sizes = _this._tierSizes[zoom], x = coords.x, y = (coords.y); From 4e3890618a559931dd0a016a4fcdf5efb47ad20f Mon Sep 17 00:00:00 2001 From: Jack Reed Date: Tue, 27 Sep 2016 10:20:45 -0400 Subject: [PATCH 3/7] update to leaflet v1.0.0 --- examples/example.html | 4 ++-- examples/manifest.html | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/examples/example.html b/examples/example.html index a650e08..452da6d 100644 --- a/examples/example.html +++ b/examples/example.html @@ -1,9 +1,9 @@ - + - + diff --git a/examples/manifest.html b/examples/manifest.html index 67aa31b..1fcd4d3 100644 --- a/examples/manifest.html +++ b/examples/manifest.html @@ -1,9 +1,9 @@ - + - + From d7d6e95efeababdb0f3b722d65de66934aea0b3e Mon Sep 17 00:00:00 2001 From: Jack Reed Date: Tue, 27 Sep 2016 10:21:03 -0400 Subject: [PATCH 4/7] maxzoom explicitly to an atainable zoom --- examples/iiif-example.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/examples/iiif-example.js b/examples/iiif-example.js index c103b44..46fd7cd 100644 --- a/examples/iiif-example.js +++ b/examples/iiif-example.js @@ -8,7 +8,7 @@ map = L.map('map', { stanfordMlk = L.tileLayer.iiif('https://stacks.stanford.edu/image/iiif/hg676jb4964%2F0380_796-44/info.json', { attribution: 'Martin Luther King Jr. & Joan Baez march to integrate schools, Grenada, MS, 1966', - maxZoom: 6 + maxZoom: 5 }).addTo(map); princetonMap = L.tileLayer.iiif('http://libimages.princeton.edu/loris2/pudl0076%2Fmap_pownall%2F00000001.jp2/info.json', { From bdab46ffed19def2d419ce1a7b56113a55a442c1 Mon Sep 17 00:00:00 2001 From: Jack Reed Date: Wed, 12 Oct 2016 13:08:17 -0400 Subject: [PATCH 5/7] update to Leaflet v1.0.1 --- examples/example.html | 4 ++-- examples/manifest.html | 4 ++-- package.json | 2 +- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/examples/example.html b/examples/example.html index 452da6d..0b83c83 100644 --- a/examples/example.html +++ b/examples/example.html @@ -1,9 +1,9 @@ - + - + diff --git a/examples/manifest.html b/examples/manifest.html index 1fcd4d3..cfe244d 100644 --- a/examples/manifest.html +++ b/examples/manifest.html @@ -1,9 +1,9 @@ - + - + diff --git a/package.json b/package.json index 7dcaf88..c6820f2 100644 --- a/package.json +++ b/package.json @@ -33,7 +33,7 @@ "karma": "^0.13.22", "karma-jasmine": "^0.3.7", "karma-phantomjs-launcher": "^1.0.0", - "leaflet": "^0.7.7", + "leaflet": "^1.0", "phantomjs-prebuilt": "^2.1.5" } } From 0de332adea83b5288f350f5ea77ad8af992df947 Mon Sep 17 00:00:00 2001 From: Jack Reed Date: Wed, 12 Oct 2016 13:11:44 -0400 Subject: [PATCH 6/7] update karma and jasmine --- package.json | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/package.json b/package.json index c6820f2..c53e7b9 100644 --- a/package.json +++ b/package.json @@ -28,10 +28,10 @@ "homepage": "https://github.com/mejackreed/Leaflet-IIIF", "devDependencies": { "http-server": "^0.9.0", - "jasmine": "^2.4.1", + "jasmine": "^2.5", "jquery": "^2.2.2", - "karma": "^0.13.22", - "karma-jasmine": "^0.3.7", + "karma": "^1.3", + "karma-jasmine": "^1.0", "karma-phantomjs-launcher": "^1.0.0", "leaflet": "^1.0", "phantomjs-prebuilt": "^2.1.5" From 1814840b547dfcbc38bb737b33c0da3b3ad5dbdd Mon Sep 17 00:00:00 2001 From: Jack Reed Date: Wed, 12 Oct 2016 13:12:39 -0400 Subject: [PATCH 7/7] cleanup listeners after tests --- spec/LTileLayerIiifSpec.js | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/spec/LTileLayerIiifSpec.js b/spec/LTileLayerIiifSpec.js index adfd44c..7e54f13 100644 --- a/spec/LTileLayerIiifSpec.js +++ b/spec/LTileLayerIiifSpec.js @@ -67,6 +67,10 @@ describe('L.TileLayer.Iiif', function() { iiifLayer = iiifLayerFactory(); }); + afterEach(function() { + iiifLayer.off('load'); + }); + it('by default is on', function(done) { map.addLayer(iiifLayer); iiifLayer.on('load', function() { @@ -91,6 +95,10 @@ describe('L.TileLayer.Iiif', function() { describe('quality', function() { var iiifLayer; + + afterEach(function() { + iiifLayer.off('load'); + }); it('by default is on', function(done) { iiifLayer = L.tileLayer.iiif('http://localhost:9876/base/fixtures/acrobat_info.json');