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

Unified Diff: runtime/observatory/lib/src/elements/isolate/shared_summary.dart

Issue 2286823002: Fixed isolate-shared-summary layout problems (Closed)
Patch Set: Created 4 years, 4 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/observatory/lib/src/elements/isolate/shared_summary.dart
diff --git a/runtime/observatory/lib/src/elements/isolate/shared_summary.dart b/runtime/observatory/lib/src/elements/isolate/shared_summary.dart
index 51fdc286343c696df984b9d97fb89d5a05dbc7a2..91bc2bb5734871920f4ca0cbc32a46cf16d79b8f 100644
--- a/runtime/observatory/lib/src/elements/isolate/shared_summary.dart
+++ b/runtime/observatory/lib/src/elements/isolate/shared_summary.dart
@@ -50,18 +50,11 @@ class IsolateSharedSummaryElement extends HtmlElement implements Renderable {
}
void render() {
- children = [];
- if (_isolate.error != null) {
- children = [
- new PreElement()..classes = const ["errorBox"]
- ..text = _isolate.error.message
- ];
- }
final newHeapUsed = Utils.formatSize(_isolate.newSpace.used);
final newHeapCapacity = Utils.formatSize(_isolate.newSpace.capacity);
final oldHeapUsed = Utils.formatSize(_isolate.oldSpace.used);
final oldHeapCapacity = Utils.formatSize(_isolate.oldSpace.capacity);
- children.addAll([
+ final content = [
new DivElement()..classes = ['menu']
..children = [
new DivElement()..classes = const ['memberList']
@@ -150,6 +143,19 @@ class IsolateSharedSummaryElement extends HtmlElement implements Renderable {
]
],
new IsolateCounterChartElement(_isolate.counters, queue: _r.queue)
- ]);
+ ];
+ if (_isolate.error != null) {
+ children = [
+ new PreElement()..classes = const ['errorBox']
+ ..text = _isolate.error.message,
+ new DivElement()..classes = const ['summary']
+ ..children = content
+ ];
+ } else {
+ children = [
+ new DivElement()..classes = const ['summary']
+ ..children = content
+ ];
+ }
}
}

Powered by Google App Engine
This is Rietveld 408576698