Skip to content

Commit

Permalink
Merge pull request #69 from levblanc/master
Browse files Browse the repository at this point in the history
fix: change const keyword to var
  • Loading branch information
sandstrom committed Aug 29, 2018
2 parents 9fe5384 + 75a0084 commit fc8c60a
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/pinch-zoom.js
Original file line number Diff line number Diff line change
Expand Up @@ -506,11 +506,11 @@ var definePinchZoom = function () {
* @return {Object} the current zoom center
*/
getCurrentZoomCenter: function () {
const offsetLeft = this.offset.x - this.initialOffset.x;
const centerX = -1 * this.offset.x - offsetLeft / (1 / this.zoomFactor - 1);
var offsetLeft = this.offset.x - this.initialOffset.x;
var centerX = -1 * this.offset.x - offsetLeft / (1 / this.zoomFactor - 1);

const offsetTop = this.offset.y - this.initialOffset.y;
const centerY = -1 * this.offset.y - offsetTop / (1 / this.zoomFactor - 1);
var offsetTop = this.offset.y - this.initialOffset.y;
var centerY = -1 * this.offset.y - offsetTop / (1 / this.zoomFactor - 1);

return {
x: centerX,
Expand Down

0 comments on commit fc8c60a

Please sign in to comment.