diff options
Diffstat (limited to 'www/js/ModalCtrl.js')
| -rw-r--r-- | www/js/ModalCtrl.js | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/www/js/ModalCtrl.js b/www/js/ModalCtrl.js index 3a130363..dea908d8 100644 --- a/www/js/ModalCtrl.js +++ b/www/js/ModalCtrl.js @@ -347,10 +347,26 @@ angular.module('zmApp.controllers').controller('ModalCtrl', ['$scope', '$rootSco }); }; + + $scope.getZoomLevel = function() + { + console.log ("ON RELEASE"); + var zl = $ionicScrollDelegate.$getByHandle("imgscroll").getScrollPosition(); + console.log (JSON.stringify(zl)); + }; + $scope.onSwipeLeft = function (m, d) { var ld = ZMDataModel.getLogin(); if (!ld.canSwipeMonitors) return; + if + ($ionicScrollDelegate.$getByHandle("imgscroll").getScrollPosition().zoom!=1) + { + console.log("Image is zoomed in - not honoring swipe"); + return; + } + + var curstate = $ionicHistory.currentStateName(); var found=0; var mid; @@ -439,6 +455,14 @@ angular.module('zmApp.controllers').controller('ModalCtrl', ['$scope', '$rootSco }; $scope.onSwipeRight = function (m, d) { if (!ld.canSwipeMonitors) return; + + if + ($ionicScrollDelegate.$getByHandle("imgscroll").getScrollPosition().zoom!=1) + { + console.log("Image is zoomed in - not honoring swipe"); + return; + } + var found=0; var mid; var curstate = $ionicHistory.currentStateName(); |
