Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

api-docs.html outdated #17

Open
johnd0e opened this issue Jan 24, 2021 · 0 comments
Open

api-docs.html outdated #17

johnd0e opened this issue Jan 24, 2021 · 0 comments

Comments

@johnd0e
Copy link
Contributor

johnd0e commented Jan 24, 2021

http://leaflet.github.io/prosthetic-hand/api-docs.html is outdated

--- api-docs.html.old
+++ api-docs.html
@@ -167,6 +167,11 @@
 		<td><code>this</code></td>
 		<td>Don&#39;t move this finger for <code>delay</code> milliseconds.</td>
 	</tr>
+	<tr id='finger-waituntil'>
+		<td><code><b>waitUntil</b>(<nobr><i>timestamp</i></nobr>)</nobr></code></td>
+		<td><code>this</code></td>
+		<td>Don&#39;t move this finger until the given timestamp is reached.</td>
+	</tr>
 	<tr id='finger-update'>
 		<td><code><b>update</b>(<nobr>&lt;{}&gt; <i>options?</i></nobr>)</nobr></code></td>
 		<td><code>this</code></td>
@@ -289,9 +294,55 @@
 		<td>Defines how often new events will be fired, in one of the possible
 timing modes</td>
 	</tr>
+	<tr id='hand-onstart'>
+		<td><code><b>onStart</b></code></td>
+		<td><code>Function</code>
+		<td><code></code></td>
+		<td>If set to a callback function, it will be called (with the <a href="#hand"><code>Hand</code></a> 
+as its only argument) whenever the movements start.</td>
+	</tr>
+	<tr id='hand-onstop'>
+		<td><code><b>onStop</b></code></td>
+		<td><code>Function</code>
+		<td><code></code></td>
+		<td>If set to a callback function, it will be called (with the <a href="#hand"><code>Hand</code></a> 
+as its only argument) whenever the movements are completed.</td>
+	</tr>
 </tbody></table>
 </section>
 
+<h3 id='hand-event'>Events</h3>
+
+<section data-type='[object Object]'>
+
+Use <code>document.addEventListener(&#39;prostheticHandStop&#39;, fn)</code> to
+do stuff with it.
+<table><thead>
+	<tr>
+		<th>Event</th>
+		<th>Data</th>
+		<th>Description</th>
+	</tr>
+	</thead><tbody>
+	<tr id='hand-prosthetichandstart'>
+		<td><code><b>prostheticHandStart</b>
+		<td><code>CustomEvent</code></td>
+		<td>Fired when all movements are complete.</td>
+	</tr>
+	<tr id='hand-prosthetichandstop'>
+		<td><code><b>prostheticHandStop</b>
+		<td><code>CustomEvent</code></td>
+		<td>Fired when all movements are complete.</td>
+	</tr>
+	<tr id='hand-prosthetichandtick'>
+		<td><code><b>prostheticHandTick</b>
+		<td><code>CustomEvent</code></td>
+		<td>Fired a movement is about to start, just before the mouse/touch/pointer
+events are fired.</td>
+	</tr>
+</tbody></table>
+</section>
+
 <h3 id='hand-method'>Methods</h3>
 
 <section data-type='[object Object]'>
@@ -322,6 +373,13 @@
 		<td>Used by this hand&#39;s fingers to signal that one finger has finished doing
 all the queued movements.</td>
 	</tr>
+	<tr id='hand-sync'>
+		<td><code><b>sync</b>(<nobr><i>delay</i></nobr>)</nobr></code></td>
+		<td><code>this</code></td>
+		<td>Synchronizes the finger movements by adding a delay of <strong>at least</strong> <code>delay</code>
+milliseconds to each finger. After a sync, the movements of the fingers
+will happen at exactly the same time.</td>
+	</tr>
 	<tr id='hand-private_dispatchevents'>
 		<td><code><b>private_dispatchEvents</b>()</nobr></code></td>
 		<td><code>this</code></td>
@@ -374,7 +432,9 @@
 		<td><code></code></td>
 		<td>Like the <code>minimal</code> mode, but ignores timings completely and dispatches
 all events instantaneously. This might cause misbehaviour in graphical
-browsers.</td>
+browsers, and the <code>onStart</code> and <code>onStop</code> callbacks will be called at.
+every step of the movement (as the movement ends before the next step
+is chained in)</td>
 	</tr>
 	<tr id='timing-fastframe'>
 		<td><code><b>fastframe</b></code></td>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant