Open stalniy opened 12 years ago
To figure out when dom html is updated you can rewrite jQuery.fn.domManip method in such way:
jQuery.fn.domManip = (function (fn){
return function () {
var result = fn.apply(this, arguments);
// this === jQuery Collection
// here you can check elements size and make decision if you have to add lionbars
return result;
}
})(jQuery.fn.domManip)
Also as alternative, for autohide = true, you can rebuild all scrollbar properties (width for wrappers, ratios, etc.) on mouse over and drop them on mouse leave after scrollbars become hidden.
For examples, I have a one page application. Apply lionscrollbar to empty dom element. Then add some html to it's content.
Expected result: lionbars scrollbars are shown
Actual result: standard os scrollbars are shown
Example: