From beb9f4ca67b7de10f6985979ea4d63fe306cb6dc Mon Sep 17 00:00:00 2001 From: Pliable Pixels Date: Tue, 8 Sep 2020 19:45:16 -0400 Subject: #970 recompute device w/h on entry into events - needed only when you start in events view on app start. earlier dimensions are not accurate, leading to whitespace till you rotate --- www/js/EventCtrl.js | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'www/js/EventCtrl.js') diff --git a/www/js/EventCtrl.js b/www/js/EventCtrl.js index 2a75cccc..23fda099 100644 --- a/www/js/EventCtrl.js +++ b/www/js/EventCtrl.js @@ -209,6 +209,12 @@ angular.module('zmApp.controllers') broadcastHandles = []; }); + $scope.$on('$ionicView.afterEnter', function () { + // don't know why but on app start, dimensions are wrong + NVR.computeDeviceSize(); + }); + + $scope.$on('$ionicView.beforeEnter', function () { /* -- cgit v1.2.3