summaryrefslogtreecommitdiff
path: root/www
diff options
context:
space:
mode:
Diffstat (limited to 'www')
-rw-r--r--www/js/EventCtrl.js24
-rw-r--r--www/templates/events.html2
2 files changed, 21 insertions, 5 deletions
diff --git a/www/js/EventCtrl.js b/www/js/EventCtrl.js
index 0cc99651..b37b5f92 100644
--- a/www/js/EventCtrl.js
+++ b/www/js/EventCtrl.js
@@ -2976,13 +2976,29 @@ angular.module('zmApp.controllers')
mh = tmp;
}
var ld = NVR.getLogin();
- if (ld.eventViewThumbsSize == 'large') {
- return calculateAspectRatioFit(mw, mh, 0.9* $rootScope.devWidth, 0.4 * $rootScope.devHeight);
+ // landscape
+ if ($rootScope.devWidth > $rootScope.devHeight) {
+
+ if (ld.eventViewThumbsSize == 'large') {
+ return calculateAspectRatioFit(mw, mh, 0.9* $rootScope.devWidth, 1.5 * $rootScope.devHeight);
+
+ } else {
+ return calculateAspectRatioFit(mw, mh, 0.5 * $rootScope.devWidth, 0.7 * $rootScope.devHeight);
+
+ }
} else {
- return calculateAspectRatioFit(mw, mh, 0.3 * $rootScope.devWidth, 0.3 * $rootScope.devHeight);
+ // portrait
+ if (ld.eventViewThumbsSize == 'large') {
+ return calculateAspectRatioFit(mw, mh, 0.9* $rootScope.devWidth, 0.4 * $rootScope.devHeight);
+
+ } else {
+ return calculateAspectRatioFit(mw, mh, 0.3 * $rootScope.devWidth, 0.3 * $rootScope.devHeight);
+
+ }
- }
+ }
+
/*
if (ld.eventViewThumbsSize == 'large') {
diff --git a/www/templates/events.html b/www/templates/events.html
index 1a964f6c..744474b0 100644
--- a/www/templates/events.html
+++ b/www/templates/events.html
@@ -98,7 +98,7 @@
<!-- <br/> Default video:{{event.Event.relativePath}}{{event.Event.DefaultVideo}}-->
</div>
</div> <!-- col-->
- <div class="col">
+ <div ng-if="loginData.eventViewThumbs!='none'" class="col">
<div ng-if="loginData.eventViewThumbs!='none'"
ng-class="::{'largeThumbs': thumbClass=='large', 'smallThumbs': thumbClass=='small'}">
<img bg-color="#6C7A89" ng-src="{{constructThumbnail(event)}}"