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

Unified Diff: lib/html/templates/html/impl/impl_DocumentFragment.darttemplate

Issue 11187063: Generate contains() method for list mixin only if not already defined. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 8 years, 2 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
Index: lib/html/templates/html/impl/impl_DocumentFragment.darttemplate
diff --git a/lib/html/templates/html/impl/impl_DocumentFragment.darttemplate b/lib/html/templates/html/impl/impl_DocumentFragment.darttemplate
index 229d58279eed495e8064d137666c864869a30b7b..e8a1e9dc2c1c90e1dff2be723434c3ac2db5ca02 100644
--- a/lib/html/templates/html/impl/impl_DocumentFragment.darttemplate
+++ b/lib/html/templates/html/impl/impl_DocumentFragment.darttemplate
@@ -46,6 +46,10 @@ class _FilteredElementList implements List {
add(value);
}
+ bool contains(Element element) {
+ return element is Element && _childNodes.contains(element);
+ }
+
void sort([Comparator<Element> compare = Comparable.compare]) {
throw const UnsupportedOperationException('TODO(jacobr): should we impl?');
}
« no previous file with comments | « lib/html/templates/html/impl/impl_Document.darttemplate ('k') | lib/html/templates/html/impl/impl_Element.darttemplate » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698