diff options
| -rw-r--r-- | www/css/style.css | 9 | ||||
| -rw-r--r-- | www/js/ModalCtrl.js | 16 | ||||
| -rw-r--r-- | www/templates/monitors-modal.html | 6 |
3 files changed, 30 insertions, 1 deletions
diff --git a/www/css/style.css b/www/css/style.css index 384304b3..2a9e9098 100644 --- a/www/css/style.css +++ b/www/css/style.css @@ -302,6 +302,15 @@ http://www.cssportal.com/tryit/index.php?file=blog/css-notification-badge */ opacity:0.7; } +.desktop-zoom-icon +{ + position:absolute; + bottom:20px; + left:70px; + z-index:10; + opacity:0.7; +} + .modal-alarm-badge { position:absolute; diff --git a/www/js/ModalCtrl.js b/www/js/ModalCtrl.js index a4a75807..1deffdbb 100644 --- a/www/js/ModalCtrl.js +++ b/www/js/ModalCtrl.js @@ -1121,7 +1121,21 @@ angular.module('zmApp.controllers').controller('ModalCtrl', ['$scope', '$rootSco } - + $scope.zoomImage = function (val) + { + var zl = parseInt($ionicScrollDelegate.$getByHandle("imgscroll").getScrollPosition().zoom); + if (zl == 1 && val == -1) + { + ZMDataModel.zmDebug ("Already zoomed out max"); + return; + } + + + zl+=val; + ZMDataModel.zmDebug ("Zoom level is " + zl); $ionicScrollDelegate.$getByHandle("imgscroll").zoomTo(zl,true); + + }; + //-------------------------------------------------------- //Navigate to next/prev event in full screen mode diff --git a/www/templates/monitors-modal.html b/www/templates/monitors-modal.html index f035f6cd..cadd856c 100644 --- a/www/templates/monitors-modal.html +++ b/www/templates/monitors-modal.html @@ -83,6 +83,12 @@ <span class="camera-icon"> <a class="button icon ion-ios-camera button-positive" href="" ng-click="saveImageToPhone(monitorId)"></a> </span> + + <span ng-if="$root.platformOS == 'desktop'" class="desktop-zoom-icon"> + <a class="button icon ion-plus-round button-assertive" href="" ng-click="zoomImage(1)"></a> + <a class="button icon ion-minus-round button-assertive" href="" ng-click="zoomImage(-1)"></a> + + </span> <span class="modal-alarm-badge"> <a data-badge="{{$root.alarmCount}}" class="animated infinite tada button icon ion-ios-bell notification-badge button-assertive" |
