Index: Source/bindings/tests/results/V8TestDictionary.cpp |
diff --git a/Source/bindings/tests/results/V8TestDictionary.cpp b/Source/bindings/tests/results/V8TestDictionary.cpp |
index ea135bc454bfb88e191692a59cc20449b69ce792..5d0168623e8fafadd59506f19edb68b2d0aa759a 100644 |
--- a/Source/bindings/tests/results/V8TestDictionary.cpp |
+++ b/Source/bindings/tests/results/V8TestDictionary.cpp |
@@ -7,7 +7,7 @@ |
#include "config.h" |
#include "V8TestDictionary.h" |
-#include "bindings/core/v8/Dictionary.h" |
+#include "bindings/core/v8/PropertyBag.h" |
#include "bindings/tests/v8/V8TestInterface.h" |
#include "bindings/tests/v8/V8TestInterfaceGarbageCollected.h" |
#include "bindings/tests/v8/V8TestInterfaceWillBeGarbageCollected.h" |
@@ -17,47 +17,48 @@ namespace blink { |
TestDictionary* V8TestDictionary::toNative(v8::Isolate* isolate, v8::Handle<v8::Value> v8Value) |
{ |
TestDictionary* impl = TestDictionary::create(); |
- // FIXME: Do not use Dictionary and DictionaryHelper |
- // https://crbug.com/321462 |
- Dictionary dictionary(v8Value, isolate); |
+ if (v8Value.IsEmpty() || !v8Value->IsObject()) |
+ return impl; |
+ v8::Local<v8::Object> v8Object = v8Value->ToObject(); |
+ PropertyBag bag(isolate, v8Object); |
bool booleanMember; |
- if (DictionaryHelper::get(dictionary, "booleanMember", booleanMember)) |
+ if (bag.get("booleanMember", booleanMember)) |
impl->setBooleanMember(booleanMember); |
double doubleOrNullMember; |
- if (DictionaryHelper::get(dictionary, "doubleOrNullMember", doubleOrNullMember)) |
+ if (bag.get("doubleOrNullMember", doubleOrNullMember)) |
impl->setDoubleOrNullMember(doubleOrNullMember); |
int longMember; |
- if (DictionaryHelper::get(dictionary, "longMember", longMember)) |
+ if (bag.get("longMember", longMember)) |
impl->setLongMember(longMember); |
Vector<String> stringArrayMember; |
- if (DictionaryHelper::get(dictionary, "stringArrayMember", stringArrayMember)) |
+ if (bag.get("stringArrayMember", stringArrayMember)) |
impl->setStringArrayMember(stringArrayMember); |
String stringMember; |
- if (DictionaryHelper::get(dictionary, "stringMember", stringMember)) |
+ if (bag.get("stringMember", stringMember)) |
impl->setStringMember(stringMember); |
String stringOrNullMember; |
- if (DictionaryHelper::get(dictionary, "stringOrNullMember", stringOrNullMember)) |
+ if (bag.get("stringOrNullMember", stringOrNullMember)) |
impl->setStringOrNullMember(stringOrNullMember); |
Vector<String> stringSequenceMember; |
- if (DictionaryHelper::get(dictionary, "stringSequenceMember", stringSequenceMember)) |
+ if (bag.get("stringSequenceMember", stringSequenceMember)) |
impl->setStringSequenceMember(stringSequenceMember); |
RawPtr<TestInterfaceGarbageCollected> testInterfaceGarbageCollectedMember; |
- if (DictionaryHelper::get(dictionary, "testInterfaceGarbageCollectedMember", testInterfaceGarbageCollectedMember)) |
+ if (bag.get("testInterfaceGarbageCollectedMember", testInterfaceGarbageCollectedMember)) |
impl->setTestInterfaceGarbageCollectedMember(testInterfaceGarbageCollectedMember); |
RawPtr<TestInterfaceGarbageCollected> testInterfaceGarbageCollectedOrNullMember; |
- if (DictionaryHelper::get(dictionary, "testInterfaceGarbageCollectedOrNullMember", testInterfaceGarbageCollectedOrNullMember)) |
+ if (bag.get("testInterfaceGarbageCollectedOrNullMember", testInterfaceGarbageCollectedOrNullMember)) |
impl->setTestInterfaceGarbageCollectedOrNullMember(testInterfaceGarbageCollectedOrNullMember); |
RefPtr<TestInterfaceImplementation> testInterfaceMember; |
- if (DictionaryHelper::get(dictionary, "testInterfaceMember", testInterfaceMember)) |
+ if (bag.get("testInterfaceMember", testInterfaceMember)) |
impl->setTestInterfaceMember(testInterfaceMember); |
RefPtr<TestInterfaceImplementation> testInterfaceOrNullMember; |
- if (DictionaryHelper::get(dictionary, "testInterfaceOrNullMember", testInterfaceOrNullMember)) |
+ if (bag.get("testInterfaceOrNullMember", testInterfaceOrNullMember)) |
impl->setTestInterfaceOrNullMember(testInterfaceOrNullMember); |
RefPtrWillBeRawPtr<TestInterfaceWillBeGarbageCollected> testInterfaceWillBeGarbageCollectedMember; |
- if (DictionaryHelper::get(dictionary, "testInterfaceWillBeGarbageCollectedMember", testInterfaceWillBeGarbageCollectedMember)) |
+ if (bag.get("testInterfaceWillBeGarbageCollectedMember", testInterfaceWillBeGarbageCollectedMember)) |
impl->setTestInterfaceWillBeGarbageCollectedMember(testInterfaceWillBeGarbageCollectedMember); |
RefPtrWillBeRawPtr<TestInterfaceWillBeGarbageCollected> testInterfaceWillBeGarbageCollectedOrNullMember; |
- if (DictionaryHelper::get(dictionary, "testInterfaceWillBeGarbageCollectedOrNullMember", testInterfaceWillBeGarbageCollectedOrNullMember)) |
+ if (bag.get("testInterfaceWillBeGarbageCollectedOrNullMember", testInterfaceWillBeGarbageCollectedOrNullMember)) |
impl->setTestInterfaceWillBeGarbageCollectedOrNullMember(testInterfaceWillBeGarbageCollectedOrNullMember); |
return impl; |
} |