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

Unified Diff: runtime/bin/vmservice/client/lib/src/observatory_elements/collapsible_content.dart

Issue 50243002: Extend Observatory to display libraries, classes, fields, functions and code. (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 side-by-side diff with in-line comments
Download patch
Index: runtime/bin/vmservice/client/lib/src/observatory_elements/collapsible_content.dart
diff --git a/runtime/bin/vmservice/client/lib/src/observatory_elements/collapsible_content.dart b/runtime/bin/vmservice/client/lib/src/observatory_elements/collapsible_content.dart
index 5422447ff5e8ae0aa936fec356ca625b97a3befe..babd9017e6f071f1e6df44d30c2163dac07a0358 100644
--- a/runtime/bin/vmservice/client/lib/src/observatory_elements/collapsible_content.dart
+++ b/runtime/bin/vmservice/client/lib/src/observatory_elements/collapsible_content.dart
@@ -14,8 +14,8 @@ class CollapsibleContentElement extends ObservatoryElement {
static const String _openIconClass = 'glyphicon glyphicon-chevron-down';
static const String _closeIconClass = 'glyphicon glyphicon-chevron-up';
- @observable String get iconClass => __$iconClass; String __$iconClass = _openIconClass; set iconClass(String value) { __$iconClass = notifyPropertyChange(#iconClass, __$iconClass, value); }
- @observable String get displayValue => __$displayValue; String __$displayValue = 'none'; set displayValue(String value) { __$displayValue = notifyPropertyChange(#displayValue, __$displayValue, value); }
+ @observable String iconClass = _openIconClass;
+ @observable String displayValue = 'none';
bool _collapsed = true;
bool get collapsed => _collapsed;
@@ -24,16 +24,20 @@ class CollapsibleContentElement extends ObservatoryElement {
_refresh();
}
- void toggleDisplay(Event e, var detail, Node target) {
- collapsed = !collapsed;
+ CollapsibleContentElement.created() : super.created();
+
+ void enteredView() {
+ super.enteredView();
_refresh();
}
- void inserted() {
- super.inserted();
+ void toggleDisplay(Event e, var detail, Node target) {
+ collapsed = !collapsed;
_refresh();
}
+
+
void _refresh() {
if (_collapsed) {
iconClass = _openIconClass;

Powered by Google App Engine
This is Rietveld 408576698