diff options
Diffstat (limited to 'www/js/ModalCtrl.js')
| -rw-r--r-- | www/js/ModalCtrl.js | 33 |
1 files changed, 31 insertions, 2 deletions
diff --git a/www/js/ModalCtrl.js b/www/js/ModalCtrl.js index c1ce47a9..9cba8697 100644 --- a/www/js/ModalCtrl.js +++ b/www/js/ModalCtrl.js @@ -303,8 +303,24 @@ angular.module('zmApp.controllers').controller('ModalCtrl', ['$scope', '$rootSco }; - // not being used anymore - using a dedicated menu instead + $scope.onTapLeft = function (m,d) + { + ZMDataModel.zmDebug("ModalCtrl:Left tap detected, moving to " + ZMDataModel.getNextMonitor(m, d)); + $scope.monitorId = ZMDataModel.getNextMonitor(m, d); + + + $ionicLoading.hide(); + $ionicLoading.show({ + template: "please wait...", + noBackdrop: true, + duration: zm.loadingTimeout, + }); + }; + $scope.onSwipeLeft = function (m, d) { + var ld = ZMDataModel.getLogin(); + if (!ld.canSwipeMonitors) return; + ZMDataModel.zmDebug("ModalCtrl:Left swipe detected, moving to " + ZMDataModel.getNextMonitor(m, d)); $scope.monitorId = ZMDataModel.getNextMonitor(m, d); @@ -315,11 +331,24 @@ angular.module('zmApp.controllers').controller('ModalCtrl', ['$scope', '$rootSco noBackdrop: true, duration: zm.loadingTimeout, }); + + }; - // not being used anymore - using a dedicated menu instead + $scope.onTapRight = function (m,d) + { + ZMDataModel.zmDebug("ModalCtrl:Right tap detected, moving to " + ZMDataModel.getNextMonitor(m, d)); + $scope.monitorId = ZMDataModel.getNextMonitor(m, d); + + $ionicLoading.show({ + template: "please wait...", + noBackdrop: true, + duration: zm.loadingTimeout, + }); + }; $scope.onSwipeRight = function (m, d) { + if (!ld.canSwipeMonitors) return; ZMDataModel.zmDebug("ModalCtrl:Right swipe detected, moving to " + ZMDataModel.getNextMonitor(m, d)); $scope.monitorId = ZMDataModel.getNextMonitor(m, d); |
