OLD | NEW |
1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file |
2 // for details. All rights reserved. Use of this source code is governed by a | 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. | 3 // BSD-style license that can be found in the LICENSE file. |
4 | 4 |
5 part of app; | 5 part of app; |
6 | 6 |
7 class IsolateNotFound implements Exception { | 7 class IsolateNotFound implements Exception { |
8 String isolateId; | 8 String isolateId; |
9 IsolateNotFound(this.isolateId); | 9 IsolateNotFound(this.isolateId); |
10 String toString() => "IsolateNotFound: $isolateId"; | 10 String toString() => "IsolateNotFound: $isolateId"; |
(...skipping 354 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
365 bool canVisit(Uri uri) => uri.path == 'error'; | 365 bool canVisit(Uri uri) => uri.path == 'error'; |
366 } | 366 } |
367 | 367 |
368 class VMConnectPage extends Page { | 368 class VMConnectPage extends Page { |
369 VMConnectPage(app) : super(app); | 369 VMConnectPage(app) : super(app); |
370 | 370 |
371 void onInstall() { | 371 void onInstall() { |
372 if (element == null) { | 372 if (element == null) { |
373 element = new VMConnectElement( | 373 element = new VMConnectElement( |
374 ObservatoryApplication.app.targets, | 374 ObservatoryApplication.app.targets, |
375 new CrashDumpRepositoryMock( | 375 ObservatoryApplication.app.loadCrashDump, |
376 load: ObservatoryApplication.app.loadCrashDump), | |
377 ObservatoryApplication.app.notifications, | 376 ObservatoryApplication.app.notifications, |
378 queue: ObservatoryApplication.app.queue); | 377 queue: ObservatoryApplication.app.queue); |
379 } | 378 } |
380 assert(element != null); | 379 assert(element != null); |
381 } | 380 } |
382 | 381 |
383 void _visit(Uri uri) { | 382 void _visit(Uri uri) { |
384 assert(element != null); | 383 assert(element != null); |
385 assert(canVisit(uri)); | 384 assert(canVisit(uri)); |
386 } | 385 } |
(...skipping 89 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
476 assert(element != null); | 475 assert(element != null); |
477 } | 476 } |
478 | 477 |
479 void _visit(Uri uri) { | 478 void _visit(Uri uri) { |
480 assert(element != null); | 479 assert(element != null); |
481 assert(canVisit(uri)); | 480 assert(canVisit(uri)); |
482 } | 481 } |
483 | 482 |
484 bool canVisit(Uri uri) => uri.path == 'timeline'; | 483 bool canVisit(Uri uri) => uri.path == 'timeline'; |
485 } | 484 } |
OLD | NEW |