Commit 8a119eb7 authored by Philip Jägenstedt's avatar Philip Jägenstedt Committed by Commit Bot

Add use counters for some of Web Speech API

SpeechGrammarList's addFromURI because it doesn't match the spec:
https://github.com/w3c/speech-api/issues/26

SpeechRecognitionEvent's interpretation and emma attributes because
they actually always return null and might be better to remove:
https://chromium.googlesource.com/chromium/src/+/7ad6ea7c2583942e86017bdd6fd5df991f6a05af/third_party/blink/renderer/modules/speech/speech_recognition_event.h#55

SpeechSynthesis#speak() to measure real SpeechSynthesis usage, like
the existing counter for SpeechRecognition#start().

Bug: 755287
Change-Id: I4f7fdcc5630887aaa051ac8ab13f72dab52c8dfb
Reviewed-on: https://chromium-review.googlesource.com/1109510Reviewed-by: default avatarMike West <mkwst@chromium.org>
Commit-Queue: Philip Jägenstedt <foolip@chromium.org>
Cr-Commit-Position: refs/heads/master@{#569222}
parent b62f9ecf
...@@ -1943,6 +1943,10 @@ enum WebFeature { ...@@ -1943,6 +1943,10 @@ enum WebFeature {
kMediaStreamSourceOnOfflineContext = 2477, kMediaStreamSourceOnOfflineContext = 2477,
kRTCDataChannelInitMaxRetransmitTime = 2478, kRTCDataChannelInitMaxRetransmitTime = 2478,
kRTCPeerConnectionCreateDataChannelMaxPacketLifeTime = 2479, kRTCPeerConnectionCreateDataChannelMaxPacketLifeTime = 2479,
kV8SpeechGrammarList_AddFromUri_Method = 2480,
kV8SpeechRecognitionEvent_Interpretation_AttributeGetter = 2481,
kV8SpeechRecognitionEvent_Emma_AttributeGetter = 2482,
kV8SpeechSynthesis_Speak_Method = 2483,
// Add new features immediately above this line. Don't change assigned // Add new features immediately above this line. Don't change assigned
// numbers of any item, and don't reuse removed slots. // numbers of any item, and don't reuse removed slots.
......
...@@ -31,6 +31,6 @@ ...@@ -31,6 +31,6 @@
] interface SpeechGrammarList { ] interface SpeechGrammarList {
readonly attribute unsigned long length; readonly attribute unsigned long length;
getter SpeechGrammar item(unsigned long index); getter SpeechGrammar item(unsigned long index);
[CallWith=ScriptState] void addFromUri(DOMString src, optional float weight); [CallWith=ScriptState, Measure] void addFromUri(DOMString src, optional float weight);
void addFromString(DOMString string, optional float weight); void addFromString(DOMString string, optional float weight);
}; };
...@@ -32,6 +32,6 @@ ...@@ -32,6 +32,6 @@
readonly attribute unsigned long resultIndex; readonly attribute unsigned long resultIndex;
readonly attribute SpeechRecognitionResultList? results; readonly attribute SpeechRecognitionResultList? results;
readonly attribute Document? interpretation; [Measure] readonly attribute Document? interpretation;
readonly attribute Document? emma; [Measure] readonly attribute Document? emma;
}; };
...@@ -32,7 +32,7 @@ ...@@ -32,7 +32,7 @@
readonly attribute boolean speaking; readonly attribute boolean speaking;
readonly attribute boolean paused; readonly attribute boolean paused;
void speak(SpeechSynthesisUtterance utterance); [Measure] void speak(SpeechSynthesisUtterance utterance);
void cancel(); void cancel();
void pause(); void pause();
void resume(); void resume();
......
...@@ -19028,6 +19028,11 @@ Called by update_net_error_codes.py.--> ...@@ -19028,6 +19028,11 @@ Called by update_net_error_codes.py.-->
<int value="2478" label="RTCDataChannelInitMaxRetransmitTime"/> <int value="2478" label="RTCDataChannelInitMaxRetransmitTime"/>
<int value="2479" <int value="2479"
label="RTCPeerConnectionCreateDataChannelMaxPacketLifeTime"/> label="RTCPeerConnectionCreateDataChannelMaxPacketLifeTime"/>
<int value="2480" label="V8SpeechGrammarList_AddFromUri_Method"/>
<int value="2481"
label="V8SpeechRecognitionEvent_Interpretation_AttributeGetter"/>
<int value="2482" label="V8SpeechRecognitionEvent_Emma_AttributeGetter"/>
<int value="2483" label="V8SpeechSynthesis_Speak_Method"/>
</enum> </enum>
<enum name="FeedbackSource"> <enum name="FeedbackSource">
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment