aparshin / leaflet-boundary-canvas

Leaflet plugin to draw raster layers with arbitrary boundary
MIT License
170 stars 41 forks source link

tiles wont load wile reusetiles option used. #8

Closed chanakyap closed 9 years ago

chanakyap commented 9 years ago

When i set maxBounds to my map and use reuseTiles option for my L.TileLayer.boundarycanvas, if i pan out so my tiles are invisible, map will automatically pan to fit the max bounds and after this the tile layer wont load. so i removed reuseTiles option and it is working fine.

aparshin commented 9 years ago

Looks like reuseTiles option is a key to this issue.

BoundaryCanvas plugin is based on L.TileLayer.Canvas for Leaflet version < 0.8. That class doesn't work with reuseTiles option correctly (you can check it using this example). Looks like the best way is to fix it in L.TileLayer.Canvas, but I'm not ready to handle this right now...

And there is no such option in Leaflet v0.8 at all (don't know why)!

aparshin commented 9 years ago

I'm closing this issue, but will be glad to any PR!