mirror of
https://github.com/stylersnico/librenms.git
synced 2026-07-28 08:02:41 +02:00
Use the font-size of the element if the font-size of the parent is 0 and use 16 if both are 0 (applies when deltaMode is 1).
This commit is contained in:
@@ -1,5 +1,9 @@
|
||||
# Mouse Wheel ChangeLog
|
||||
|
||||
## 3.1.12
|
||||
|
||||
* Fix possible 0 value for line height when in delta mode 1
|
||||
|
||||
## 3.1.11
|
||||
|
||||
* Fix version number for package managers...
|
||||
|
||||
@@ -61,11 +61,12 @@
|
||||
},
|
||||
|
||||
getLineHeight: function(elem) {
|
||||
var $parent = $(elem)['offsetParent' in $.fn ? 'offsetParent' : 'parent']();
|
||||
var $elem = $(elem),
|
||||
$parent = $elem['offsetParent' in $.fn ? 'offsetParent' : 'parent']();
|
||||
if (!$parent.length) {
|
||||
$parent = $('body');
|
||||
}
|
||||
return parseInt($parent.css('fontSize'), 10);
|
||||
return parseInt($parent.css('fontSize'), 10) || parseInt($elem.css('fontSize'), 10) || 16;
|
||||
},
|
||||
|
||||
getPageHeight: function(elem) {
|
||||
|
||||
Reference in New Issue
Block a user