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

Side by Side Diff: tools/dom/src/CssClassSet.dart

Issue 12295014: Remove deprecated Strings class. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 7 years, 10 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2012, 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 html; 5 part of html;
6 6
7 abstract class CssClassSet implements Set<String> { 7 abstract class CssClassSet implements Set<String> {
8 8
9 String toString() { 9 String toString() {
10 return Strings.join(new List.from(readClasses()), ' '); 10 return readClasses().join(' ');
11 } 11 }
12 12
13 /** 13 /**
14 * Adds the class [token] to the element if it is not on it, removes it if it 14 * Adds the class [token] to the element if it is not on it, removes it if it
15 * is. 15 * is.
16 */ 16 */
17 bool toggle(String value) { 17 bool toggle(String value) {
18 Set<String> s = readClasses(); 18 Set<String> s = readClasses();
19 bool result = false; 19 bool result = false;
20 if (s.contains(value)) { 20 if (s.contains(value)) {
(...skipping 140 matching lines...) Expand 10 before | Expand all | Expand 10 after
161 */ 161 */
162 Set<String> readClasses(); 162 Set<String> readClasses();
163 163
164 /** 164 /**
165 * Join all the elements of a set into one string and write 165 * Join all the elements of a set into one string and write
166 * back to the element. 166 * back to the element.
167 * This is intended to be overridden by specific implementations. 167 * This is intended to be overridden by specific implementations.
168 */ 168 */
169 void writeClasses(Set<String> s); 169 void writeClasses(Set<String> s);
170 } 170 }
OLDNEW
« no previous file with comments | « tools/dom/scripts/idlrenderer.dart ('k') | tools/dom/templates/html/impl/impl_SVGElement.darttemplate » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698