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 final _allocationProfileRepository = new AllocationProfileRepository(); | 7 final _allocationProfileRepository = new AllocationProfileRepository(); |
8 final _breakpointRepository = new BreakpointRepository(); | 8 final _breakpointRepository = new BreakpointRepository(); |
9 final _classSampleProfileRepository = new ClassSampleProfileRepository(); | 9 final _classSampleProfileRepository = new ClassSampleProfileRepository(); |
10 final _classRepository = new ClassRepository(); | 10 final _classRepository = new ClassRepository(); |
(...skipping 758 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
769 }); | 769 }); |
770 } | 770 } |
771 | 771 |
772 bool canVisit(Uri uri) => uri.path == 'metrics'; | 772 bool canVisit(Uri uri) => uri.path == 'metrics'; |
773 } | 773 } |
774 | 774 |
775 class TimelinePage extends Page { | 775 class TimelinePage extends Page { |
776 TimelinePage(app) : super(app); | 776 TimelinePage(app) : super(app); |
777 | 777 |
778 void onInstall() { | 778 void onInstall() { |
779 if (element == null) { | 779 element = new TimelinePageElement(app.vm, app.events, app.notifications, |
780 element = new Element.tag('timeline-page'); | 780 queue: app.queue); |
781 } | |
782 assert(element != null); | |
783 } | 781 } |
784 | 782 |
785 void _visit(Uri uri) { | 783 void _visit(Uri uri) { |
786 assert(element != null); | |
787 assert(canVisit(uri)); | 784 assert(canVisit(uri)); |
788 } | 785 } |
789 | 786 |
790 bool canVisit(Uri uri) => uri.path == 'timeline'; | 787 bool canVisit(Uri uri) => uri.path == 'timeline'; |
791 } | 788 } |
OLD | NEW |