Index: sdk/lib/html/dartium/html_dartium.dart |
diff --git a/sdk/lib/html/dartium/html_dartium.dart b/sdk/lib/html/dartium/html_dartium.dart |
index a4d3eb755b61d0b3ac9a44b42ab3225d92542bc8..1f9f0249c529ff39b5b82b67c3128ab37ad7d945 100644 |
--- a/sdk/lib/html/dartium/html_dartium.dart |
+++ b/sdk/lib/html/dartium/html_dartium.dart |
@@ -1219,7 +1219,7 @@ class DartHtmlDomObject { |
// Flag to disable JS interop asserts. Setting to false will speed up the |
// wrap_jso calls. |
-bool __interop_checks = true; |
+bool __interop_checks = false; |
/** Expando for JsObject, used by every Dart class associated with a Javascript |
* class (e.g., DOM, WebAudio, etc.). |
@@ -1304,7 +1304,11 @@ wrap_jso(jsObject) { |
} |
// Custom Element to upgrade. |
- if (customElementClass != null && extendsTag == "") { |
+ // Only allow custome elements to be created in the html or svg default |
+ // namespace. |
+ var defaultNS = jsObject['namespaceURI'] == 'http://www.w3.org/1999/xhtml' || |
+ jsObject['namespaceURI'] == 'http://www.w3.org/2000/svg'; |
+ if (customElementClass != null && extendsTag == "" && defaultNS) { |
try { |
dartClass_instance = _blink.Blink_Utils.constructElement(customElementClass, jsObject); |
} finally { |