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

Side by Side Diff: utils/apidoc/mdn/extract.dart

Issue 11363252: Extend Iterable instead of implementing it. (Closed) Base URL: https://dart.googlecode.com/svn/experimental/lib_v2/dart
Patch Set: Address Stephen's comments. Created 8 years, 1 month 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 import 'dart:html'; 1 import 'dart:html';
2 import 'dart:json'; 2 import 'dart:json';
3 3
4 // Workaround for HTML lib missing feature. 4 // Workaround for HTML lib missing feature.
5 Range newRange() { 5 Range newRange() {
6 return document.createRange(); 6 return document.createRange();
7 } 7 }
8 8
9 // Temporary range object to optimize performance computing client rects 9 // Temporary range object to optimize performance computing client rects
10 // from text nodes. 10 // from text nodes.
(...skipping 457 matching lines...) Expand 10 before | Expand all | Expand 10 after
468 } 468 }
469 469
470 static Node _leftMostDescendent(Node n) { 470 static Node _leftMostDescendent(Node n) {
471 while (n.nodes.length > 0) { 471 while (n.nodes.length > 0) {
472 n = n.nodes.first; 472 n = n.nodes.first;
473 } 473 }
474 return n; 474 return n;
475 } 475 }
476 } 476 }
477 477
478 class PostOrderTraversal implements Iterable<Node> { 478 class PostOrderTraversal extends Iterable<Node> {
479 final Node _node; 479 final Node _node;
480 PostOrderTraversal(this._node); 480 PostOrderTraversal(this._node);
481 481
482 Iterator<Node> iterator() => new PostOrderTraversalIterator(_node); 482 Iterator<Node> iterator() => new PostOrderTraversalIterator(_node);
483 } 483 }
484 484
485 /** 485 /**
486 * Estimate what content represents the first line of text within the [section] 486 * Estimate what content represents the first line of text within the [section]
487 * range returning null if there isn't a plausible first line of text that 487 * range returning null if there isn't a plausible first line of text that
488 * contains the string [prop]. We measure the actual rendered client rectangle 488 * contains the string [prop]. We measure the actual rendered client rectangle
(...skipping 816 matching lines...) Expand 10 before | Expand all | Expand 10 after
1305 } 1305 }
1306 1306
1307 void documentLoaded(event) { 1307 void documentLoaded(event) {
1308 // Load the database of expected methods and properties with an HttpRequest. 1308 // Load the database of expected methods and properties with an HttpRequest.
1309 new HttpRequest.get('${window.location}.json', (req) { 1309 new HttpRequest.get('${window.location}.json', (req) {
1310 data = JSON.parse(req.responseText); 1310 data = JSON.parse(req.responseText);
1311 dbEntry = {'members': [], 'srcUrl': pageUrl}; 1311 dbEntry = {'members': [], 'srcUrl': pageUrl};
1312 run(); 1312 run();
1313 }); 1313 });
1314 } 1314 }
OLDNEW
« sdk/lib/utf/utf16.dart ('K') | « tests/compiler/dart2js_extra/for_in_test.dart ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698