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: tools/dom/src/Validators.dart

Issue 1369573004: Move JS calls out of Dartium code (Closed) Base URL: https://github.com/dart-lang/sdk.git@master
Patch Set: Created 5 years, 3 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 | « sdk/lib/html/dartium/html_dartium.dart ('k') | tools/dom/templates/html/impl/impl_Element.darttemplate » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/dom/src/Validators.dart
diff --git a/tools/dom/src/Validators.dart b/tools/dom/src/Validators.dart
index d7fd920b79400ada5d947f459469a35dd2f70c49..d964153afea1d46ce71e489f3bd4773977f9dc05 100644
--- a/tools/dom/src/Validators.dart
+++ b/tools/dom/src/Validators.dart
@@ -209,11 +209,12 @@ class _ValidatingTreeSanitizer implements NodeTreeSanitizer {
// If getting/indexing attributes throws, count that as corrupt.
attrs = element.attributes;
isAttr = attrs['is'];
+ var corruptedTest1 = Element._hasCorruptedAttributes(element);
+
// On IE, erratically, the hasCorruptedAttributes test can return false,
// even though it clearly is corrupted. A separate copy of the test
// inlining just the basic check seems to help.
- var corruptedTest1 = Element._hasCorruptedAttributes(element);
- var corruptedTest2 = JS('bool', r'!(#.attributes instanceof NamedNodeMap)', element);
+ var corruptedTest2 = Element._hasCorruptedAttributesAdditionalCheck(element);
corrupted = corruptedTest1 || corruptedTest2;
} catch(e) {}
var elementText = 'element unprintable';
« no previous file with comments | « sdk/lib/html/dartium/html_dartium.dart ('k') | tools/dom/templates/html/impl/impl_Element.darttemplate » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698