From 1edbe75bf8d72023e639cff788c9c04df5c4d936 Mon Sep 17 00:00:00 2001 From: Vincent Vanwaelscappel Date: Wed, 28 Jun 2017 19:33:56 +0200 Subject: [PATCH] #1471 --- js/libs/fluidbook/fluidbook.touch.js | 16 ++++++++++------ 1 file changed, 10 insertions(+), 6 deletions(-) diff --git a/js/libs/fluidbook/fluidbook.touch.js b/js/libs/fluidbook/fluidbook.touch.js index ac1b824e..85a2d464 100644 --- a/js/libs/fluidbook/fluidbook.touch.js +++ b/js/libs/fluidbook/fluidbook.touch.js @@ -17,12 +17,16 @@ FluidbookTouch.prototype = { init: function () { var $this = this; - // Disable native zoom - document.addEventListener('touchmove', function (event) { - if (event.scale !== 1) { - event.preventDefault(); - } - }, false); + // Disable native zoom #1471 + if (this.fluidbook.support.iOS) { + document.addEventListener('touchmove', function (event) { + event = event.originalEvent || event; + if (event.scale != undefined && event.scale !== 1) { + event.preventDefault(); + } + }, false); + } + $(this.fluidbook).on('fluidbook.page.change.end', function () { $this.resetSlide(); -- 2.39.5