アプリケーションでtwitterブートストラップ、jquery、phonegapを使用しています。
私はoverflow:scrollとそれをナビゲートするための2つのボタンを持つdivを持っています:
<a href="#" id="left-button" style="float: left;"><i class="icon-chevron-left"></i></a>
<a href="#" id="right-button" style="float: right;"><i class="icon-chevron-right"></i></a>
<div id="content" style="overflow: scroll; white-space: nowrap;">
<img src="img/bandera.jpg" class="img-rounded">
<img src="img/arbol.jpg" class="img-rounded">
</div>
ボタンを使用する次のjqueryスクリプトがあります。
$('#right-button').click(function(){
$('#content').animate({
scrollLeft: '+=200px'
}, 600 );
});
$('#left-button').click(function(){
$('#content').animate({
scrollLeft: '-=200px'
}, 600 );
});
しかし、私には問題があります。ボタンはFirefox、Chrome、さらにはデスクトップのIEでも正常に機能し、Android2.2でも正常に機能します。
しかし、何らかの理由で、Android4.0ではボタンは何もしません。