OLD | NEW |
1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2013, 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 library service_object_view_element; | 5 library service_object_view_element; |
6 | 6 |
7 import 'dart:html'; | 7 import 'dart:html'; |
8 import 'package:logging/logging.dart'; | 8 import 'package:logging/logging.dart'; |
9 import 'package:observatory/service.dart'; | 9 import 'package:observatory/service.dart'; |
10 import 'package:observatory/elements.dart'; | 10 import 'package:observatory/elements.dart'; |
(...skipping 83 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
94 case 'HttpServerList': | 94 case 'HttpServerList': |
95 IOHttpServerListViewElement element = | 95 IOHttpServerListViewElement element = |
96 new Element.tag('io-http-server-list-view'); | 96 new Element.tag('io-http-server-list-view'); |
97 element.list = object; | 97 element.list = object; |
98 return element; | 98 return element; |
99 case 'HttpServer': | 99 case 'HttpServer': |
100 IOHttpServerViewElement element = | 100 IOHttpServerViewElement element = |
101 new Element.tag('io-http-server-view'); | 101 new Element.tag('io-http-server-view'); |
102 element.httpServer = object; | 102 element.httpServer = object; |
103 return element; | 103 return element; |
| 104 case 'Socket': |
| 105 IOSocketViewElement element = new Element.tag('io-socket-view'); |
| 106 element.socket = object; |
| 107 return element; |
104 case 'Isolate': | 108 case 'Isolate': |
105 IsolateViewElement element = new Element.tag('isolate-view'); | 109 IsolateViewElement element = new Element.tag('isolate-view'); |
106 element.isolate = object; | 110 element.isolate = object; |
107 return element; | 111 return element; |
108 case 'Library': | 112 case 'Library': |
109 LibraryViewElement element = new Element.tag('library-view'); | 113 LibraryViewElement element = new Element.tag('library-view'); |
110 element.library = object; | 114 element.library = object; |
111 return element; | 115 return element; |
112 case 'Profile': | 116 case 'Profile': |
113 IsolateProfileElement element = new Element.tag('isolate-profile'); | 117 IsolateProfileElement element = new Element.tag('isolate-profile'); |
(...skipping 48 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
162 var type = object.serviceType; | 166 var type = object.serviceType; |
163 var element = _constructElementForObject(); | 167 var element = _constructElementForObject(); |
164 if (element == null) { | 168 if (element == null) { |
165 Logger.root.info('Unable to find a view element for \'${type}\''); | 169 Logger.root.info('Unable to find a view element for \'${type}\''); |
166 return; | 170 return; |
167 } | 171 } |
168 children.add(element); | 172 children.add(element); |
169 Logger.root.info('Viewing object of \'${type}\''); | 173 Logger.root.info('Viewing object of \'${type}\''); |
170 } | 174 } |
171 } | 175 } |
OLD | NEW |