To differentiate between various types of speech input, we add a 'x-webkit-grammar' attribute to a speech enabled input element. This is passed without validation to the speech recognizer. Typical values could be "builtin:search", "builtin:dictation" and even an externally hosted SRGS grammar XML file URI. It is up to the recognizer to interpret the value and use it as an aid in recognition.
Created attachment 71904 [details] Patch
Comment on attachment 71904 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=71904&action=review r=me > WebCore/page/SpeechInputClient.h:34 > +#include <wtf/Forward.h> Needed? > WebCore/platform/mock/SpeechInputClientMock.cpp:53 > +bool SpeechInputClientMock::startRecognition(int requestId, const IntRect&, const String&) include name > WebCore/platform/mock/SpeechInputClientMock.h:53 > + bool startRecognition(int, const IntRect&, const String&); include name > WebKit/chromium/src/SpeechInputClientImpl.h:57 > + bool startRecognition(int, const WebCore::IntRect&, const WTF::String&); you should include a name here
Comment on attachment 71904 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=71904&action=review Thanks, addressed the comments. Will land. >> WebCore/page/SpeechInputClient.h:34 >> +#include <wtf/Forward.h> > > Needed? Yes since we are using WTF::String in the added code below. >> WebCore/platform/mock/SpeechInputClientMock.cpp:53 >> +bool SpeechInputClientMock::startRecognition(int requestId, const IntRect&, const String&) > > include name Done >> WebCore/platform/mock/SpeechInputClientMock.h:53 >> + bool startRecognition(int, const IntRect&, const String&); > > include name Done >> WebKit/chromium/src/SpeechInputClientImpl.h:57 >> + bool startRecognition(int, const WebCore::IntRect&, const WTF::String&); > > you should include a name here Done
Committed r70567: <http://trac.webkit.org/changeset/70567>