| Index: pkg/mdv/lib/src/text.dart
|
| diff --git a/tools/dom/templates/html/impl/impl_Text.darttemplate b/pkg/mdv/lib/src/text.dart
|
| similarity index 59%
|
| copy from tools/dom/templates/html/impl/impl_Text.darttemplate
|
| copy to pkg/mdv/lib/src/text.dart
|
| index 2675d8bc677850f05ed3f789fefee30f3a9eac9b..6d2b380011938a85dc7227b7feb82f221b42a7fc 100644
|
| --- a/tools/dom/templates/html/impl/impl_Text.darttemplate
|
| +++ b/pkg/mdv/lib/src/text.dart
|
| @@ -1,21 +1,17 @@
|
| -// Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file
|
| +// Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file
|
| // for details. All rights reserved. Use of this source code is governed by a
|
| // BSD-style license that can be found in the LICENSE file.
|
|
|
| -// WARNING: Do not edit - generated code.
|
| +part of mdv;
|
|
|
| -part of $LIBRARYNAME;
|
| +/** Extensions to the [Text] API. */
|
| +class _TextExtension extends _NodeExtension {
|
| + _TextExtension(Text node) : super(node);
|
|
|
| -$(ANNOTATIONS)class $CLASSNAME$EXTENDS$IMPLEMENTS$NATIVESPEC {
|
| - factory $CLASSNAME(String data) => document.$dom_createTextNode(data);
|
| -$!MEMBERS
|
| + Text get node => super.node;
|
|
|
| -$if DART2JS
|
| - @Creates('Null') // Set from Dart code; does not instantiate a native type.
|
| -$endif
|
| StreamSubscription _textBinding;
|
|
|
| - @Experimental
|
| void bind(String name, model, String path) {
|
| if (name != 'text') {
|
| super.bind(name, model, path);
|
| @@ -25,11 +21,10 @@ $endif
|
| unbind('text');
|
|
|
| _textBinding = new PathObserver(model, path).bindSync((value) {
|
| - text = value == null ? '' : '$value';
|
| + node.text = value == null ? '' : '$value';
|
| });
|
| }
|
|
|
| - @Experimental
|
| void unbind(String name) {
|
| if (name != 'text') {
|
| super.unbind(name);
|
| @@ -42,7 +37,6 @@ $endif
|
| _textBinding = null;
|
| }
|
|
|
| - @Experimental
|
| void unbindAll() {
|
| unbind('text');
|
| super.unbindAll();
|
|
|