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

Side by Side Diff: tools/dom/templates/html/impl/impl_Element.darttemplate

Issue 300143002: Change Element offset/client/scroll attributes to be num instead of int (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 6 years, 7 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
« no previous file with comments | « tools/dom/scripts/htmlrenamer.py ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 $LIBRARYNAME; 5 part of $LIBRARYNAME;
6 6
7 class _ChildrenElementList extends ListBase<Element> 7 class _ChildrenElementList extends ListBase<Element>
8 implements NodeListWrapper { 8 implements NodeListWrapper {
9 // Raw Element. 9 // Raw Element.
10 final Element _element; 10 final Element _element;
(...skipping 1307 matching lines...) Expand 10 before | Expand all | Expand 10 after
1318 html, validator: validator, treeSanitizer: treeSanitizer)); 1318 html, validator: validator, treeSanitizer: treeSanitizer));
1319 } 1319 }
1320 String get innerHtml => _innerHtml; 1320 String get innerHtml => _innerHtml;
1321 1321
1322 /** 1322 /**
1323 * This is an ease-of-use accessor for event streams which should only be 1323 * This is an ease-of-use accessor for event streams which should only be
1324 * used when an explicit accessor is not available. 1324 * used when an explicit accessor is not available.
1325 */ 1325 */
1326 ElementEvents get on => new ElementEvents(this); 1326 ElementEvents get on => new ElementEvents(this);
1327 1327
1328 $if DART2JS
blois 2014/05/27 15:21:14 Can this not use the private field accessors?
1329 @DomName('Element.offsetHeight')
1330 @DocsEditable()
1331 final num offsetHeight;
1332
1333 @DomName('Element.offsetLeft')
1334 @DocsEditable()
1335 final num offsetLeft;
1336
1337 @DomName('Element.offsetTop')
1338 @DocsEditable()
1339 final num offsetTop;
1340
1341 @DomName('Element.offsetWidth')
1342 @DocsEditable()
1343 final num offsetWidth;
1344
1345 @DomName('Element.clientHeight')
1346 @DocsEditable()
1347 final num clientHeight;
1348
1349 @DomName('Element.clientLeft')
1350 @DocsEditable()
1351 final num clientLeft;
1352
1353 @DomName('Element.clientTop')
1354 @DocsEditable()
1355 final num clientTop;
1356
1357 @DomName('Element.clientWidth')
1358 @DocsEditable()
1359 final num clientWidth;
1360
1361 @DomName('Element.scrollHeight')
1362 @DocsEditable()
1363 final num scrollHeight;
1364
1365 @DomName('Element.scrollLeft')
1366 @DocsEditable()
1367 num scrollLeft;
1368
1369 @DomName('Element.scrollTop')
1370 @DocsEditable()
1371 num scrollTop;
1372
1373 @DomName('Element.scrollWidth')
1374 @DocsEditable()
1375 final num scrollWidth;
1376
1377 $else
1378 @DomName('Element.offsetHeight')
1379 @DocsEditable()
1380 num get offsetHeight => Native_Element_offsetHeight_Getter(this);
1381
1382 @DomName('Element.offsetLeft')
1383 @DocsEditable()
1384 num get offsetLeft => Native_Element_offsetLeft_Getter(this);
1385
1386 @DomName('Element.offsetTop')
1387 @DocsEditable()
1388 num get offsetTop => Native_Element_offsetTop_Getter(this);
1389
1390 @DomName('Element.offsetWidth')
1391 @DocsEditable()
1392 num get offsetWidth => Native_Element_offsetWidth_Getter(this);
1393
1394 @DomName('Element.clientHeight')
1395 @DocsEditable()
1396 num get clientHeight => Native_Element_clientHeight_Getter(this);
1397
1398 @DomName('Element.clientLeft')
1399 @DocsEditable()
1400 num get clientLeft => Native_Element_clientLeft_Getter(this);
1401
1402 @DomName('Element.clientTop')
1403 @DocsEditable()
1404 num get clientTop => Native_Element_clientTop_Getter(this);
1405
1406 @DomName('Element.clientWidth')
1407 @DocsEditable()
1408 num get clientWidth => Native_Element_clientWidth_Getter(this);
1409
1410 @DomName('Element.scrollHeight')
1411 @DocsEditable()
1412 num get scrollHeight => Native_Element_scrollHeight_Getter(this);
1413
1414 @DomName('Element.scrollLeft')
1415 @DocsEditable()
1416 num get scrollLeft => Native_Element_scrollLeft_Getter(this);
1417
1418 @DomName('Element.scrollLeft')
1419 @DocsEditable()
1420 void set scrollLeft(num value) => Native_Element_scrollLeft_Setter(this, value );
1421
1422 @DomName('Element.scrollTop')
1423 @DocsEditable()
1424 num get scrollTop => Native_Element_scrollTop_Getter(this);
1425
1426 @DomName('Element.scrollTop')
1427 @DocsEditable()
1428 void set scrollTop(num value) => Native_Element_scrollTop_Setter(this, value);
1429
1430 @DomName('Element.scrollWidth')
1431 @DocsEditable()
1432 num get scrollWidth => Native_Element_scrollWidth_Getter(this);
1433 $endif
1434
1328 $!MEMBERS 1435 $!MEMBERS
1329 } 1436 }
1330 1437
1331 1438
1332 class _ElementFactoryProvider { 1439 class _ElementFactoryProvider {
1333 1440
1334 @DomName('Document.createElement') 1441 @DomName('Document.createElement')
1335 $if DART2JS 1442 $if DART2JS
1336 // Optimization to improve performance until the dart2js compiler inlines this 1443 // Optimization to improve performance until the dart2js compiler inlines this
1337 // method. 1444 // method.
(...skipping 25 matching lines...) Expand all
1363 const ScrollAlignment._internal(this._value); 1470 const ScrollAlignment._internal(this._value);
1364 toString() => 'ScrollAlignment.$_value'; 1471 toString() => 'ScrollAlignment.$_value';
1365 1472
1366 /// Attempt to align the element to the top of the scrollable area. 1473 /// Attempt to align the element to the top of the scrollable area.
1367 static const TOP = const ScrollAlignment._internal('TOP'); 1474 static const TOP = const ScrollAlignment._internal('TOP');
1368 /// Attempt to center the element in the scrollable area. 1475 /// Attempt to center the element in the scrollable area.
1369 static const CENTER = const ScrollAlignment._internal('CENTER'); 1476 static const CENTER = const ScrollAlignment._internal('CENTER');
1370 /// Attempt to align the element to the bottom of the scrollable area. 1477 /// Attempt to align the element to the bottom of the scrollable area.
1371 static const BOTTOM = const ScrollAlignment._internal('BOTTOM'); 1478 static const BOTTOM = const ScrollAlignment._internal('BOTTOM');
1372 } 1479 }
OLDNEW
« no previous file with comments | « tools/dom/scripts/htmlrenamer.py ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698