d3/d3

GeometryCollection is a *geometry*, not objecttype (c.f. http://www.g…

`…eojson.org/geojson-spec.html#geometry-objects). this makes nested test pass.`
1 parent 33bf327 commit 1aa504645b65549d26ef12be64b1ec209513a944 natevw committed Dec 28, 2012
Showing with 9 additions and 9 deletions.
1. +4 −4 d3.js
2. +1 −1 d3.min.js
3. +4 −4 src/geo/stream.js
8 d3.js
 @@ -5348,10 +5348,6 @@ FeatureCollection: function(object, listener) { var features = object.features, i = -1, n = features.length; while (++i < n) d3_geo_streamGeometry(features[i].geometry, listener); - }, - GeometryCollection: function(object, listener) { - var geometries = object.geometries, i = -1, n = geometries.length; - while (++i < n) d3_geo_streamGeometry(geometries[i], listener); } }; var d3_geo_streamGeometryType = { @@ -5379,6 +5375,10 @@ MultiPolygon: function(object, listener) { var coordinates = object.coordinates, i = -1, n = coordinates.length; while (++i < n) d3_geo_streamPolygon(coordinates[i], listener); + }, + GeometryCollection: function(object, listener) { + var geometries = object.geometries, i = -1, n = geometries.length; + while (++i < n) d3_geo_streamGeometry(geometries[i], listener); } }; function d3_geo_streamLine(coordinates, listener, closed) {
2 d3.min.js
1 addition, 1 deletion not shown because the diff is too large. Please use a local Git client to view these changes.
8 src/geo/stream.js
 @@ -19,10 +19,6 @@ var d3_geo_streamObjectType = { FeatureCollection: function(object, listener) { var features = object.features, i = -1, n = features.length; while (++i < n) d3_geo_streamGeometry(features[i].geometry, listener); - }, - GeometryCollection: function(object, listener) { - var geometries = object.geometries, i = -1, n = geometries.length; - while (++i < n) d3_geo_streamGeometry(geometries[i], listener); } }; @@ -51,6 +47,10 @@ var d3_geo_streamGeometryType = { MultiPolygon: function(object, listener) { var coordinates = object.coordinates, i = -1, n = coordinates.length; while (++i < n) d3_geo_streamPolygon(coordinates[i], listener); + }, + GeometryCollection: function(object, listener) { + var geometries = object.geometries, i = -1, n = geometries.length; + while (++i < n) d3_geo_streamGeometry(geometries[i], listener); } };