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

Unified Diff: Source/bindings/core/v8/custom/V8BlobCustomHelpers.cpp

Issue 373423002: Split Dictionary's get and convert into DictionaryHelper. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 5 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
« no previous file with comments | « Source/bindings/core/v8/DictionaryHelperForCore.cpp ('k') | Source/bindings/core/v8/v8.gypi » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/bindings/core/v8/custom/V8BlobCustomHelpers.cpp
diff --git a/Source/bindings/core/v8/custom/V8BlobCustomHelpers.cpp b/Source/bindings/core/v8/custom/V8BlobCustomHelpers.cpp
index e508bd40cb795bca0301d8298331dd0e4e1b7da2..74d15d0c80d12ef919461a9e8cd80bafbdcfeb6e 100644
--- a/Source/bindings/core/v8/custom/V8BlobCustomHelpers.cpp
+++ b/Source/bindings/core/v8/custom/V8BlobCustomHelpers.cpp
@@ -72,7 +72,7 @@ bool ParsedProperties::parseBlobPropertyBag(v8::Local<v8::Value> propertyBag, co
TONATIVE_DEFAULT(Dictionary, dictionary, Dictionary(propertyBag, isolate), false);
String endings;
- TONATIVE_DEFAULT(bool, containsEndings, dictionary.get("endings", endings), false);
+ TONATIVE_DEFAULT(bool, containsEndings, DictionaryHelper::get(dictionary, "endings", endings), false);
if (containsEndings) {
if (endings != "transparent" && endings != "native") {
exceptionState.throwTypeError("The 'endings' property must be either 'transparent' or 'native'.");
@@ -82,7 +82,7 @@ bool ParsedProperties::parseBlobPropertyBag(v8::Local<v8::Value> propertyBag, co
m_normalizeLineEndingsToNative = true;
}
- TONATIVE_DEFAULT(bool, containsType, dictionary.get("type", m_contentType), false);
+ TONATIVE_DEFAULT(bool, containsType, DictionaryHelper::get(dictionary, "type", m_contentType), false);
if (containsType) {
if (!m_contentType.containsOnlyASCII()) {
exceptionState.throwDOMException(SyntaxError, "The 'type' property must consist of ASCII characters.");
@@ -95,7 +95,7 @@ bool ParsedProperties::parseBlobPropertyBag(v8::Local<v8::Value> propertyBag, co
return true;
v8::Local<v8::Value> lastModified;
- TONATIVE_DEFAULT(bool, containsLastModified, dictionary.get("lastModified", lastModified), false);
+ TONATIVE_DEFAULT(bool, containsLastModified, DictionaryHelper::get(dictionary, "lastModified", lastModified), false);
if (containsLastModified) {
TONATIVE_DEFAULT(long long, lastModifiedInt, toInt64(lastModified), false);
setLastModified(static_cast<double>(lastModifiedInt) / msPerSecond);
« no previous file with comments | « Source/bindings/core/v8/DictionaryHelperForCore.cpp ('k') | Source/bindings/core/v8/v8.gypi » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698