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

Side by Side Diff: Source/modules/speech/SpeechRecognition.cpp

Issue 540283003: bindings: Retires ScriptWrappable::init, etc. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Addressed a review comment. Created 6 years, 3 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2012 Google Inc. All rights reserved. 2 * Copyright (C) 2012 Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions 5 * modification, are permitted provided that the following conditions
6 * are met: 6 * are met:
7 * * Redistributions of source code must retain the above copyright 7 * * Redistributions of source code must retain the above copyright
8 * notice, this list of conditions and the following disclaimer. 8 * notice, this list of conditions and the following disclaimer.
9 * * Redistributions in binary form must reproduce the above copyright 9 * * Redistributions in binary form must reproduce the above copyright
10 * notice, this list of conditions and the following disclaimer in the 10 * notice, this list of conditions and the following disclaimer in the
(...skipping 158 matching lines...) Expand 10 before | Expand all | Expand 10 after
169 : ActiveDOMObject(context) 169 : ActiveDOMObject(context)
170 , m_grammars(SpeechGrammarList::create()) // FIXME: The spec is not clear on the default value for the grammars attribute. 170 , m_grammars(SpeechGrammarList::create()) // FIXME: The spec is not clear on the default value for the grammars attribute.
171 , m_continuous(false) 171 , m_continuous(false)
172 , m_interimResults(false) 172 , m_interimResults(false)
173 , m_maxAlternatives(1) 173 , m_maxAlternatives(1)
174 , m_controller(nullptr) 174 , m_controller(nullptr)
175 , m_stoppedByActiveDOMObject(false) 175 , m_stoppedByActiveDOMObject(false)
176 , m_started(false) 176 , m_started(false)
177 , m_stopping(false) 177 , m_stopping(false)
178 { 178 {
179 ScriptWrappable::init(this);
180 Document* document = toDocument(executionContext()); 179 Document* document = toDocument(executionContext());
181 180
182 Page* page = document->page(); 181 Page* page = document->page();
183 ASSERT(page); 182 ASSERT(page);
184 183
185 m_controller = SpeechRecognitionController::from(page); 184 m_controller = SpeechRecognitionController::from(page);
186 ASSERT(m_controller); 185 ASSERT(m_controller);
187 186
188 // FIXME: Need to hook up with Page to get notified when the visibility chan ges. 187 // FIXME: Need to hook up with Page to get notified when the visibility chan ges.
189 } 188 }
190 189
191 SpeechRecognition::~SpeechRecognition() 190 SpeechRecognition::~SpeechRecognition()
192 { 191 {
193 } 192 }
194 193
195 void SpeechRecognition::trace(Visitor* visitor) 194 void SpeechRecognition::trace(Visitor* visitor)
196 { 195 {
197 visitor->trace(m_grammars); 196 visitor->trace(m_grammars);
198 #if ENABLE(OILPAN) 197 #if ENABLE(OILPAN)
199 visitor->trace(m_controller); 198 visitor->trace(m_controller);
200 #endif 199 #endif
201 visitor->trace(m_finalResults); 200 visitor->trace(m_finalResults);
202 EventTargetWithInlineData::trace(visitor); 201 EventTargetWithInlineData::trace(visitor);
203 } 202 }
204 203
205 } // namespace blink 204 } // namespace blink
OLDNEW
« no previous file with comments | « Source/modules/speech/SpeechGrammarList.cpp ('k') | Source/modules/speech/SpeechRecognitionAlternative.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698