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

Side by Side Diff: tools/dom/templates/html/impl/impl_HTMLTemplateElement.darttemplate

Issue 18162004: [package:mdv] port createInstance change (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: fix copyright line Created 7 years, 5 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 // WARNING: Do not edit - generated code. 5 // WARNING: Do not edit - generated code.
6 6
7 part of $LIBRARYNAME; 7 part of $LIBRARYNAME;
8 8
9 9
10 /** 10 /**
11 * Model-Driven Views (MDV)'s native features enables a wide-range of use cases, 11 * Model-Driven Views (MDV)'s native features enables a wide-range of use cases,
(...skipping 68 matching lines...) Expand 10 before | Expand all | Expand 10 after
80 * 80 *
81 * - [template]: The template element which is about to create and insert an 81 * - [template]: The template element which is about to create and insert an
82 * instance. 82 * instance.
83 * - [model]: The data context for which this instance is being created. 83 * - [model]: The data context for which this instance is being created.
84 * 84 *
85 * The template element will always use the return value of `getInstanceModel` 85 * The template element will always use the return value of `getInstanceModel`
86 * as the model for the new instance. If the syntax does not wish to override 86 * as the model for the new instance. If the syntax does not wish to override
87 * the value, it should simply return the `model` value it was passed. 87 * the value, it should simply return the `model` value it was passed.
88 */ 88 */
89 getInstanceModel(Element template, model) => model; 89 getInstanceModel(Element template, model) => model;
90
91 /**
92 * This syntax method allows a syntax to provide an alterate expansion of
93 * the [template] contents. When the template wants to create an instance,
94 * it will call this method with the template element.
95 *
96 * By default this will call `template.createInstance()`.
97 */
98 getInstanceFragment(Element template) => template.createInstance();
99 } 90 }
100 91
101 92
102 @Experimental 93 @Experimental
103 $(ANNOTATIONS)class $CLASSNAME$EXTENDS$IMPLEMENTS$NATIVESPEC { 94 $(ANNOTATIONS)class $CLASSNAME$EXTENDS$IMPLEMENTS$NATIVESPEC {
104 $!MEMBERS 95 $!MEMBERS
105 96
106 // For real TemplateElement use the actual DOM .content field instead of 97 // For real TemplateElement use the actual DOM .content field instead of
107 // our polyfilled expando. 98 // our polyfilled expando.
108 @Experimental 99 @Experimental
(...skipping 192 matching lines...) Expand 10 before | Expand all | Expand 10 after
301 document.head.append(style); 292 document.head.append(style);
302 } 293 }
303 294
304 /** 295 /**
305 * A mapping of names to Custom Syntax objects. See [CustomBindingSyntax] for 296 * A mapping of names to Custom Syntax objects. See [CustomBindingSyntax] for
306 * more information. 297 * more information.
307 */ 298 */
308 @Experimental 299 @Experimental
309 static Map<String, CustomBindingSyntax> syntax = {}; 300 static Map<String, CustomBindingSyntax> syntax = {};
310 } 301 }
OLDNEW
« pkg/mdv/lib/src/bindings.dart ('K') | « tools/dom/templates/html/impl/impl_Element.darttemplate ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698