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

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

Issue 2298563002: Removed const from classes arrays in Observatory (Closed)
Patch Set: Created 4 years, 3 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) 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 flag_list_element; 5 library flag_list_element;
6 6
7 import 'dart:html'; 7 import 'dart:html';
8 import 'dart:async'; 8 import 'dart:async';
9 import 'package:observatory/models.dart' as M; 9 import 'package:observatory/models.dart' as M;
10 import 'package:observatory/src/elements/helpers/rendering_scheduler.dart'; 10 import 'package:observatory/src/elements/helpers/rendering_scheduler.dart';
(...skipping 118 matching lines...) Expand 10 before | Expand all | Expand 10 after
129 _flags = flags; 129 _flags = flags;
130 _r.dirty(); 130 _r.dirty();
131 }); 131 });
132 } 132 }
133 133
134 static bool _isModified(M.Flag flag) => flag.modified; 134 static bool _isModified(M.Flag flag) => flag.modified;
135 static bool _isUnmodified(M.Flag flag) => !flag.modified; 135 static bool _isUnmodified(M.Flag flag) => !flag.modified;
136 136
137 static List<Element> _renderFlag(M.Flag flag) { 137 static List<Element> _renderFlag(M.Flag flag) {
138 return [ 138 return [
139 new SpanElement()..classes = const ['comment'] 139 new SpanElement()..classes = ['comment']
140 ..text = '// ${flag.comment}', 140 ..text = '// ${flag.comment}',
141 new DivElement()..classes = flag.modified ? const ['flag', 'modified'] 141 new DivElement()..classes = flag.modified ? ['flag', 'modified']
142 : const ['flag', 'unmodified'] 142 : ['flag', 'unmodified']
143 ..children = [ 143 ..children = [
144 new SpanElement()..classes = const ['name'] 144 new SpanElement()..classes = ['name']
145 ..text = flag.name, 145 ..text = flag.name,
146 new SpanElement()..text = '=', 146 new SpanElement()..text = '=',
147 new SpanElement()..classes = const ['value'] 147 new SpanElement()..classes = ['value']
148 ..text = flag.valueAsString ?? 'NULL' 148 ..text = flag.valueAsString ?? 'NULL'
149 ], 149 ],
150 new BRElement(), 150 new BRElement(),
151 ]; 151 ];
152 } 152 }
153 } 153 }
OLDNEW
« no previous file with comments | « runtime/observatory/lib/src/elements/field_view.dart ('k') | runtime/observatory/lib/src/elements/function_view.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698