reverts changes to dist in d82fe9d057
This commit is contained in:
parent
495082c29e
commit
68c68f3a02
14
dist/torque.full.js
vendored
14
dist/torque.full.js
vendored
File diff suppressed because one or more lines are too long
6
dist/torque.js
vendored
6
dist/torque.js
vendored
File diff suppressed because one or more lines are too long
15
dist/torque.uncompressed.js
vendored
15
dist/torque.uncompressed.js
vendored
@ -29,11 +29,10 @@ var cancelAnimationFrame = global.cancelAnimationFrame
|
||||
this._t0 = +new Date();
|
||||
this.callback = callback;
|
||||
this._time = 0.0;
|
||||
|
||||
this.options = torque.extend({
|
||||
animationDelay: 0,
|
||||
maxDelta: 0.2,
|
||||
loop: options.loop || true
|
||||
loop: true
|
||||
}, this.options);
|
||||
|
||||
this.rescale();
|
||||
@ -121,9 +120,6 @@ var cancelAnimationFrame = global.cancelAnimationFrame
|
||||
this.time(this._time);
|
||||
if(this.step() >= this.options.steps) {
|
||||
this._time = 0;
|
||||
if(!this.options.loop){
|
||||
this.stop();
|
||||
}
|
||||
}
|
||||
if(this.running) {
|
||||
requestAnimationFrame(this._tick);
|
||||
@ -2540,14 +2536,7 @@ L.TorqueLayer = L.CanvasLayer.extend({
|
||||
var c = tile._tileCache = document.createElement('canvas');
|
||||
c.width = c.height = tile_size;
|
||||
pos = this.getTilePos(tile.coord);
|
||||
// clip bounds, firefox raise an exception when try to get data from outside canvas
|
||||
var x = Math.max(0, pos.x)
|
||||
var y = Math.max(0, pos.y)
|
||||
var w = Math.min(tile_size, this.getCanvas().width - x);
|
||||
var h = Math.min(tile_size, this.getCanvas().height - y);
|
||||
if (w > 0 && h > 0) {
|
||||
c.getContext('2d').drawImage(this.getCanvas(), x, y, w, h, x - pos.x, y - pos.y, w, h);
|
||||
}
|
||||
c.getContext('2d').drawImage(this.getCanvas(), pos.x, pos.y, tile_size, tile_size, 0, 0, tile_size, tile_size);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user