Skip to content

Commit 47e6927

Browse files
committed
Merge pull request jquery#66 from AliciaLippert/master
API Doc: vMouseOut
2 parents c878998 + f0f7169 commit 47e6927

File tree

3 files changed

+52
-2
lines changed

3 files changed

+52
-2
lines changed

entries/vmousemove.xml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<?xml version="1.0"?>
2-
<entry name="vmousedown" type="event" return="jQuery">
2+
<entry name="vmousemove" type="event" return="jQuery">
33
<title>vmousemove</title>
4-
<desc>Virtualized mouseover event handler.</desc>
4+
<desc>Virtualized mousemove event handler.</desc>
55
<longdesc>
66
<p>The jQuery Mobile <code>vmousemove</code> event handler simulates the "onmousemove" event handler on mobile devices.</p>
77
<p><i>The idea behind virtualized mouse events is to translate touch events into mouse events. Developers should be aware that these virtualized mouse events will not prevent any synthetic mouse events from being triggered inside the browser after a touch event. If a mouse-type device is used on the system, the virtualized mouse events are dispatched at the same time as the normal mouse events.</i></p>

entries/vmouseout.xml

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
<?xml version="1.0"?>
2+
<entry name="vmouseout" type="event" return="jQuery">
3+
<title>vmouseout</title>
4+
<desc>Virtualized mouseout event handler.</desc>
5+
<longdesc>
6+
<p>The jQuery Mobile <code>vmouseout</code> event handler simulates the "onmouseout" event handler on mobile devices. This event is fired on the initial touch of the screen on the device.</p>
7+
<p>The idea behind virtualized mouse events is to translate touch events into mouse events. Developers should be aware that these virtualized mouse events will not prevent any synthetic mouse events from being triggered inside the browser after a touch event. If a mouse-type device is used on the system, the virtualized mouse events are dispatched at the same time as the normal mouse events.</p>
8+
9+
<xi:include href="../includes/core-extension-desc.xml" xmlns:xi="http://www.w3.org/2003/XInclude"/>
10+
<pre>
11+
<code><![CDATA[
12+
$(function(){
13+
$(document).on("vmouseout", "p", function(){
14+
$(this).append('<span style="color:#00F;">Mouse out.</span>');
15+
});
16+
]]></code>
17+
</pre>
18+
<p>
19+
<iframe src="/resources/vmousedown/example1.html" style="width:100%;height:90px;border:0px"></iframe>
20+
</p>
21+
</longdesc>
22+
<added>1.0</added>
23+
<signature>
24+
<argument name="preventDefault" type="Function" optional="true">
25+
<desc>A function to invoke in the event binding to prevent the synthetic click event by the browser.</desc>
26+
</argument>
27+
28+
</signature>
29+
<category slug="events"/>
30+
</entry>

resources/vmouseout/example1.html

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
<!doctype html>
2+
<html lang="en">
3+
<head>
4+
<meta charset="utf-8">
5+
<meta name="viewport" content="width=device-width, initial-scale=1">
6+
<title>vmouseout demo</title>
7+
<link rel="stylesheet" href="http://code.jquery.com/mobile/1.1.1/jquery.mobile-1.1.1.min.css">
8+
<script src="http://code.jquery.com/jquery-1.7.2.min.js"></script>
9+
<script src="http://code.jquery.com/mobile/1.1.1/jquery.mobile-1.1.1.min.js"></script>
10+
</head>
11+
<body>
12+
<p>Touch here, move up and down to see what happens.</p>
13+
<script>
14+
$(function(){
15+
$(document).on("vmouseout", "p", function(){
16+
$(this).append('<span style="color:#00F;">Mouse out.</span>');
17+
});
18+
</script>
19+
</body>
20+
</html>

0 commit comments

Comments
 (0)