From 232409d70b5f58442b3497d00f83a4224d362f45 Mon Sep 17 00:00:00 2001 From: DennisSchiefer Date: Tue, 3 Jul 2012 10:24:10 +0100 Subject: [PATCH] selector elements now use offsetHeight and offsetWidth instead of clientHeight and clientWidth of invisible selector element --- WebContent/gui/OSRM.Selector.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/WebContent/gui/OSRM.Selector.js b/WebContent/gui/OSRM.Selector.js index a9700f50a..f5f2286fa 100644 --- a/WebContent/gui/OSRM.Selector.js +++ b/WebContent/gui/OSRM.Selector.js @@ -44,8 +44,8 @@ selectorInit: function(id, options, selected, onchange_fct) { myspan.id = "styled-select-" + select.id; myspan.appendChild(textnode); select.parentNode.insertBefore(myspan, select); - myspan.style.width = (select.clientWidth-2)+"px"; - myspan.style.height = (select.clientHeight)+"px"; + myspan.style.width = (select.offsetWidth-2)+"px"; + myspan.style.height = (select.offsetHeight)+"px"; // clientHeight gives the height of the opened dropbox! }, // required behaviour of selector on change to switch shown name