0

I made a horizontal list. and set onScroll event on the list.

It's work well on chrome browser. but not on android default browser.

mycodes is below,

HTML

<ul id="menu-list">
  <li class="menu-page">
    <div class="menu-div">width 100% div</div>
  </li>
  <li class="menu-page">
    <div class="menu-div">width 100% div</div>
  </li>
  ...
</ul>

CSS

body, html {
  margin:0;
  width: 100%;
}
ul, li {
  margin: 0;
  padding: 0;
  list-style: none;
}

#menu-list {
  width: 100%;
  overflow: auto;
  white-space: nowrap;
}

.menu-div {
  display: inline-block;
  width: 100%;
  height: 300px;
  background: red;
}

.menu-page {
  display: inline;
  width: 100%;
}

JS

$(document).ready(function() {
  $("#menu-list").on('scroll', function(){
    //event fired
  });
});

How can I receive the onScroll event on android default browser? (when using horizontal scroll)

Lion.k
  • 2,519
  • 8
  • 28
  • 43
  • Mobile browsers do not fire the "onscroll" event continuously, only after the scrolling comes to a stop... This article should help you understand the problem: http://tjvantoll.com/2012/08/19/onscroll-event-issues-on-mobile-browsers/ – mrksbnch Nov 11 '13 at 10:42
  • No I'm not talking about continuously event. It doesn't fire any event. I tested on default browser of HTC evo, Google GALAXY Nexus. – Lion.k Nov 12 '13 at 01:20

0 Answers0