0

I added customize scrollbar in my site that doesn't update window.scrollY and my picture does'nt fade in. my code is this:

<link rel='stylesheet' href='Style/jquery.mCustomScrollbar.css' type='text/css' media='all' />
<script type='text/javascript' src='Js/jquery.mCustomScrollbar.concat.min.js'></script>
<script type="text/javascript">
        (function ($) {
                    $(window).load(function () {
                        $("body").mCustomScrollbar();
                    });


    })(jQuery);
    </script>

Is any customize jquery scroll bar for 1.9.1 version that update window.scrollY?? thank u for help.

Marc Audet
  • 46,011
  • 11
  • 63
  • 83
Sasan007
  • 215
  • 1
  • 9

1 Answers1

0

This happens because custom scrollbar emulates scroll using content offset, not scrollTop/scrollLeft. You can try jQuery Scrollbar that scrolls page, but you will have to make page wrapper, apply scrollbar to it and listen scroll events on this container, not on window!

Example is here. Also, you can't remove native page scrollbar in IE7

Community
  • 1
  • 1
Gromo
  • 1,609
  • 1
  • 13
  • 14