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

Unified Diff: samples/swarm/swarm_ui_lib/layout/GridLayout.dart

Issue 11412086: Make 'where' lazy. (Closed) Base URL: https://dart.googlecode.com/svn/experimental/lib_v2/dart
Patch Set: Rebase 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 side-by-side diff with in-line comments
Download patch
Index: samples/swarm/swarm_ui_lib/layout/GridLayout.dart
diff --git a/samples/swarm/swarm_ui_lib/layout/GridLayout.dart b/samples/swarm/swarm_ui_lib/layout/GridLayout.dart
index 41ec8f38a989e81b61a84b56241dc25c10f6a496..084b328d3e7dbb7d9f1fe148a1949d864ff5a728 100644
--- a/samples/swarm/swarm_ui_lib/layout/GridLayout.dart
+++ b/samples/swarm/swarm_ui_lib/layout/GridLayout.dart
@@ -254,7 +254,7 @@ class GridLayout extends ViewLayout {
*/
num _calcNormalizedFractionBreadth(List<GridTrack> tracks) {
- final fractionTracks = tracks.where((t) => t.maxSizing.isFraction);
+ final fractionTracks = tracks.where((t) => t.maxSizing.isFraction).toList();
// Note: the spec has various bugs in this function, such as mismatched
// identifiers and names that aren't defined. For the most part it's
@@ -341,7 +341,7 @@ class GridLayout extends ViewLayout {
ContentSizeMode sizeMode, _BreadthAccumulator breadth) {
items = items.where((item) =>
- _hasContentSizedTracks(_getTracks(item), sizeMode, breadth));
+ _hasContentSizedTracks(_getTracks(item), sizeMode, breadth)).toList();
var tracks = [];

Powered by Google App Engine
This is Rietveld 408576698