From 17b6d369e3608e5b6d1073c0338f240dec9618b0 Mon Sep 17 00:00:00 2001 From: Brandon Aaron Date: Thu, 12 Dec 2013 14:36:47 -0500 Subject: [PATCH] offsetParent was not added until 1.2.6 and should probably continue support for 1.2.2 since this is going to be a bug fix release --- jquery.mousewheel.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/jquery.mousewheel.js b/jquery.mousewheel.js index a28a661f4..4c2178c95 100755 --- a/jquery.mousewheel.js +++ b/jquery.mousewheel.js @@ -58,7 +58,7 @@ }, getLineHeight: function(elem) { - return parseInt($(elem).offsetParent().css('fontSize'), 10); + return parseInt($(elem)['offsetParent' in jQuery.fn ? 'offsetParent' : 'parent']().css('fontSize'), 10); }, getPageHeight: function(elem) {