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

Side by Side Diff: Source/bindings/v8/Dictionary.cpp

Issue 315133004: Enable Oilpan by default in modules/speech/ (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Rebased Created 6 years, 6 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
« no previous file with comments | « Source/bindings/v8/Dictionary.h ('k') | Source/modules/speech/DOMWindowSpeechSynthesis.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2010 Google Inc. All rights reserved. 2 * Copyright (C) 2010 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 * 7 *
8 * 1. Redistributions of source code must retain the above copyright 8 * 1. Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * 2. Redistributions in binary form must reproduce the above copyright 10 * 2. Redistributions in binary form must reproduce the above copyright
(...skipping 21 matching lines...) Expand all
32 #include "bindings/core/v8/V8MessagePort.h" 32 #include "bindings/core/v8/V8MessagePort.h"
33 #include "bindings/core/v8/V8Storage.h" 33 #include "bindings/core/v8/V8Storage.h"
34 #include "bindings/core/v8/V8TextTrack.h" 34 #include "bindings/core/v8/V8TextTrack.h"
35 #include "bindings/core/v8/V8VoidCallback.h" 35 #include "bindings/core/v8/V8VoidCallback.h"
36 #include "bindings/core/v8/V8Window.h" 36 #include "bindings/core/v8/V8Window.h"
37 #include "bindings/modules/v8/V8Gamepad.h" 37 #include "bindings/modules/v8/V8Gamepad.h"
38 #include "bindings/modules/v8/V8HeaderMap.h" 38 #include "bindings/modules/v8/V8HeaderMap.h"
39 #include "bindings/modules/v8/V8IDBKeyRange.h" 39 #include "bindings/modules/v8/V8IDBKeyRange.h"
40 #include "bindings/modules/v8/V8MIDIPort.h" 40 #include "bindings/modules/v8/V8MIDIPort.h"
41 #include "bindings/modules/v8/V8MediaStream.h" 41 #include "bindings/modules/v8/V8MediaStream.h"
42 #include "bindings/modules/v8/V8SpeechRecognitionError.h"
43 #include "bindings/modules/v8/V8SpeechRecognitionResult.h" 42 #include "bindings/modules/v8/V8SpeechRecognitionResult.h"
44 #include "bindings/modules/v8/V8SpeechRecognitionResultList.h" 43 #include "bindings/modules/v8/V8SpeechRecognitionResultList.h"
45 #include "bindings/v8/ArrayValue.h" 44 #include "bindings/v8/ArrayValue.h"
46 #include "bindings/v8/ExceptionMessages.h" 45 #include "bindings/v8/ExceptionMessages.h"
47 #include "bindings/v8/ExceptionState.h" 46 #include "bindings/v8/ExceptionState.h"
48 #include "bindings/v8/V8Binding.h" 47 #include "bindings/v8/V8Binding.h"
49 #include "bindings/v8/custom/V8ArrayBufferViewCustom.h" 48 #include "bindings/v8/custom/V8ArrayBufferViewCustom.h"
50 #include "bindings/v8/custom/V8Uint8ArrayCustom.h" 49 #include "bindings/v8/custom/V8Uint8ArrayCustom.h"
51 #include "core/html/track/TrackBase.h" 50 #include "core/html/track/TrackBase.h"
52 #include "modules/gamepad/Gamepad.h" 51 #include "modules/gamepad/Gamepad.h"
53 #include "modules/indexeddb/IDBKeyRange.h" 52 #include "modules/indexeddb/IDBKeyRange.h"
54 #include "modules/mediastream/MediaStream.h" 53 #include "modules/mediastream/MediaStream.h"
55 #include "modules/speech/SpeechRecognitionError.h"
56 #include "modules/speech/SpeechRecognitionResult.h" 54 #include "modules/speech/SpeechRecognitionResult.h"
57 #include "modules/speech/SpeechRecognitionResultList.h" 55 #include "modules/speech/SpeechRecognitionResultList.h"
58 #include "wtf/MathExtras.h" 56 #include "wtf/MathExtras.h"
59 57
60 namespace WebCore { 58 namespace WebCore {
61 59
62 Dictionary::Dictionary() 60 Dictionary::Dictionary()
63 : m_isolate(0) 61 : m_isolate(0)
64 { 62 {
65 } 63 }
(...skipping 406 matching lines...) Expand 10 before | Expand all | Expand 10 after
472 // FIXME: this will need to be changed so it can also return an AudioTra ck or a VideoTrack once 470 // FIXME: this will need to be changed so it can also return an AudioTra ck or a VideoTrack once
473 // we add them. 471 // we add them.
474 v8::Handle<v8::Object> track = V8TextTrack::findInstanceInPrototypeChain (wrapper, m_isolate); 472 v8::Handle<v8::Object> track = V8TextTrack::findInstanceInPrototypeChain (wrapper, m_isolate);
475 if (!track.IsEmpty()) 473 if (!track.IsEmpty())
476 source = V8TextTrack::toNative(track); 474 source = V8TextTrack::toNative(track);
477 } 475 }
478 value = source; 476 value = source;
479 return true; 477 return true;
480 } 478 }
481 479
482 bool Dictionary::get(const String& key, RefPtrWillBeMember<SpeechRecognitionErro r>& value) const 480 bool Dictionary::get(const String& key, Member<SpeechRecognitionResult>& value) const
483 { 481 {
484 v8::Local<v8::Value> v8Value; 482 v8::Local<v8::Value> v8Value;
485 if (!getKey(key, v8Value)) 483 if (!getKey(key, v8Value))
486 return false;
487
488 value = V8SpeechRecognitionError::toNativeWithTypeCheck(m_isolate, v8Value);
489 return true;
490 }
491
492 bool Dictionary::get(const String& key, RefPtrWillBeMember<SpeechRecognitionResu lt>& value) const
493 {
494 v8::Local<v8::Value> v8Value;
495 if (!getKey(key, v8Value))
496 return false; 484 return false;
497 485
498 value = V8SpeechRecognitionResult::toNativeWithTypeCheck(m_isolate, v8Value) ; 486 value = V8SpeechRecognitionResult::toNativeWithTypeCheck(m_isolate, v8Value) ;
499 return true; 487 return true;
500 } 488 }
501 489
502 bool Dictionary::get(const String& key, RefPtrWillBeMember<SpeechRecognitionResu ltList>& value) const 490 bool Dictionary::get(const String& key, Member<SpeechRecognitionResultList>& val ue) const
503 { 491 {
504 v8::Local<v8::Value> v8Value; 492 v8::Local<v8::Value> v8Value;
505 if (!getKey(key, v8Value)) 493 if (!getKey(key, v8Value))
506 return false; 494 return false;
507 495
508 value = V8SpeechRecognitionResultList::toNativeWithTypeCheck(m_isolate, v8Va lue); 496 value = V8SpeechRecognitionResultList::toNativeWithTypeCheck(m_isolate, v8Va lue);
509 return true; 497 return true;
510 } 498 }
511 499
512 bool Dictionary::get(const String& key, Member<Gamepad>& value) const 500 bool Dictionary::get(const String& key, Member<Gamepad>& value) const
(...skipping 234 matching lines...) Expand 10 before | Expand all | Expand 10 after
747 735
748 return *this; 736 return *this;
749 } 737 }
750 738
751 void Dictionary::ConversionContext::throwTypeError(const String& detail) 739 void Dictionary::ConversionContext::throwTypeError(const String& detail)
752 { 740 {
753 exceptionState().throwTypeError(detail); 741 exceptionState().throwTypeError(detail);
754 } 742 }
755 743
756 } // namespace WebCore 744 } // namespace WebCore
OLDNEW
« no previous file with comments | « Source/bindings/v8/Dictionary.h ('k') | Source/modules/speech/DOMWindowSpeechSynthesis.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698