Jun*_*aid 13 iphone opera android widget jquery-mobile
我尝试在其中一个演示中实现jquerymobile的Tap-hold功能
<!DOCTYPE html>
<html>
<head>
<title>jQuery Mobile Events</title>
<link rel="stylesheet" href="http://code.jquery.com/mobile/1.0a1/jquery.mobile-1.0a1.min.css" />
<script src="http://code.jquery.com/jquery-1.4.3.min.js"></script>
<script src="http://code.jquery.com/mobile/1.0a1/jquery.mobile-1.0a1.min.js"></script>
<script type="text/javascript">
$( function() {
$('body').bind( 'taphold', function( e ) {
alert( 'You tapped and held!' );
e.stopImmediatePropagation();
return false;
} );
$('body').bind( 'swipe', function( e ) {
alert( 'You swiped!' );
e.stopImmediatePropagation();
return false;
} );
} );
</script>
</head>
<body>
<div data-role="page" id="home">
<div data-role="header">
<h1>jQuery Mobile Events</h1>
</div>
<div data-role="content">
<p>Try:</p>
<ul>
<li>Tapping and holding</li>
<li>Swiping</li>
</ul>
</div>
</div>
</body>
</html>
Run Code Online (Sandbox Code Playgroud)
但刷卡是不工作的歌剧工具仿真器和水龙头保持工作非常古怪,当u敲击两次,然后轻扫它不保持工作它的工作原理.我尝试删除绑定到滑动功能,但没有变化.
归档时间: |
|
查看次数: |
1989 次 |
最近记录: |