From 771f977787bf2153b5e50660c044bd72aec66a31 Mon Sep 17 00:00:00 2001 From: ivmartel Date: Mon, 8 Oct 2018 23:38:22 +0200 Subject: [PATCH] Use layer container parent as reference. Fixes #581. --- src/app/application.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/app/application.js b/src/app/application.js index 6d1baa581f..2535e679b1 100644 --- a/src/app/application.js +++ b/src/app/application.js @@ -364,7 +364,8 @@ dwv.App = function () * @return {width, height} The width and height of the div. */ this.getLayerContainerSize = function () { - var div = document.getElementById(containerDivId); + var ldiv = self.getElement("layerContainer"); + var div = ldiv.parentNode; // remove the height of other elements of the container div var height = div.offsetHeight; var kids = div.children;