Skip to content

Commit

Permalink
Merge branch 'KeanW-master'
Browse files Browse the repository at this point in the history
  • Loading branch information
TalAter committed Nov 24, 2014
2 parents 8c9278c + 614fdd9 commit a2aaf0e
Show file tree
Hide file tree
Showing 7 changed files with 23 additions and 13 deletions.
13 changes: 10 additions & 3 deletions annyang.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
//! annyang
//! version : 1.4.0
//! version : 1.5.0
//! author : Tal Ater @TalAter
//! license : MIT
//! https://www.TalAter.com/annyang/
Expand Down Expand Up @@ -209,12 +209,15 @@
* Start listening.
* It's a good idea to call this after adding some commands first, but not mandatory.
*
* Receives an optional options object which currently only supports one option:
* Receives an optional options object which supports the following options:
* - `autoRestart` (Boolean, default: true) Should annyang restart itself if it is closed indirectly, because of silence or window conflicts?
* - `continuous` (Boolean, default: undefined) Allow forcing continuous mode on or off. Annyang is pretty smart about this, so only set this if you know what you're doing.
*
* ### Examples:
* // Start listening, but don't restart automatically
* // Start listening, don't restart automatically
* annyang.start({ autoRestart: false });
* // Start listening, don't restart automatically, stop recognition after first phrase recognized
* annyang.start({ autoRestart: false, continuous: false });
*
* @param {Object} [options] - Optional options.
* @method start
Expand All @@ -227,6 +230,10 @@
} else {
autoRestart = true;
}
if (options.continuous !== undefined) {
recognition.continuous = !!options.continuous;
}

lastStartedAt = new Date().getTime();
recognition.start();
},
Expand Down
4 changes: 2 additions & 2 deletions annyang.min.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion bower.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "annyang",
"version": "1.4.0",
"version": "1.5.0",
"description": "A javascript library for adding voice commands to your site, using speech recognition",
"main": "annyang.js",
"keywords": [
Expand Down
7 changes: 5 additions & 2 deletions docs/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -40,12 +40,15 @@ See: [Commands Object](#commands-object)
Start listening.
It's a good idea to call this after adding some commands first, but not mandatory.

Receives an optional options object which currently only supports one option:
Receives an optional options object which supports the following options:
- `autoRestart` (Boolean, default: true) Should annyang restart itself if it is closed indirectly, because of silence or window conflicts?
- `continuous` (Boolean, default: undefined) Allow forcing continuous mode on or off. Annyang is pretty smart about this, so only set this if you know what you're doing.

### Examples:
// Start listening, but don't restart automatically
// Start listening, don't restart automatically
annyang.start({ autoRestart: false });
// Start listening, don't restart automatically, stop recognition after first phrase recognized
annyang.start({ autoRestart: false, continuous: false });

### Params:

Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "annyang",
"version": "1.4.0",
"version": "1.5.0",
"description": "A javascript library for adding voice commands to your site, using speech recognition",
"homepage": "https://www.talater.com/annyang/",
"main": "annyang.js",
Expand Down
4 changes: 2 additions & 2 deletions sites/facebook.min.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions sites/geektime.min.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit a2aaf0e

Please sign in to comment.