Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1574)

Unified Diff: Source/modules/speech/SpeechRecognitionEvent.cpp

Issue 169343002: [WIP]Add WebPrivateHeapPtr and use it for speech platform layer. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 6 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: Source/modules/speech/SpeechRecognitionEvent.cpp
diff --git a/Source/modules/speech/SpeechRecognitionEvent.cpp b/Source/modules/speech/SpeechRecognitionEvent.cpp
index 83f118c02c0fe7ed8f5e0a651ec59299d37f6fe7..5741b7540115b6a33200c23f12fb70524b0a0312 100644
--- a/Source/modules/speech/SpeechRecognitionEvent.cpp
+++ b/Source/modules/speech/SpeechRecognitionEvent.cpp
@@ -44,15 +44,15 @@ PassRefPtr<SpeechRecognitionEvent> SpeechRecognitionEvent::create(const AtomicSt
return adoptRef(new SpeechRecognitionEvent(eventName, initializer));
}
-PassRefPtr<SpeechRecognitionEvent> SpeechRecognitionEvent::createResult(unsigned long resultIndex, const Vector<RefPtr<SpeechRecognitionResult> >& results)
+PassRefPtr<SpeechRecognitionEvent> SpeechRecognitionEvent::createResult(unsigned long resultIndex, const WillBeHeapVector<RefPtrWillBeMember<SpeechRecognitionResult> >& results)
{
return adoptRef(new SpeechRecognitionEvent(EventTypeNames::result, resultIndex, SpeechRecognitionResultList::create(results)));
}
-PassRefPtr<SpeechRecognitionEvent> SpeechRecognitionEvent::createNoMatch(PassRefPtr<SpeechRecognitionResult> result)
+PassRefPtr<SpeechRecognitionEvent> SpeechRecognitionEvent::createNoMatch(PassRefPtrWillBeRawPtr<SpeechRecognitionResult> result)
{
if (result) {
- Vector<RefPtr<SpeechRecognitionResult> > results;
+ WillBeHeapVector<RefPtrWillBeMember<SpeechRecognitionResult> > results;
results.append(result);
return adoptRef(new SpeechRecognitionEvent(EventTypeNames::nomatch, 0, SpeechRecognitionResultList::create(results)));
}

Powered by Google App Engine
This is Rietveld 408576698