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

Unified Diff: src/site/docs/tutorials/polymer-intro/examples/stopwatch/out/web/tute_stopwatch.dart

Issue 26922002: removing Web UI tutorials, updating remaining 4 to current release, + review pass (Closed) Base URL: https://github.com/dart-lang/dartlang.org.git@master
Patch Set: merge with master 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 side-by-side diff with in-line comments
Download patch
Index: src/site/docs/tutorials/polymer-intro/examples/stopwatch/out/web/tute_stopwatch.dart
diff --git a/src/site/docs/tutorials/polymer-intro/examples/stopwatch/out/web/tute_stopwatch.dart b/src/site/docs/tutorials/polymer-intro/examples/stopwatch/out/web/tute_stopwatch.dart
index 4ec2f03dac7b36dd0a1b471fbcfe1ea04e39ac06..5e5f0617e97d75dd549b22d41b09abb5f04e8151 100644
--- a/src/site/docs/tutorials/polymer-intro/examples/stopwatch/out/web/tute_stopwatch.dart
+++ b/src/site/docs/tutorials/polymer-intro/examples/stopwatch/out/web/tute_stopwatch.dart
@@ -3,13 +3,8 @@ import 'dart:async';
import 'package:polymer/polymer.dart';
@CustomTag('tute-stopwatch')
-class TuteStopwatch extends PolymerElement with ChangeNotifierMixin {
- String __$counter = '00:00';
- String get counter => __$counter;
- set counter(String value) {
- __$counter = notifyPropertyChange(const Symbol('counter'), __$counter, value);
- }
-
+class TuteStopwatch extends PolymerElement {
+ @observable String get counter => __$counter; String __$counter='00:00'; set counter(String value) { __$counter = notifyPropertyChange(#counter, __$counter, value); }
Stopwatch mywatch = new Stopwatch();
Timer mytimer;
@@ -20,9 +15,9 @@ class TuteStopwatch extends PolymerElement with ChangeNotifierMixin {
void inserted() {
super.inserted();
- startButton = getShadowRoot('tute-stopwatch').query('#startButton');
- stopButton = getShadowRoot('tute-stopwatch').query('#stopButton');
- resetButton = getShadowRoot('tute-stopwatch').query('#resetButton');
+ startButton = $['startButton'];
+ stopButton = $['stopButton'];
+ resetButton = $['resetButton'];
stopButton.disabled = true;
resetButton.disabled = true;

Powered by Google App Engine
This is Rietveld 408576698