Chromium Code Reviews| Index: Source/bindings/v8/Dictionary.cpp |
| diff --git a/Source/bindings/v8/Dictionary.cpp b/Source/bindings/v8/Dictionary.cpp |
| index b4cde415c32ba171a1639b1c2f6716dcca3bd696..7e0c890aea991d685d1c5681e58ab80312cc9086 100644 |
| --- a/Source/bindings/v8/Dictionary.cpp |
| +++ b/Source/bindings/v8/Dictionary.cpp |
| @@ -31,6 +31,7 @@ |
| #include "V8DOMWindow.h" |
| #include "V8EventTarget.h" |
| #include "V8IDBKeyRange.h" |
| +#include "V8MIDIPort.h" |
| #include "V8SpeechRecognitionError.h" |
| #include "V8SpeechRecognitionResult.h" |
| #include "V8SpeechRecognitionResultList.h" |
| @@ -331,6 +332,18 @@ bool Dictionary::get(const String& key, RefPtr<Uint8Array>& value) const |
| return true; |
| } |
| +bool Dictionary::get(const String& key, RefPtr<MIDIPort>& value) const |
| +{ |
| + v8::Local<v8::Value> v8Value; |
| + if (!getKey(key, v8Value)) |
| + return false; |
| + |
| + value = 0; |
| + if (V8MediaKeyError::HasInstance(v8Value, m_isolate, worldType(m_isolate))) |
|
haraken
2013/04/25 06:33:00
I don't think this works. V8MediaKeyError => V8MID
Takashi Toyoshima
2013/04/25 07:20:27
Oops. Sorry, I missed to rename it.
|
| + value = V8MIDIPort::toNative(v8::Handle<v8::Object>::Cast(v8Value)); |
| + return true; |
| +} |
| + |
| #if ENABLE(ENCRYPTED_MEDIA) |
| bool Dictionary::get(const String& key, RefPtr<MediaKeyError>& value) const |
| { |