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 781 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
792 }); | 792 }); |
793 } | 793 } |
794 | 794 |
795 bool canVisit(Uri uri) => uri.path == 'metrics'; | 795 bool canVisit(Uri uri) => uri.path == 'metrics'; |
796 } | 796 } |
797 | 797 |
798 class TimelinePage extends Page { | 798 class TimelinePage extends Page { |
799 TimelinePage(app) : super(app); | 799 TimelinePage(app) : super(app); |
800 | 800 |
801 void onInstall() { | 801 void onInstall() { |
802 if (element == null) { | 802 element = new TimelinePageElement(app.vm, app.events, app.notifications, |
803 element = new Element.tag('timeline-page'); | 803 queue: app.queue); |
804 } | |
805 assert(element != null); | |
806 } | 804 } |
807 | 805 |
808 void _visit(Uri uri) { | 806 void _visit(Uri uri) { |
809 assert(element != null); | |
810 assert(canVisit(uri)); | 807 assert(canVisit(uri)); |
811 } | 808 } |
812 | 809 |
813 bool canVisit(Uri uri) => uri.path == 'timeline'; | 810 bool canVisit(Uri uri) => uri.path == 'timeline'; |
814 } | 811 } |
OLD | NEW |