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

Side by Side Diff: runtime/observatory/lib/src/elements/nav/top_menu.dart

Issue 2168463004: Converted Observatory isolate-nav-menu element (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Fixed long line Created 4 years, 5 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 unified diff | Download patch
OLDNEW
1 // Copyright (c) 2016, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2016, 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 import 'dart:html'; 5 import 'dart:html';
6 import 'dart:async'; 6 import 'dart:async';
7 import 'package:observatory/src/elements/helpers/rendering_scheduler.dart';
7 import 'package:observatory/src/elements/helpers/tag.dart'; 8 import 'package:observatory/src/elements/helpers/tag.dart';
8 import 'package:observatory/src/elements/helpers/rendering_scheduler.dart'; 9 import 'package:observatory/src/elements/helpers/uris.dart';
9 import 'package:observatory/src/elements/nav/menu.dart'; 10 import 'package:observatory/src/elements/nav/menu.dart';
10 import 'package:observatory/src/elements/nav/menu_item.dart'; 11 import 'package:observatory/src/elements/nav/menu_item.dart';
11 12
12 class NavTopMenuElement extends HtmlElement implements Renderable { 13 class NavTopMenuElement extends HtmlElement implements Renderable {
13 static const tag = const Tag<NavTopMenuElement>('nav-top-menu', 14 static const tag = const Tag<NavTopMenuElement>('nav-top-menu',
14 dependencies: const [NavMenuElement.tag, 15 dependencies: const [NavMenuElement.tag,
15 NavMenuItemElement.tag]); 16 NavMenuItemElement.tag]);
16 17
17 RenderingScheduler _r; 18 RenderingScheduler _r;
18 19
(...skipping 21 matching lines...) Expand all
40 41
41 @override 42 @override
42 void detached() { 43 void detached() {
43 super.detached(); 44 super.detached();
44 _r.disable(notify: true); 45 _r.disable(notify: true);
45 shadowRoot.children = []; 46 shadowRoot.children = [];
46 } 47 }
47 48
48 void render() { 49 void render() {
49 shadowRoot.children = [ 50 shadowRoot.children = [
50 new NavMenuElement('Observatory', link: '/vm', last: last, 51 new NavMenuElement('Observatory', link: Uris.vm(), last: last,
51 queue: _r.queue) 52 queue: _r.queue)
52 ..children = [ 53 ..children = [
53 new NavMenuItemElement('Connect to a VM', link: '/vm-connect', 54 new NavMenuItemElement('Connect to a VM', link: Uris.vmConnect(),
54 queue: _r.queue), 55 queue: _r.queue),
55 new ContentElement() 56 new ContentElement()
56 ] 57 ]
57 ]; 58 ];
58 } 59 }
59 } 60 }
OLDNEW
« no previous file with comments | « runtime/observatory/lib/src/elements/nav/menu_wrapper.dart ('k') | runtime/observatory/lib/src/elements/nav_bar.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698