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

Side by Side Diff: runtime/observatory/lib/src/elements/action_link.dart

Issue 2310003004: Removed polymer & mirror from Observatory (Closed)
Patch Set: Fixed crash in heap-map page Created 4 years, 3 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
OLDNEW
(Empty)
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
3 // BSD-style license that can be found in the LICENSE file.
4
5 library action_link_element;
6
7 import 'observatory_element.dart';
8 import 'package:polymer/polymer.dart';
9
10 @CustomTag('action-link')
11 class ActionLinkElement extends ObservatoryElement {
12 ActionLinkElement.created() : super.created();
13
14 @observable bool busy = false;
15 @published var callback = null;
16 @published String label = 'action';
17 @published String color = null;
18
19 void doAction(var a, var b, var c) {
20 if (busy) {
21 return;
22 }
23 if (callback != null) {
24 busy = true;
25 callback()
26 .catchError(app.handleException)
27 .whenComplete(() {
28 busy = false;
29 });
30 }
31 }
32 }
OLDNEW
« no previous file with comments | « runtime/observatory/lib/src/app/view_model.dart ('k') | runtime/observatory/lib/src/elements/action_link.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698