mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 1187791 - Part 1 of 1 - SpeechRecognition::maxAlternatives can't throw; so, rm webidl throws specifier. r=smaug
This commit is contained in:
parent
afd6ca669c
commit
c703f8c144
@ -54,8 +54,7 @@ public:
|
||||
SpeechRecognitionResultList* resultList =
|
||||
new SpeechRecognitionResultList(mRecognition);
|
||||
SpeechRecognitionResult* result = new SpeechRecognitionResult(mRecognition);
|
||||
ErrorResult rv;
|
||||
if (0 < mRecognition->GetMaxAlternatives(rv)) { // GetMaxAlternatives can't fail
|
||||
if (0 < mRecognition->MaxAlternatives()) {
|
||||
SpeechRecognitionAlternative* alternative =
|
||||
new SpeechRecognitionAlternative(mRecognition);
|
||||
|
||||
@ -331,8 +330,7 @@ PocketSphinxSpeechRecognitionService::BuildMockResultList()
|
||||
SpeechRecognitionResultList* resultList =
|
||||
new SpeechRecognitionResultList(mRecognition);
|
||||
SpeechRecognitionResult* result = new SpeechRecognitionResult(mRecognition);
|
||||
ErrorResult rv;
|
||||
if (0 < mRecognition->GetMaxAlternatives(rv)) { // GetMaxAlternatives can't fail
|
||||
if (0 < mRecognition->MaxAlternatives()) {
|
||||
SpeechRecognitionAlternative* alternative =
|
||||
new SpeechRecognitionAlternative(mRecognition);
|
||||
|
||||
|
@ -684,13 +684,13 @@ SpeechRecognition::SetInterimResults(bool aArg)
|
||||
}
|
||||
|
||||
uint32_t
|
||||
SpeechRecognition::GetMaxAlternatives(ErrorResult& aRv) const
|
||||
SpeechRecognition::MaxAlternatives() const
|
||||
{
|
||||
return mMaxAlternatives;
|
||||
}
|
||||
|
||||
void
|
||||
SpeechRecognition::SetMaxAlternatives(uint32_t aArg, ErrorResult& aRv)
|
||||
SpeechRecognition::SetMaxAlternatives(uint32_t aArg)
|
||||
{
|
||||
mMaxAlternatives = aArg;
|
||||
return;
|
||||
|
@ -87,9 +87,9 @@ public:
|
||||
|
||||
void SetInterimResults(bool aArg);
|
||||
|
||||
uint32_t GetMaxAlternatives(ErrorResult& aRv) const;
|
||||
uint32_t MaxAlternatives() const;
|
||||
|
||||
void SetMaxAlternatives(uint32_t aArg, ErrorResult& aRv);
|
||||
void SetMaxAlternatives(uint32_t aArg);
|
||||
|
||||
void GetServiceURI(nsString& aRetVal, ErrorResult& aRv) const;
|
||||
|
||||
|
@ -102,8 +102,7 @@ FakeSpeechRecognitionService::BuildMockResultList()
|
||||
{
|
||||
SpeechRecognitionResultList* resultList = new SpeechRecognitionResultList(mRecognition);
|
||||
SpeechRecognitionResult* result = new SpeechRecognitionResult(mRecognition);
|
||||
ErrorResult rv;
|
||||
if (0 < mRecognition->GetMaxAlternatives(rv)) { // GetMaxAlternatives can't fail
|
||||
if (0 < mRecognition->MaxAlternatives()) {
|
||||
SpeechRecognitionAlternative* alternative = new SpeechRecognitionAlternative(mRecognition);
|
||||
|
||||
alternative->mTranscript = NS_LITERAL_STRING("Mock final result");
|
||||
|
@ -20,7 +20,6 @@ interface SpeechRecognition : EventTarget {
|
||||
[Throws]
|
||||
attribute boolean continuous;
|
||||
attribute boolean interimResults;
|
||||
[Throws]
|
||||
attribute unsigned long maxAlternatives;
|
||||
[Throws]
|
||||
attribute DOMString serviceURI;
|
||||
|
Loading…
Reference in New Issue
Block a user