diff options
| author | Pliable Pixels <pliablepixels@gmail.com> | 2019-10-16 11:03:38 -0400 |
|---|---|---|
| committer | Pliable Pixels <pliablepixels@gmail.com> | 2019-10-16 11:03:38 -0400 |
| commit | b688f20a5ffa35bea6415b8d4f566d6cf7d9d6b0 (patch) | |
| tree | 862be68323c55962cafcfd29012dd3a91f7a8bf2 | |
| parent | 86ec31cc680fe51d13286adea5bbdbc398f7a4a5 (diff) | |
#854 toggle controls
| -rw-r--r-- | config.xml | 8 | ||||
| -rw-r--r-- | package.json | 8 | ||||
| -rw-r--r-- | www/js/EventModalCtrl.js | 5 | ||||
| -rw-r--r-- | www/js/MomentCtrl.js | 2 | ||||
| -rw-r--r-- | www/js/MonitorModalCtrl.js | 8 | ||||
| -rw-r--r-- | www/js/MontageCtrl.js | 14 | ||||
| -rw-r--r-- | www/js/NVR.js | 2 | ||||
| -rw-r--r-- | www/templates/events-modal.html | 8 | ||||
| -rw-r--r-- | www/templates/monitors-modal.html | 10 |
9 files changed, 48 insertions, 17 deletions
@@ -1,5 +1,5 @@ <?xml version='1.0' encoding='utf-8'?> -<widget android-packageName="com.pliablepixels.zmninja_pro" id="com.pliablepixels.zmninja_pro" ios-CFBundleIdentifier="com.pliablepixels.zmninja-pro" version="1.3.078" xmlns="http://www.w3.org/ns/widgets" xmlns:android="http://schemas.android.com/apk/res/android" xmlns:cdv="http://cordova.apache.org/ns/1.0"> +<widget android-packageName="com.pliablepixels.zmninja_pro" id="com.pliablepixels.zmninja_pro" ios-CFBundleIdentifier="com.pliablepixels.zmninja-pro" version="1.3.079" xmlns="http://www.w3.org/ns/widgets" xmlns:android="http://schemas.android.com/apk/res/android" xmlns:cdv="http://cordova.apache.org/ns/1.0"> <name>zmNinja</name> <description> High performance ZoneMinder client @@ -172,14 +172,14 @@ <plugin name="cordova-custom-config" spec="5.0.2" /> <plugin name="cordova-plugin-advanced-http" spec="git+https://github.com/silkimen/cordova-plugin-advanced-http.git" /> <plugin name="cordova-plugin-advanced-websocket" spec="1.1.5" /> - <plugin name="cordova-plugin-media-pp-fork" spec="^1.0.2-dev" /> <plugin name="cordova-plugin-add-swift-support" spec="1.7.2" /> <plugin name="cordova-plugin-photo-library" spec="https://github.com/pliablepixels/cordova-plugin-photo-library"> <variable name="PHOTO_LIBRARY_USAGE_DESCRIPTION" value=" " /> </plugin> - <engine name="ios" spec="4.5.5" /> - <engine name="android" spec="8.0.0" /> <plugin name="cordova-plugin-ionic-webview" spec="https://github.com/pliablepixels/cordova-plugin-ionic-webview.git"> <variable name="ANDROID_SUPPORT_ANNOTATIONS_VERSION" value="27.+" /> </plugin> + <plugin name="cordova-plugin-media-pp-fork" spec="^1.0.2-dev" /> + <engine name="ios" spec="4.5.5" /> + <engine name="android" spec="8.0.0" /> </widget> diff --git a/package.json b/package.json index 45dd4624..93306d8e 100644 --- a/package.json +++ b/package.json @@ -1,7 +1,7 @@ { "name": "zmninjapro", "description": "Home security mobile app for ZoneMinder", - "version":"1.3.078", + "version": "1.3.079", "displayName": "zmNinja", "author": "Pliable Pixels", "license": "custom see LICENSE.md", @@ -54,14 +54,14 @@ "cordova-custom-config": {}, "cordova-plugin-advanced-websocket": {}, "cordova-plugin-splashscreen": {}, - "cordova-plugin-media-pp-fork": {}, "cordova-plugin-add-swift-support": {}, "cordova-plugin-photo-library": { "PHOTO_LIBRARY_USAGE_DESCRIPTION": "Save monitor photos to albums" }, "cordova-plugin-ionic-webview": { "ANDROID_SUPPORT_ANNOTATIONS_VERSION": "27.+" - } + }, + "cordova-plugin-media-pp-fork": {} } }, "dependencies": { @@ -191,4 +191,4 @@ ] } } -} +}
\ No newline at end of file diff --git a/www/js/EventModalCtrl.js b/www/js/EventModalCtrl.js index e15b2dc9..92eae748 100644 --- a/www/js/EventModalCtrl.js +++ b/www/js/EventModalCtrl.js @@ -1075,9 +1075,14 @@ angular.module('zmApp.controllers').controller('EventModalCtrl', ['$scope', '$ro }); + $scope.showHideControls = function () { + $scope.displayControls = !$scope.displayControls; + NVR.debug ('control display is:'+$scope.displayControls); + }; $scope.$on('modal.shown', function (e, m) { + $scope.displayControls = true; $ionicLoading.hide(); if (m.id != 'footage') return; diff --git a/www/js/MomentCtrl.js b/www/js/MomentCtrl.js index 186df5cd..c53974a3 100644 --- a/www/js/MomentCtrl.js +++ b/www/js/MomentCtrl.js @@ -8,7 +8,7 @@ angular.module('zmApp.controllers').controller('zmApp.MomentCtrl', ['$scope', '$rootScope', '$ionicModal', 'NVR', '$ionicSideMenuDelegate', '$ionicHistory', '$state', '$translate', '$templateRequest', '$sce', '$compile', '$http', '$ionicLoading', 'zm', '$timeout', '$q', '$ionicPopover', '$ionicPopup', 'message', '$ionicScrollDelegate', function ($scope, $rootScope, $ionicModal, NVR, $ionicSideMenuDelegate, $ionicHistory, $state, $translate, $templateRequest, $sce, $compile, $http, $ionicLoading, zm, $timeout, $q, $ionicPopover, $ionicPopup, message, $ionicScrollDelegate) { - var masonry = null; +var masonry = null; var timeFrom; var timeTo; var moments = []; diff --git a/www/js/MonitorModalCtrl.js b/www/js/MonitorModalCtrl.js index 1f0ce944..903c2e2a 100644 --- a/www/js/MonitorModalCtrl.js +++ b/www/js/MonitorModalCtrl.js @@ -5,6 +5,7 @@ angular.module('zmApp.controllers').controller('MonitorModalCtrl', ['$scope', '$rootScope', 'zm', 'NVR', '$ionicSideMenuDelegate', '$timeout', '$interval', '$ionicModal', '$ionicLoading', '$http', '$state', '$stateParams', '$ionicHistory', '$ionicScrollDelegate', '$q', '$sce', 'carouselUtils', '$ionicPopup', 'SecuredPopups', '$translate', '$cordovaFile', function ($scope, $rootScope, zm, NVR, $ionicSideMenuDelegate, $timeout, $interval, $ionicModal, $ionicLoading, $http, $state, $stateParams, $ionicHistory, $ionicScrollDelegate, $q, $sce, carouselUtils, $ionicPopup, SecuredPopups, $translate, $cordovaFile) { + $scope.displayControls = true; $scope.animationInProgress = false; $scope.imageFit = true; $scope.isModalActive = true; @@ -1782,9 +1783,14 @@ angular.module('zmApp.controllers').controller('MonitorModalCtrl', ['$scope', '$ } - $scope.$on('modal.shown', function () { + $scope.showHideControls = function () { + $scope.displayControls = !$scope.displayControls; + NVR.debug ('control display is:'+$scope.displayControls); + }; + $scope.$on('modal.shown', function () { + $scope.displayControls = true; if (0 && $rootScope.platformOS == 'ios') { NVR.debug("Webkit hack, hammering window.stop();"); NVR.stopNetwork(); diff --git a/www/js/MontageCtrl.js b/www/js/MontageCtrl.js index 6292bae9..edca6dbb 100644 --- a/www/js/MontageCtrl.js +++ b/www/js/MontageCtrl.js @@ -1065,6 +1065,20 @@ angular.module('zmApp.controllers') NVR.debug("MontageCtrl: switch minimal is " + $scope.minimal); // console.log("Hide Statusbar"); ionic.Platform.fullScreen($scope.minimal, !$scope.minimal); + + // hiding status bar messes up X + /*if ($scope.minimal) { + if ($rootScope.platformOS !='desktop') { + NVR.debug ('hiding device status bar'); + return StatusBar.hide(); + } + } else { + if ($rootScope.platformOS !='desktop') { + NVR.debug ('showing device status bar'); + return StatusBar.show(); + } + }*/ + //console.log ("minimal switch:Cancelling timer"); $interval.cancel(intervalHandleMontage); //we will renew on reload $interval.cancel(intervalHandleMontageCycle); diff --git a/www/js/NVR.js b/www/js/NVR.js index b8b3f57b..71d58df1 100644 --- a/www/js/NVR.js +++ b/www/js/NVR.js @@ -21,7 +21,7 @@ angular.module('zmApp.controllers') DO NOT TOUCH zmAppVersion It is changed by sync_version.sh */ - var zmAppVersion = "1.3.078"; + var zmAppVersion = "1.3.079"; var isBackground = false; var justResumed = false; var timeSinceResumed = -1; diff --git a/www/templates/events-modal.html b/www/templates/events-modal.html index 466cd18e..be971b52 100644 --- a/www/templates/events-modal.html +++ b/www/templates/events-modal.html @@ -35,6 +35,7 @@ <img ng-if="!liveFeedMid" id="testaut_events_playwindow" image-spinner-src="{{constructStream()}}" ng-class="{'object-fit_cover':imageFit==false, 'object-fit_contain':imageFit==true}" + on-tap="showHideControls();" on-double-tap="closeModal();" img-spinner-w="1024" img-spinner-h="768" image-spinner-loader="lines" imageonload="modalImageLoaded()" on-swipe-left="onSwipeEvent(nextId,1)" on-swipe-right="onSwipeEvent(prevId,-1)" /> @@ -42,7 +43,9 @@ <div ng-if="liveFeedMid"> <img id="testaut_events_playwindow" image-spinner-src="{{currentEvent.Event.streamingURL}}/nph-zms?mode=jpeg&monitor={{liveFeedMid}}&connkey={{connKey}}{{$root.authSession}}" - ng-class="{'object-fit_cover':imageFit==false, 'object-fit_contain':imageFit==true}" on-double-tap="closeModal();" + ng-class="{'object-fit_cover':imageFit==false, 'object-fit_contain':imageFit==true}" + on-tap="showHideControls();" + on-double-tap="closeModal();" img-spinner-w="1024" img-spinner-h="768" image-spinner-loader="lines" imageonload="modalImageLoaded()" on-swipe-left="onSwipeEvent(nextId,1)" on-swipe-right="onSwipeEvent(prevId,-1)" /> <div class="events-range-modal-text"> @@ -73,6 +76,7 @@ vg-update-state="onPlayerState($state)" vg-update-playback="onPlaybackUpdate($playBack)" vg-plays-inline="videoObject.config.playsInline" vg-theme="videoObject.config.theme" vg-complete="playbackFinished()" + on-tap="showHideControls();" on-double-tap="closeModal();" vg-autoplay="videoObject.config.autoPlay" vg-responsive="videoObject.config.responsive" vg-update-time="videoTime(event.Event.StartTime,$currentTime)" vg-error="onVideoError($event)"> <vg-media vg-src="videoObject.config.sources" vg-native-controls="videoObject.config.nativeControls"> @@ -130,7 +134,7 @@ - <div ng-show="!liveFeedMid"> + <div ng-show="!liveFeedMid && displayControls"> <nav mfb-menu position="tr" effect="zoomin" label="{{'kCollapse'|translate}}" active-icon="ion-chevron-down" resting-icon="ion-chevron-up" toggling-method="click"> <a mfb-button icon="ion-arrow-right-c" label="{{'kNextEvent'|translate}}" ng-click="jumpToEvent(nextId,1);"></a> diff --git a/www/templates/monitors-modal.html b/www/templates/monitors-modal.html index ff0a11c3..bd64cdd5 100644 --- a/www/templates/monitors-modal.html +++ b/www/templates/monitors-modal.html @@ -17,6 +17,7 @@ <img id="singlemonitor" style="width:100vw; height:100vh;" image-spinner-loader="lines" image-spinner-src="{{constructSingleStream()}}" ng-class="{'object-fit_cover':imageFit==false, 'object-fit_contain':imageFit==true}" on-swipe-left="onSwipe(monitorId,1)" on-swipe-right="onSwipe(monitorId,-1)" on-double-tap="closeModal();" + on-tap="showHideControls();" imageonload="imageLoaded()" /> </div> <div ng-if="animationInProgress"> @@ -112,7 +113,8 @@ </div> </div> </ion-modal-view> - <nav id='testaut_monitormodal_nav_button' mfb-menu position="tr" effect="zoomin" label="{{'kCollapse' | translate}}" active-icon="ion-chevron-up" + + <nav ng-if="displayControls" id='testaut_monitormodal_nav_button' mfb-menu position="tr" effect="zoomin" label="{{'kCollapse' | translate}}" active-icon="ion-chevron-up" resting-icon="ion-chevron-down" toggling-method="click"> <button mfb-button icon="ion-arrow-resize" label="{{imageFit? ('kFillScreen' | translate):('kFitScreen' | translate)}}" ng-click="scaleImage();"> @@ -122,7 +124,7 @@ <button mfb-button icon="ion-arrow-expand" label="{{'kControl'| translate}}" ng-click="togglePTZ();"> </button> </nav> - <nav mfb-menu position="br" effect="zoomin" label="{{'kCollapse' | translate}}" active-icon="ion-chevron-down" + <nav ng-if="displayControls" mfb-menu position="br" effect="zoomin" label="{{'kCollapse' | translate}}" active-icon="ion-chevron-down" resting-icon="ion-chevron-up" toggling-method="click"> <button mfb-button icon="ion-android-arrow-back" label="{{'kPrevMonitor' | translate}} " ng-click="onTap(monitorId,-1);"> </button> @@ -131,7 +133,7 @@ <button id='testaut_monitormodal_nav_exit_button' mfb-button icon="ion-close" label="{{'kExitLiveView' | translate}}" ng-click="closeModal();"> </button> </nav> - <div id="flyoutmenu" style="position:absolute;bottom:80px;left:10px"> + <div id="flyoutmenu" ng-if="displayControls" style="position:absolute;bottom:80px;left:10px"> <ul> <li> @@ -208,7 +210,7 @@ </li> </ul> </div> - <div ng-if="!showPTZ" class="monitor-modal-text">{{monitorName}} + <div ng-if="!showPTZ && displayControls" class="monitor-modal-text">{{monitorName}} <span ng-style="{'background-color':stateColor()}"> {{monStatus}} </span> </div> </div> |
