diff options
author | Michael Scherle | 2017-03-07 00:49:21 +0100 |
---|---|---|
committer | Michael Scherle | 2017-03-07 00:49:21 +0100 |
commit | 8106c9e8c63d4c197af6727c98fa06fc560022ad (patch) | |
tree | 72acd6be481a2297bf4710fbbedbe9bb980ae3db | |
parent | API: Fixed Calendar json decode was missing on the calendar part. (diff) | |
download | slx-admin-8106c9e8c63d4c197af6727c98fa06fc560022ad.tar.gz slx-admin-8106c9e8c63d4c197af6727c98fa06fc560022ad.tar.xz slx-admin-8106c9e8c63d4c197af6727c98fa06fc560022ad.zip |
frontend: fixed scaling issue when there was only one pc
-rwxr-xr-x | modules-available/locationinfo/frontend/doorsign.html | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/modules-available/locationinfo/frontend/doorsign.html b/modules-available/locationinfo/frontend/doorsign.html index b096ec33..76a352ce 100755 --- a/modules-available/locationinfo/frontend/doorsign.html +++ b/modules-available/locationinfo/frontend/doorsign.html @@ -1259,6 +1259,7 @@ optional: xDifference = maxX - minX;
yDifference = maxY - minY;
+
room.xDifference = xDifference;
room.yDifference = yDifference;
room.minX = minX;
@@ -1305,7 +1306,10 @@ optional: if (scaleXs <= 0) {
scaleXs = 9999;
}
- var tmp = [scaleYs, scaleY, scaleXs, scaleX];
+
+
+ var tmp = [scaleYs, scaleY, scaleXs, scaleX,(clientHeight *0.9) / picSizeY,(clientWidth *0.9) / picSizeX];
+ console.log(tmp)
room.scale = Math.min.apply(Math, tmp);
room.xOffset = 0 - room.minX;
room.yOffset = 0 - room.minY;
|