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

Side by Side Diff: samples/third_party/todomvc/web/todo_row.dart

Issue 27618002: package:observe fix various api issues (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 7 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « samples/third_party/todomvc/web/model.dart ('k') | samples/tracker/lib/models.dart » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2013, 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 library todomvc.web.todo_row; 5 library todomvc.web.todo_row;
6 6
7 import 'dart:html'; 7 import 'dart:html';
8 import 'package:polymer/polymer.dart'; 8 import 'package:polymer/polymer.dart';
9 import 'model.dart'; 9 import 'model.dart';
10 10
11 @CustomTag('todo-row') 11 @CustomTag('todo-row')
12 class TodoRow extends LIElement with Polymer, ObservableMixin { 12 class TodoRow extends LIElement with Polymer, Observable {
13 @published Todo todo; 13 @published Todo todo;
14 14
15 bool get applyAuthorStyles => true; 15 bool get applyAuthorStyles => true;
16 16
17 factory TodoRow() => new Element.tag('todo-row'); 17 factory TodoRow() => new Element.tag('todo-row');
18 18
19 TodoRow.created() : super.created() { 19 TodoRow.created() : super.created() {
20 polymerCreated(); 20 polymerCreated();
21 } 21 }
22 22
23 void ready() { 23 void ready() {
24 var root = getShadowRoot("todo-row"); 24 var root = getShadowRoot("todo-row");
25 var label = root.query('#label'); 25 var label = root.query('#label');
26 var item = root.query('.todo-item'); 26 var item = root.query('.todo-item');
27 27
28 bindCssClass(item, 'completed', this, 'todo.done'); 28 bindCssClass(item, 'completed', this, 'todo.done');
29 bindCssClass(item, 'editing', label, 'editing'); 29 bindCssClass(item, 'editing', label, 'editing');
30 } 30 }
31 31
32 void removeTodo() => appModel.todos.remove(todo); 32 void removeTodo() => appModel.todos.remove(todo);
33 } 33 }
OLDNEW
« no previous file with comments | « samples/third_party/todomvc/web/model.dart ('k') | samples/tracker/lib/models.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698