diff --git a/src/dom.js b/src/dom.js index 8c82900..ce87673 100644 --- a/src/dom.js +++ b/src/dom.js @@ -1176,12 +1176,11 @@ Element.addMethods = function(methods) { document.viewport = { getDimensions: function() { - var dimensions = { }; - var B = Prototype.Browser; + var dimensions = { }, B = Prototype.Browser; $w('width height').each(function(d) { var D = d.capitalize(); dimensions[d] = (B.WebKit && !document.evaluate) ? self['inner' + D] : - (B.Opera) ? document.body['client' + D] : document.documentElement['client' + D]; + (B.Opera && opera.version() < 9.5) ? document.body['client' + D] : document.documentElement['client' + D]; }); return dimensions; },