Added a check whether element is visible before accessing its width and height (it's very CPU intensive for non visible elements in IE8)