Title: [100247] trunk
- Revision
- 100247
- Author
- tk...@chromium.org
- Date
- 2011-11-15 00:36:56 -0800 (Tue, 15 Nov 2011)
Log Message
[V8] Fix incorrect handling of _javascript_ properties in DOMStringMap
https://bugs.webkit.org/show_bug.cgi?id=53578
Reviewed by Adam Barth.
Source/WebCore:
Follows a JSC behavior change by r96893.
* bindings/v8/custom/V8DOMStringMapCustom.cpp:
(WebCore::V8DOMStringMap::namedPropertyGetter):
Propagate to the _javascript_ object if the DOMStringMap object
doesn't have the requested item.
(WebCore::V8DOMStringMap::namedPropertyDeleter): ditto.
(WebCore::V8DOMStringMap::namedPropertySetter):
Try to set a property to only a DOMStringMap object.
LayoutTests:
* platform/chromium/test_expectations.txt:
Remove failure expectations of fast/dom/dataset.html and
fast/dom/dataset-xhtml.xhtml.
Modified Paths
Diff
Modified: trunk/LayoutTests/ChangeLog (100246 => 100247)
--- trunk/LayoutTests/ChangeLog 2011-11-15 08:08:59 UTC (rev 100246)
+++ trunk/LayoutTests/ChangeLog 2011-11-15 08:36:56 UTC (rev 100247)
@@ -1,3 +1,14 @@
+2011-11-15 Kent Tamura <tk...@chromium.org>
+
+ [V8] Fix incorrect handling of _javascript_ properties in DOMStringMap
+ https://bugs.webkit.org/show_bug.cgi?id=53578
+
+ Reviewed by Adam Barth.
+
+ * platform/chromium/test_expectations.txt:
+ Remove failure expectations of fast/dom/dataset.html and
+ fast/dom/dataset-xhtml.xhtml.
+
2011-11-14 Pavel Feldman <pfeld...@google.com>
Web Inspector: Command line $x fails for 3 of 4 types of XPath query
Modified: trunk/LayoutTests/platform/chromium/test_expectations.txt (100246 => 100247)
--- trunk/LayoutTests/platform/chromium/test_expectations.txt 2011-11-15 08:08:59 UTC (rev 100246)
+++ trunk/LayoutTests/platform/chromium/test_expectations.txt 2011-11-15 08:36:56 UTC (rev 100247)
@@ -3673,10 +3673,6 @@
BUGWK68982 : svg/custom/oversized-pattern-scale.svg = IMAGE PASS
BUGWK68982 : svg/custom/transformed-pattern-clamp-svg-root.svg = IMAGE PASS
-// Need to follow a JSC binding change. See webkit.org/b/53752.
-BUGWK53578 : fast/dom/dataset.html = TEXT
-BUGWK53578 : fast/dom/dataset-xhtml.xhtml = TEXT
-
BUGWK69060 WIN LINUX : fast/repaint/selection-clear.html = IMAGE+TEXT
BUGWK69062 WIN GPU : compositing/shadows/shadow-drawing.html = IMAGE
Modified: trunk/Source/WebCore/ChangeLog (100246 => 100247)
--- trunk/Source/WebCore/ChangeLog 2011-11-15 08:08:59 UTC (rev 100246)
+++ trunk/Source/WebCore/ChangeLog 2011-11-15 08:36:56 UTC (rev 100247)
@@ -1,3 +1,20 @@
+2011-11-15 Kent Tamura <tk...@chromium.org>
+
+ [V8] Fix incorrect handling of _javascript_ properties in DOMStringMap
+ https://bugs.webkit.org/show_bug.cgi?id=53578
+
+ Reviewed by Adam Barth.
+
+ Follows a JSC behavior change by r96893.
+
+ * bindings/v8/custom/V8DOMStringMapCustom.cpp:
+ (WebCore::V8DOMStringMap::namedPropertyGetter):
+ Propagate to the _javascript_ object if the DOMStringMap object
+ doesn't have the requested item.
+ (WebCore::V8DOMStringMap::namedPropertyDeleter): ditto.
+ (WebCore::V8DOMStringMap::namedPropertySetter):
+ Try to set a property to only a DOMStringMap object.
+
2011-11-14 Pavel Feldman <pfeld...@google.com>
Web Inspector: Command line $x fails for 3 of 4 types of XPath query
Modified: trunk/Source/WebCore/bindings/v8/custom/V8DOMStringMapCustom.cpp (100246 => 100247)
--- trunk/Source/WebCore/bindings/v8/custom/V8DOMStringMapCustom.cpp 2011-11-15 08:08:59 UTC (rev 100246)
+++ trunk/Source/WebCore/bindings/v8/custom/V8DOMStringMapCustom.cpp 2011-11-15 08:36:56 UTC (rev 100247)
@@ -49,7 +49,10 @@
v8::Handle<v8::Value> V8DOMStringMap::namedPropertyGetter(v8::Local<v8::String> name, const v8::AccessorInfo& info)
{
INC_STATS("DOM.DOMStringMap.NamedPropertyGetter");
- return v8StringOrUndefined(V8DOMStringMap::toNative(info.Holder())->item(toWebCoreString(name)));
+ String value = V8DOMStringMap::toNative(info.Holder())->item(toWebCoreString(name));
+ if (value.isNull())
+ return notHandledByInterceptor();
+ return v8StringOrUndefined(value);
}
v8::Handle<v8::Array> V8DOMStringMap::namedPropertyEnumerator(const v8::AccessorInfo& info)
@@ -66,28 +69,14 @@
v8::Handle<v8::Boolean> V8DOMStringMap::namedPropertyDeleter(v8::Local<v8::String> name, const v8::AccessorInfo& info)
{
INC_STATS("DOM.DOMStringMap.NamedPropertyDeleter");
-
- if (!info.Holder()->GetRealNamedPropertyInPrototypeChain(name).IsEmpty())
- return v8::False();
- if (info.Holder()->HasRealNamedCallbackProperty(name))
- return v8::False();
-
ExceptionCode ec = 0;
V8DOMStringMap::toNative(info.Holder())->deleteItem(toWebCoreString(name), ec);
- if (ec)
- throwError(ec);
- return v8::True();
+ return ec ? v8::False() : v8::True();
}
v8::Handle<v8::Value> V8DOMStringMap::namedPropertySetter(v8::Local<v8::String> name, v8::Local<v8::Value> value, const v8::AccessorInfo& info)
{
INC_STATS("DOM.DOMStringMap.NamedPropertySetter");
-
- if (!info.Holder()->GetRealNamedPropertyInPrototypeChain(name).IsEmpty())
- return value;
- if (info.Holder()->HasRealNamedCallbackProperty(name))
- return value;
-
ExceptionCode ec = 0;
V8DOMStringMap::toNative(info.Holder())->setItem(toWebCoreString(name), toWebCoreString(value), ec);
if (ec)
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
http://lists.webkit.org/mailman/listinfo.cgi/webkit-changes