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

Unified Diff: sdk/lib/html/dartium/html_dartium.dart

Side-by-side diff isn't available for this file because of its large size.
Issue 12886043: Optimizing createElement_html (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 7 years, 9 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:
Download patch
« no previous file with comments | « sdk/lib/html/dart2js/html_dart2js.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: 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 1fbd92a913fd1698ceed09959695ee1ef8be9142..38d1e98ce1e025ac677554ea8c352662f9979429 100644
--- a/sdk/lib/html/dartium/html_dartium.dart
+++ b/sdk/lib/html/dartium/html_dartium.dart
@@ -10515,12 +10515,13 @@ class _ElementFactoryProvider {
Element element;
if (temp.children.length == 1) {
- element = temp.children[0];
+ element = temp.$dom_firstChild;
} else if (parentTag == 'html' && temp.children.length == 2) {
// In html5 the root <html> tag will always have a <body> and a <head>,
// even though the inner html only contains one of them.
element = temp.children[tag == 'head' ? 0 : 1];
} else {
+ // Throw an exception because too many children.
_singleNode(temp.children);
}
element.remove();
« no previous file with comments | « sdk/lib/html/dart2js/html_dart2js.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