| OLD | NEW |
| 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 $LIBRARYNAME; | 5 part of $LIBRARYNAME; |
| 6 | 6 |
| 7 class _ChildrenElementList extends ListBase<Element> { | 7 class _ChildrenElementList extends ListBase<Element> { |
| 8 // Raw Element. | 8 // Raw Element. |
| 9 final Element _element; | 9 final Element _element; |
| 10 final HtmlCollection _childElements; | 10 final HtmlCollection _childElements; |
| (...skipping 1359 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1370 */ | 1370 */ |
| 1371 void setInnerHtml(String html, | 1371 void setInnerHtml(String html, |
| 1372 {NodeValidator validator, NodeTreeSanitizer treeSanitizer}) { | 1372 {NodeValidator validator, NodeTreeSanitizer treeSanitizer}) { |
| 1373 text = null; | 1373 text = null; |
| 1374 append(createFragment( | 1374 append(createFragment( |
| 1375 html, validator: validator, treeSanitizer: treeSanitizer)); | 1375 html, validator: validator, treeSanitizer: treeSanitizer)); |
| 1376 } | 1376 } |
| 1377 String get innerHtml => _innerHtml; | 1377 String get innerHtml => _innerHtml; |
| 1378 | 1378 |
| 1379 /** | 1379 /** |
| 1380 * For use while transitioning to the safe [innerHtml] or [setInnerHtml]. | |
| 1381 * Unsafe because it opens the app to cross-site scripting vulnerabilities. | |
| 1382 */ | |
| 1383 @deprecated | |
| 1384 void set unsafeInnerHtml(String html) { | |
| 1385 _innerHtml = html; | |
| 1386 } | |
| 1387 | |
| 1388 /** | |
| 1389 * This is an ease-of-use accessor for event streams which should only be | 1380 * This is an ease-of-use accessor for event streams which should only be |
| 1390 * used when an explicit accessor is not available. | 1381 * used when an explicit accessor is not available. |
| 1391 */ | 1382 */ |
| 1392 ElementEvents get on => new ElementEvents(this); | 1383 ElementEvents get on => new ElementEvents(this); |
| 1393 | 1384 |
| 1394 $!MEMBERS | 1385 $!MEMBERS |
| 1395 } | 1386 } |
| 1396 | 1387 |
| 1397 | 1388 |
| 1398 class _ElementFactoryProvider { | 1389 class _ElementFactoryProvider { |
| (...skipping 30 matching lines...) Expand all Loading... |
| 1429 const ScrollAlignment._internal(this._value); | 1420 const ScrollAlignment._internal(this._value); |
| 1430 toString() => 'ScrollAlignment.$_value'; | 1421 toString() => 'ScrollAlignment.$_value'; |
| 1431 | 1422 |
| 1432 /// Attempt to align the element to the top of the scrollable area. | 1423 /// Attempt to align the element to the top of the scrollable area. |
| 1433 static const TOP = const ScrollAlignment._internal('TOP'); | 1424 static const TOP = const ScrollAlignment._internal('TOP'); |
| 1434 /// Attempt to center the element in the scrollable area. | 1425 /// Attempt to center the element in the scrollable area. |
| 1435 static const CENTER = const ScrollAlignment._internal('CENTER'); | 1426 static const CENTER = const ScrollAlignment._internal('CENTER'); |
| 1436 /// Attempt to align the element to the bottom of the scrollable area. | 1427 /// Attempt to align the element to the bottom of the scrollable area. |
| 1437 static const BOTTOM = const ScrollAlignment._internal('BOTTOM'); | 1428 static const BOTTOM = const ScrollAlignment._internal('BOTTOM'); |
| 1438 } | 1429 } |
| OLD | NEW |