Index: runtime/observatory/lib/src/elements/instance_view.dart |
diff --git a/runtime/observatory/lib/src/elements/instance_view.dart b/runtime/observatory/lib/src/elements/instance_view.dart |
index 668da170b25df07796e39eeceb0b6284671c3891..1a33542ed0597f8adb180c5f883114a84840535d 100644 |
--- a/runtime/observatory/lib/src/elements/instance_view.dart |
+++ b/runtime/observatory/lib/src/elements/instance_view.dart |
@@ -33,26 +33,26 @@ import 'package:observatory/src/elements/view_footer.dart'; |
import 'package:observatory/utils.dart'; |
class InstanceViewElement extends HtmlElement implements Renderable { |
- static const tag = const Tag<InstanceViewElement>('instance-view', |
- dependencies: const [ |
- ClassRefElement.tag, |
- ContextRefElement.tag, |
- CurlyBlockElement.tag, |
- FieldRefElement.tag, |
- FunctionRefElement.tag, |
- InstanceRefElement.tag, |
- NavClassMenuElement.tag, |
- NavLibraryMenuElement.tag, |
- NavTopMenuElement.tag, |
- NavVMMenuElement.tag, |
- NavIsolateMenuElement.tag, |
- NavRefreshElement.tag, |
- NavNotifyElement.tag, |
- ObjectCommonElement.tag, |
- SourceInsetElement.tag, |
- SourceLinkElement.tag, |
- ViewFooterElement.tag |
- ]); |
+ static const tag = |
+ const Tag<InstanceViewElement>('instance-view', dependencies: const [ |
+ ClassRefElement.tag, |
+ ContextRefElement.tag, |
+ CurlyBlockElement.tag, |
+ FieldRefElement.tag, |
+ FunctionRefElement.tag, |
+ InstanceRefElement.tag, |
+ NavClassMenuElement.tag, |
+ NavLibraryMenuElement.tag, |
+ NavTopMenuElement.tag, |
+ NavVMMenuElement.tag, |
+ NavIsolateMenuElement.tag, |
+ NavRefreshElement.tag, |
+ NavNotifyElement.tag, |
+ ObjectCommonElement.tag, |
+ SourceInsetElement.tag, |
+ SourceLinkElement.tag, |
+ ViewFooterElement.tag |
+ ]); |
RenderingScheduler<InstanceViewElement> _r; |
@@ -78,28 +78,29 @@ class InstanceViewElement extends HtmlElement implements Renderable { |
M.FunctionRepository _functions; |
M.SourceLocation _location; |
- |
M.VMRef get vm => _vm; |
M.IsolateRef get isolate => _isolate; |
M.NotificationRepository get notifications => _notifications; |
M.Instance get instance => _instance; |
- factory InstanceViewElement(M.VM vm, M.IsolateRef isolate, |
- M.Instance instance, |
- M.EventRepository events, |
- M.NotificationRepository notifications, |
- M.InstanceRepository instances, |
- M.ClassRepository classes, |
- M.RetainedSizeRepository retainedSizes, |
- M.ReachableSizeRepository reachableSizes, |
- M.InboundReferencesRepository references, |
- M.RetainingPathRepository retainingPaths, |
- M.ScriptRepository scripts, |
- M.EvalRepository eval, |
- M.TypeArgumentsRepository arguments, |
- M.BreakpointRepository breakpoints, |
- M.FunctionRepository functions, |
- {RenderingQueue queue}) { |
+ factory InstanceViewElement( |
+ M.VM vm, |
+ M.IsolateRef isolate, |
+ M.Instance instance, |
+ M.EventRepository events, |
+ M.NotificationRepository notifications, |
+ M.InstanceRepository instances, |
+ M.ClassRepository classes, |
+ M.RetainedSizeRepository retainedSizes, |
+ M.ReachableSizeRepository reachableSizes, |
+ M.InboundReferencesRepository references, |
+ M.RetainingPathRepository retainingPaths, |
+ M.ScriptRepository scripts, |
+ M.EvalRepository eval, |
+ M.TypeArgumentsRepository arguments, |
+ M.BreakpointRepository breakpoints, |
+ M.FunctionRepository functions, |
+ {RenderingQueue queue}) { |
assert(vm != null); |
assert(isolate != null); |
assert(events != null); |
@@ -155,38 +156,38 @@ class InstanceViewElement extends HtmlElement implements Renderable { |
void render() { |
final content = [ |
- new HeadingElement.h2()..text = M.isAbstractType(_instance.kind) |
- ? 'type ${_instance.name}' |
- : 'instance of ${_instance.clazz.name}', |
+ new HeadingElement.h2() |
+ ..text = M.isAbstractType(_instance.kind) |
+ ? 'type ${_instance.name}' |
+ : 'instance of ${_instance.clazz.name}', |
new HRElement(), |
new ObjectCommonElement(_isolate, _instance, _retainedSizes, |
- _reachableSizes, _references, _retainingPaths, |
- _instances, queue: _r.queue), |
+ _reachableSizes, _references, _retainingPaths, _instances, |
+ queue: _r.queue), |
new BRElement(), |
- new DivElement()..classes = ['memberList'] |
+ new DivElement() |
+ ..classes = ['memberList'] |
..children = _createMembers(), |
new HRElement(), |
new EvalBoxElement(_isolate, _instance, _instances, _eval, |
- quickExpressions: const ['toString()', |
- 'runtimeType'], |
- queue: _r.queue) |
+ quickExpressions: const ['toString()', 'runtimeType'], |
+ queue: _r.queue) |
]; |
if (_location != null) { |
content.addAll([ |
new HRElement(), |
- new SourceInsetElement(_isolate, _location, _scripts, _instances, |
- _events, queue: _r.queue) |
+ new SourceInsetElement( |
+ _isolate, _location, _scripts, _instances, _events, |
+ queue: _r.queue) |
]); |
} |
- content.addAll([ |
- new HRElement(), |
- new ViewFooterElement(queue: _r.queue) |
- ]); |
+ content.addAll([new HRElement(), new ViewFooterElement(queue: _r.queue)]); |
children = [ |
navBar(_createMenu()), |
- new DivElement()..classes = ['content-centered-big'] |
+ new DivElement() |
+ ..classes = ['content-centered-big'] |
..children = content |
- ]; |
+ ]; |
} |
List<Element> _createMenu() { |
@@ -196,17 +197,16 @@ class InstanceViewElement extends HtmlElement implements Renderable { |
new NavIsolateMenuElement(_isolate, _events, queue: _r.queue) |
]; |
if (_library != null) { |
- menu.add(new NavLibraryMenuElement(_isolate, _library, |
- queue: _r.queue)); |
+ menu.add(new NavLibraryMenuElement(_isolate, _library, queue: _r.queue)); |
} |
menu.addAll([ |
new NavClassMenuElement(_isolate, _instance.clazz, queue: _r.queue), |
navMenu('instance'), |
new NavRefreshElement(queue: _r.queue) |
- ..onRefresh.listen((e) { |
- e.element.disabled = true; |
- _refresh(); |
- }), |
+ ..onRefresh.listen((e) { |
+ e.element.disabled = true; |
+ _refresh(); |
+ }), |
new NavNotifyElement(_notifications, queue: _r.queue) |
]); |
return menu; |
@@ -215,130 +215,158 @@ class InstanceViewElement extends HtmlElement implements Renderable { |
List<Element> _createMembers() { |
final members = <Element>[]; |
if (_instance.valueAsString != null) { |
- members.add(new DivElement()..classes = ['memberItem'] |
+ members.add(new DivElement() |
+ ..classes = ['memberItem'] |
..children = [ |
- new DivElement()..classes = ['memberName'] |
+ new DivElement() |
+ ..classes = ['memberName'] |
..text = _instance.kind == M.InstanceKind.string |
- ? 'value as literal' |
- : 'value', |
- new DivElement()..classes = ['memberValue'] |
+ ? 'value as literal' |
+ : 'value', |
+ new DivElement() |
+ ..classes = ['memberValue'] |
..text = _instance.kind == M.InstanceKind.string |
- ? Utils.formatStringAsLiteral(_instance.valueAsString, |
- _instance.valueAsStringIsTruncated) |
- : _instance.valueAsString |
+ ? Utils.formatStringAsLiteral( |
+ _instance.valueAsString, _instance.valueAsStringIsTruncated) |
+ : _instance.valueAsString |
]); |
} |
if (_instance.typeClass != null) { |
- members.add(new DivElement()..classes = ['memberItem'] |
+ members.add(new DivElement() |
+ ..classes = ['memberItem'] |
..children = [ |
- new DivElement()..classes = ['memberName'] |
+ new DivElement() |
+ ..classes = ['memberName'] |
..text = 'type class', |
- new DivElement()..classes = ['memberValue'] |
+ new DivElement() |
+ ..classes = ['memberValue'] |
..children = [ |
new ClassRefElement(_isolate, _instance.typeClass, |
- queue: _r.queue) |
+ queue: _r.queue) |
] |
]); |
} |
if (_typeArguments != null && _typeArguments.types.isNotEmpty) { |
- members.add(new DivElement()..classes = ['memberItem'] |
+ members.add(new DivElement() |
+ ..classes = ['memberItem'] |
..children = [ |
- new DivElement()..classes = ['memberName'] |
+ new DivElement() |
+ ..classes = ['memberName'] |
..text = 'type arguments', |
- new DivElement()..classes = ['memberValue'] |
- ..children = ([ |
- new SpanElement()..text = '< ' |
- ] |
- ..addAll(_typeArguments.types.expand((type) => [ |
- new InstanceRefElement(_isolate, type, _instances, queue: |
- _r.queue), |
- new SpanElement()..text = ', ' |
- ])) |
- ..removeLast() |
- ..add(new SpanElement()..text = ' >')) |
+ new DivElement() |
+ ..classes = ['memberValue'] |
+ ..children = ([new SpanElement()..text = '< '] |
+ ..addAll(_typeArguments.types.expand((type) => [ |
+ new InstanceRefElement(_isolate, type, _instances, |
+ queue: _r.queue), |
+ new SpanElement()..text = ', ' |
+ ])) |
+ ..removeLast() |
+ ..add(new SpanElement()..text = ' >')) |
]); |
} |
if (_instance.parameterizedClass != null) { |
- members.add(new DivElement()..classes = ['memberItem'] |
+ members.add(new DivElement() |
+ ..classes = ['memberItem'] |
..children = [ |
- new DivElement()..classes = ['memberName'] |
+ new DivElement() |
+ ..classes = ['memberName'] |
..text = 'parameterized class', |
- new DivElement()..classes = ['memberValue'] |
+ new DivElement() |
+ ..classes = ['memberValue'] |
..children = [ |
new ClassRefElement(_isolate, _instance.parameterizedClass, |
- queue: _r.queue) |
+ queue: _r.queue) |
] |
]); |
} |
if (_instance.parameterIndex != null) { |
- members.add(new DivElement()..classes = ['memberItem'] |
+ members.add(new DivElement() |
+ ..classes = ['memberItem'] |
..children = [ |
- new DivElement()..classes = ['memberName'] |
+ new DivElement() |
+ ..classes = ['memberName'] |
..text = 'parameter index', |
- new DivElement()..classes = ['memberValue'] |
+ new DivElement() |
+ ..classes = ['memberValue'] |
..text = '${_instance.parameterIndex}' |
]); |
} |
if (_instance.targetType != null) { |
- members.add(new DivElement()..classes = ['memberItem'] |
+ members.add(new DivElement() |
+ ..classes = ['memberItem'] |
..children = [ |
- new DivElement()..classes = ['memberName'] |
+ new DivElement() |
+ ..classes = ['memberName'] |
..text = 'target type', |
- new DivElement()..classes = ['memberValue'] |
+ new DivElement() |
+ ..classes = ['memberValue'] |
..children = [ |
new InstanceRefElement(_isolate, _instance.targetType, _instances, |
- queue: _r.queue) |
+ queue: _r.queue) |
] |
]); |
} |
if (_instance.bound != null) { |
- members.add(new DivElement()..classes = ['memberItem'] |
+ members.add(new DivElement() |
+ ..classes = ['memberItem'] |
..children = [ |
- new DivElement()..classes = ['memberName'] |
+ new DivElement() |
+ ..classes = ['memberName'] |
..text = 'bound', |
- new DivElement()..classes = ['memberValue'] |
+ new DivElement() |
+ ..classes = ['memberValue'] |
..children = [ |
new InstanceRefElement(_isolate, _instance.bound, _instances, |
- queue: _r.queue) |
+ queue: _r.queue) |
] |
]); |
} |
if (_instance.closureFunction != null) { |
- members.add(new DivElement()..classes = ['memberItem'] |
+ members.add(new DivElement() |
+ ..classes = ['memberItem'] |
..children = [ |
- new DivElement()..classes = ['memberName'] |
+ new DivElement() |
+ ..classes = ['memberName'] |
..text = 'closure function', |
- new DivElement()..classes = ['memberValue'] |
+ new DivElement() |
+ ..classes = ['memberValue'] |
..children = [ |
new FunctionRefElement(_isolate, _instance.closureFunction, |
- queue: _r.queue) |
+ queue: _r.queue) |
] |
]); |
} |
if (_instance.closureContext != null) { |
- members.add(new DivElement()..classes = ['memberItem'] |
+ members.add(new DivElement() |
+ ..classes = ['memberItem'] |
..children = [ |
- new DivElement()..classes = ['memberName'] |
+ new DivElement() |
+ ..classes = ['memberName'] |
..text = 'closure context', |
- new DivElement()..classes = ['memberValue'] |
+ new DivElement() |
+ ..classes = ['memberValue'] |
..children = [ |
new ContextRefElement(_isolate, _instance.closureContext, |
- queue: _r.queue) |
+ queue: _r.queue) |
] |
]); |
} |
if (_instance.kind == M.InstanceKind.closure) { |
ButtonElement btn; |
- members.add(new DivElement()..classes = ['memberItem'] |
+ members.add(new DivElement() |
+ ..classes = ['memberItem'] |
..children = [ |
- new DivElement()..classes = ['memberName'] |
+ new DivElement() |
+ ..classes = ['memberName'] |
..text = 'closure breakpoint', |
- new DivElement()..classes = ['memberValue'] |
+ new DivElement() |
+ ..classes = ['memberValue'] |
..children = [ |
btn = new ButtonElement() |
..text = _instance.activationBreakpoint == null |
- ? 'break on activation' |
- : 'remove' |
+ ? 'break on activation' |
+ : 'remove' |
..onClick.listen((_) { |
btn.disabled = true; |
_toggleBreakpoint(); |
@@ -349,25 +377,33 @@ class InstanceViewElement extends HtmlElement implements Renderable { |
if (_instance.nativeFields != null && _instance.nativeFields.isNotEmpty) { |
int i = 0; |
- members.add(new DivElement()..classes = ['memberItem'] |
+ members.add(new DivElement() |
+ ..classes = ['memberItem'] |
..children = [ |
- new DivElement()..classes = ['memberName'] |
+ new DivElement() |
+ ..classes = ['memberName'] |
..text = 'native fields (${_instance.nativeFields.length})', |
- new DivElement()..classes = ['memberName'] |
+ new DivElement() |
+ ..classes = ['memberName'] |
..children = [ |
new CurlyBlockElement( |
expanded: _instance.nativeFields.length <= 100, |
queue: _r.queue) |
..content = [ |
- new DivElement()..classes = ['memberList'] |
- ..children = _instance.nativeFields.map((f) => |
- new DivElement()..classes = ['memberItem'] |
- ..children = [ |
- new DivElement()..classes = ['memberName'] |
- ..text = '[ ${i++} ]', |
- new DivElement()..classes = ['memberValue'] |
- ..text = '[ ${f.value} ]' |
- ]).toList() |
+ new DivElement() |
+ ..classes = ['memberList'] |
+ ..children = _instance.nativeFields |
+ .map((f) => new DivElement() |
+ ..classes = ['memberItem'] |
+ ..children = [ |
+ new DivElement() |
+ ..classes = ['memberName'] |
+ ..text = '[ ${i++} ]', |
+ new DivElement() |
+ ..classes = ['memberValue'] |
+ ..text = '[ ${f.value} ]' |
+ ]) |
+ .toList() |
] |
] |
]); |
@@ -375,32 +411,40 @@ class InstanceViewElement extends HtmlElement implements Renderable { |
if (_instance.fields != null && _instance.fields.isNotEmpty) { |
final fields = _instance.fields.toList(); |
- members.add(new DivElement()..classes = ['memberItem'] |
+ members.add(new DivElement() |
+ ..classes = ['memberItem'] |
..children = [ |
- new DivElement()..classes = ['memberName'] |
+ new DivElement() |
+ ..classes = ['memberName'] |
..text = 'fields (${fields.length})', |
- new DivElement()..classes = ['memberName'] |
+ new DivElement() |
+ ..classes = ['memberName'] |
..children = [ |
new CurlyBlockElement( |
- expanded: fields.length <= 100, |
- queue: _r.queue) |
+ expanded: fields.length <= 100, queue: _r.queue) |
..content = [ |
- new DivElement()..classes = ['memberList'] |
- ..children = fields.map((f) => |
- new DivElement()..classes = ['memberItem'] |
- ..children = [ |
- new DivElement()..classes = ['memberName'] |
- ..children = [ |
- new FieldRefElement(_isolate, f.decl, _instances, |
- queue: _r.queue) |
- ], |
- new DivElement()..classes = ['memberValue'] |
- ..children = [ |
- new SpanElement()..text = ' = ', |
- anyRef(_isolate, f.value, _instances, |
- queue: _r.queue) |
- ] |
- ]).toList() |
+ new DivElement() |
+ ..classes = ['memberList'] |
+ ..children = fields |
+ .map((f) => new DivElement() |
+ ..classes = ['memberItem'] |
+ ..children = [ |
+ new DivElement() |
+ ..classes = ['memberName'] |
+ ..children = [ |
+ new FieldRefElement( |
+ _isolate, f.decl, _instances, |
+ queue: _r.queue) |
+ ], |
+ new DivElement() |
+ ..classes = ['memberValue'] |
+ ..children = [ |
+ new SpanElement()..text = ' = ', |
+ anyRef(_isolate, f.value, _instances, |
+ queue: _r.queue) |
+ ] |
+ ]) |
+ .toList() |
] |
] |
]); |
@@ -409,37 +453,47 @@ class InstanceViewElement extends HtmlElement implements Renderable { |
if (_instance.elements != null && _instance.elements.isNotEmpty) { |
final elements = _instance.elements.toList(); |
int i = 0; |
- members.add(new DivElement()..classes = ['memberItem'] |
+ members.add(new DivElement() |
+ ..classes = ['memberItem'] |
..children = [ |
- new DivElement()..classes = ['memberName'] |
+ new DivElement() |
+ ..classes = ['memberName'] |
..text = 'elements (${_instance.length})', |
- new DivElement()..classes = ['memberValue'] |
+ new DivElement() |
+ ..classes = ['memberValue'] |
..children = [ |
new CurlyBlockElement( |
- expanded: elements.length <= 100, |
- queue: _r.queue) |
+ expanded: elements.length <= 100, queue: _r.queue) |
..content = [ |
- new DivElement()..classes = ['memberList'] |
- ..children = elements.map((element) => |
- new DivElement()..classes = ['memberItem'] |
- ..children = [ |
- new DivElement()..classes = ['memberName'] |
- ..text = '[ ${i++} ]', |
- new DivElement()..classes = ['memberValue'] |
- ..children = [ |
- anyRef(_isolate, element, _instances, |
- queue: _r.queue) |
- ] |
- ]).toList() |
+ new DivElement() |
+ ..classes = ['memberList'] |
+ ..children = elements |
+ .map((element) => new DivElement() |
+ ..classes = ['memberItem'] |
+ ..children = [ |
+ new DivElement() |
+ ..classes = ['memberName'] |
+ ..text = '[ ${i++} ]', |
+ new DivElement() |
+ ..classes = ['memberValue'] |
+ ..children = [ |
+ anyRef(_isolate, element, _instances, |
+ queue: _r.queue) |
+ ] |
+ ]) |
+ .toList() |
] |
] |
]); |
if (_instance.length != elements.length) { |
- members.add(new DivElement()..classes = ['memberItem'] |
+ members.add(new DivElement() |
+ ..classes = ['memberItem'] |
..children = [ |
- new DivElement()..classes = ['memberName'] |
+ new DivElement() |
+ ..classes = ['memberName'] |
..text = '...', |
- new DivElement()..classes = ['memberValue'] |
+ new DivElement() |
+ ..classes = ['memberValue'] |
..text = '${_instance.length - elements.length} omitted elements' |
]); |
} |
@@ -447,44 +501,54 @@ class InstanceViewElement extends HtmlElement implements Renderable { |
if (_instance.associations != null && _instance.associations.isNotEmpty) { |
final associations = _instance.associations.toList(); |
- members.add(new DivElement()..classes = ['memberItem'] |
+ members.add(new DivElement() |
+ ..classes = ['memberItem'] |
..children = [ |
- new DivElement()..classes = ['memberName'] |
+ new DivElement() |
+ ..classes = ['memberName'] |
..text = 'associations (${_instance.length})', |
- new DivElement()..classes = ['memberName'] |
+ new DivElement() |
+ ..classes = ['memberName'] |
..children = [ |
new CurlyBlockElement( |
- expanded: associations.length <= 100, |
- queue: _r.queue) |
+ expanded: associations.length <= 100, queue: _r.queue) |
..content = [ |
- new DivElement()..classes = ['memberList'] |
- ..children = associations.map((a) => |
- new DivElement()..classes = ['memberItem'] |
- ..children = [ |
- new DivElement()..classes = ['memberName'] |
- ..children = [ |
- new SpanElement()..text = '[ ', |
- anyRef(_isolate, a.key, _instances, |
- queue: _r.queue), |
- new SpanElement()..text = ' ]', |
- ], |
- new DivElement()..classes = ['memberValue'] |
- ..children = [ |
- anyRef(_isolate, a.value, _instances, |
- queue: _r.queue) |
- ] |
- ]).toList() |
+ new DivElement() |
+ ..classes = ['memberList'] |
+ ..children = associations |
+ .map((a) => new DivElement() |
+ ..classes = ['memberItem'] |
+ ..children = [ |
+ new DivElement() |
+ ..classes = ['memberName'] |
+ ..children = [ |
+ new SpanElement()..text = '[ ', |
+ anyRef(_isolate, a.key, _instances, |
+ queue: _r.queue), |
+ new SpanElement()..text = ' ]', |
+ ], |
+ new DivElement() |
+ ..classes = ['memberValue'] |
+ ..children = [ |
+ anyRef(_isolate, a.value, _instances, |
+ queue: _r.queue) |
+ ] |
+ ]) |
+ .toList() |
] |
] |
]); |
if (_instance.length != associations.length) { |
- members.add(new DivElement()..classes = ['memberItem'] |
+ members.add(new DivElement() |
+ ..classes = ['memberItem'] |
..children = [ |
- new DivElement()..classes = ['memberName'] |
+ new DivElement() |
+ ..classes = ['memberName'] |
..text = '...', |
- new DivElement()..classes = ['memberValue'] |
+ new DivElement() |
+ ..classes = ['memberValue'] |
..text = '${_instance.length - associations.length} ' |
- 'omitted elements' |
+ 'omitted elements' |
]); |
} |
} |
@@ -492,162 +556,210 @@ class InstanceViewElement extends HtmlElement implements Renderable { |
if (_instance.typedElements != null && _instance.typedElements.isNotEmpty) { |
final typedElements = _instance.typedElements.toList(); |
int i = 0; |
- members.add(new DivElement()..classes = ['memberItem'] |
+ members.add(new DivElement() |
+ ..classes = ['memberItem'] |
..children = [ |
- new DivElement()..classes = ['memberName'] |
+ new DivElement() |
+ ..classes = ['memberName'] |
..text = 'elements (${_instance.length})', |
- new DivElement()..classes = ['memberValue'] |
+ new DivElement() |
+ ..classes = ['memberValue'] |
..children = [ |
new CurlyBlockElement( |
- expanded: typedElements.length <= 100, |
- queue: _r.queue) |
+ expanded: typedElements.length <= 100, queue: _r.queue) |
..content = [ |
- new DivElement()..classes = ['memberList'] |
- ..children = typedElements.map((e) => |
- new DivElement()..classes = ['memberItem'] |
- ..children = [ |
- new DivElement()..classes = ['memberName'] |
- ..text = '[ ${i++} ]', |
- new DivElement()..classes = ['memberValue'] |
- ..text = '$e' |
- ]).toList() |
+ new DivElement() |
+ ..classes = ['memberList'] |
+ ..children = typedElements |
+ .map((e) => new DivElement() |
+ ..classes = ['memberItem'] |
+ ..children = [ |
+ new DivElement() |
+ ..classes = ['memberName'] |
+ ..text = '[ ${i++} ]', |
+ new DivElement() |
+ ..classes = ['memberValue'] |
+ ..text = '$e' |
+ ]) |
+ .toList() |
] |
] |
]); |
if (_instance.length != typedElements.length) { |
- members.add(new DivElement()..classes = ['memberItem'] |
+ members.add(new DivElement() |
+ ..classes = ['memberItem'] |
..children = [ |
- new DivElement()..classes = ['memberName'] |
+ new DivElement() |
+ ..classes = ['memberName'] |
..text = '...', |
- new DivElement()..classes = ['memberValue'] |
+ new DivElement() |
+ ..classes = ['memberValue'] |
..text = '${_instance.length - typedElements.length} ' |
- 'omitted elements' |
+ 'omitted elements' |
]); |
} |
} |
if (_instance.kind == M.InstanceKind.regExp) { |
members.addAll([ |
- new DivElement()..classes = ['memberItem'] |
+ new DivElement() |
+ ..classes = ['memberItem'] |
..children = [ |
- new DivElement()..classes = ['memberName'] |
+ new DivElement() |
+ ..classes = ['memberName'] |
..text = 'pattern', |
- new DivElement()..classes = ['memberValue'] |
+ new DivElement() |
+ ..classes = ['memberValue'] |
..children = [ |
anyRef(_isolate, _instance.pattern, _instances, queue: _r.queue) |
] |
], |
- new DivElement()..classes = ['memberItem'] |
+ new DivElement() |
+ ..classes = ['memberItem'] |
..children = [ |
- new DivElement()..classes = ['memberName'] |
+ new DivElement() |
+ ..classes = ['memberName'] |
..text = 'isCaseSensitive', |
- new DivElement()..classes = ['memberValue'] |
+ new DivElement() |
+ ..classes = ['memberValue'] |
..text = _instance.isCaseSensitive ? 'yes' : 'no' |
], |
- new DivElement()..classes = ['memberItem'] |
+ new DivElement() |
+ ..classes = ['memberItem'] |
..children = [ |
- new DivElement()..classes = ['memberName'] |
+ new DivElement() |
+ ..classes = ['memberName'] |
..text = 'isMultiLine', |
- new DivElement()..classes = ['memberValue'] |
+ new DivElement() |
+ ..classes = ['memberValue'] |
..text = _instance.isMultiLine ? 'yes' : 'no' |
], |
- new DivElement()..classes = ['memberItem'] |
+ new DivElement() |
+ ..classes = ['memberItem'] |
..children = [ |
- new DivElement()..classes = ['memberName'] |
+ new DivElement() |
+ ..classes = ['memberName'] |
..text = 'oneByteFunction', |
- new DivElement()..classes = ['memberValue'] |
+ new DivElement() |
+ ..classes = ['memberValue'] |
..children = [ |
new FunctionRefElement(_isolate, _instance.oneByteFunction, |
- queue: _r.queue) |
+ queue: _r.queue) |
] |
], |
- new DivElement()..classes = ['memberItem'] |
+ new DivElement() |
+ ..classes = ['memberItem'] |
..children = [ |
- new DivElement()..classes = ['memberName'] |
+ new DivElement() |
+ ..classes = ['memberName'] |
..text = 'twoByteFunction', |
- new DivElement()..classes = ['memberValue'] |
+ new DivElement() |
+ ..classes = ['memberValue'] |
..children = [ |
new FunctionRefElement(_isolate, _instance.twoByteFunction, |
- queue: _r.queue) |
+ queue: _r.queue) |
] |
], |
- new DivElement()..classes = ['memberItem'] |
+ new DivElement() |
+ ..classes = ['memberItem'] |
..children = [ |
- new DivElement()..classes = ['memberName'] |
+ new DivElement() |
+ ..classes = ['memberName'] |
..text = 'externalOneByteFunction', |
- new DivElement()..classes = ['memberValue'] |
+ new DivElement() |
+ ..classes = ['memberValue'] |
..children = [ |
- new FunctionRefElement(_isolate, |
- _instance.externalOneByteFunction, |
- queue: _r.queue) |
+ new FunctionRefElement( |
+ _isolate, _instance.externalOneByteFunction, |
+ queue: _r.queue) |
] |
], |
- new DivElement()..classes = ['memberItem'] |
+ new DivElement() |
+ ..classes = ['memberItem'] |
..children = [ |
- new DivElement()..classes = ['memberName'] |
+ new DivElement() |
+ ..classes = ['memberName'] |
..text = 'externalTwoByteFunction', |
- new DivElement()..classes = ['memberValue'] |
+ new DivElement() |
+ ..classes = ['memberValue'] |
..children = [ |
- new FunctionRefElement(_isolate, |
- _instance.externalTwoByteFunction, |
- queue: _r.queue) |
+ new FunctionRefElement( |
+ _isolate, _instance.externalTwoByteFunction, |
+ queue: _r.queue) |
] |
], |
- new DivElement()..classes = ['memberItem'] |
+ new DivElement() |
+ ..classes = ['memberItem'] |
..children = [ |
- new DivElement()..classes = ['memberName'] |
+ new DivElement() |
+ ..classes = ['memberName'] |
..text = 'oneByteBytecode', |
- new DivElement()..classes = ['memberValue'] |
+ new DivElement() |
+ ..classes = ['memberValue'] |
..children = [ |
- new InstanceRefElement(_isolate, _instance.oneByteBytecode, |
- _instances, queue: _r.queue) |
+ new InstanceRefElement( |
+ _isolate, _instance.oneByteBytecode, _instances, |
+ queue: _r.queue) |
] |
], |
- new DivElement()..classes = ['memberItem'] |
+ new DivElement() |
+ ..classes = ['memberItem'] |
..children = [ |
- new DivElement()..classes = ['memberName'] |
+ new DivElement() |
+ ..classes = ['memberName'] |
..text = 'twoByteBytecode', |
- new DivElement()..classes = ['memberValue'] |
+ new DivElement() |
+ ..classes = ['memberValue'] |
..children = [ |
- new InstanceRefElement(_isolate, _instance.twoByteBytecode, |
- _instances, queue: _r.queue) |
+ new InstanceRefElement( |
+ _isolate, _instance.twoByteBytecode, _instances, |
+ queue: _r.queue) |
] |
] |
]); |
} |
if (_instance.kind == M.InstanceKind.mirrorReference) { |
- members.add(new DivElement()..classes = ['memberItem'] |
+ members.add(new DivElement() |
+ ..classes = ['memberItem'] |
..children = [ |
- new DivElement()..classes = ['memberName'] |
+ new DivElement() |
+ ..classes = ['memberName'] |
..text = 'referent', |
- new DivElement()..classes = ['memberValue'] |
+ new DivElement() |
+ ..classes = ['memberValue'] |
..children = [ |
new ContextRefElement(_isolate, _instance.referent, |
- queue: _r.queue) |
+ queue: _r.queue) |
] |
]); |
} |
if (_instance.kind == M.InstanceKind.weakProperty) { |
members.addAll([ |
- new DivElement()..classes = ['memberItem'] |
+ new DivElement() |
+ ..classes = ['memberItem'] |
..children = [ |
- new DivElement()..classes = ['memberName'] |
+ new DivElement() |
+ ..classes = ['memberName'] |
..text = 'key', |
- new DivElement()..classes = ['memberValue'] |
+ new DivElement() |
+ ..classes = ['memberValue'] |
..children = [ |
new InstanceRefElement(_isolate, _instance.key, _instances, |
- queue: _r.queue), |
+ queue: _r.queue), |
] |
], |
- new DivElement()..classes = ['memberItem'] |
+ new DivElement() |
+ ..classes = ['memberItem'] |
..children = [ |
- new DivElement()..classes = ['memberName'] |
+ new DivElement() |
+ ..classes = ['memberName'] |
..text = 'value', |
- new DivElement()..classes = ['memberValue'] |
+ new DivElement() |
+ ..classes = ['memberValue'] |
..children = [ |
new InstanceRefElement(_isolate, _instance.value, _instances, |
- queue: _r.queue), |
+ queue: _r.queue), |
] |
] |
]); |
@@ -664,17 +776,17 @@ class InstanceViewElement extends HtmlElement implements Renderable { |
Future _loadExtraData() async { |
_library = (await _classes.get(_isolate, _instance.clazz.id)).library; |
if (_instance.typeArguments != null) { |
- _typeArguments = await _arguments.get(_isolate, |
- _instance.typeArguments.id); |
+ _typeArguments = |
+ await _arguments.get(_isolate, _instance.typeArguments.id); |
} else { |
_typeArguments = null; |
} |
if (_instance.closureFunction != null) { |
- _location = (await _functions.get(_isolate, |
- _instance.closureFunction.id)).location; |
+ _location = (await _functions.get(_isolate, _instance.closureFunction.id)) |
+ .location; |
} else if (_instance.typeClass != null) { |
- _location = (await _classes.get(_isolate, |
- _instance.typeClass.id)).location; |
+ _location = |
+ (await _classes.get(_isolate, _instance.typeClass.id)).location; |
} |
_r.dirty(); |
} |