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

Unified Diff: runtime/observatory/lib/src/app/page.dart

Issue 2312553002: Converted Observatory debugger elements (Closed)
Patch Set: Sharing command history and console 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « runtime/observatory/lib/elements.html ('k') | runtime/observatory/lib/src/cli/command.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/observatory/lib/src/app/page.dart
diff --git a/runtime/observatory/lib/src/app/page.dart b/runtime/observatory/lib/src/app/page.dart
index 87a7528935330e83835dc8f8e4bf6b01c237b191..cdcb45716cd7e0864d4bc9967c0fef54ed25b118 100644
--- a/runtime/observatory/lib/src/app/page.dart
+++ b/runtime/observatory/lib/src/app/page.dart
@@ -434,19 +434,33 @@ class ClassTreePage extends SimplePage {
}
}
-class DebuggerPage extends SimplePage {
- DebuggerPage(app) : super('debugger', 'debugger-page', app);
+class DebuggerPage extends MatchingPage {
+ DebuggerPage(app) : super('debugger', app);
+
+ final DivElement container = new DivElement();
void _visit(Uri uri) {
super._visit(uri);
- getIsolate(uri).then((isolate) {
- if (element != null) {
- /// Update the page.
- DebuggerPageElement page = element;
- page.isolate = isolate;
- }
+ getIsolate(uri).then((isolate) async {
+ container.children = [
+ new DebuggerPageElement(isolate, _instanceRepository,
+ _scriptRepository, app.events)
+ ];
});
}
+
+ void onInstall() {
+ if (element == null) {
+ element = container;
+ }
+ assert(element != null);
+ }
+
+ @override
+ void onUninstall() {
+ assert(element != null);
+ element.children = const [];
+ }
}
class ObjectStorePage extends MatchingPage {
« no previous file with comments | « runtime/observatory/lib/elements.html ('k') | runtime/observatory/lib/src/cli/command.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698