Permalink
Commits on Aug 3, 2010
  1. Latitude clamping now considers map angle.

    Mike Bostock committed Aug 3, 2010
  2. Improve stability of mousewheel interaction (again).

    Mike Bostock committed Aug 3, 2010
    The previous fix suffered from two problems.
    
    First, redundant hashchange events are occasionally dispatched by the browser,
    and later events would not be ignored; thus the hash control would end up moving
    the map on map move. We avoid this now by caching the location hash, and only
    moving the map when the hash changes. This also allows us to ignore the
    hashchange event when the map moves.
    
    Second, the wheel control was caching the location under the mouse, and only
    updating it when the mouse moves. However, the map can move independently of the
    mouse, for example with arrow controls or animation. Thus, we now clear the
    cached location when the map moves. (And, we're careful to preserve the cached
    location when we zoom the map.)
  3. Don't hardcode the number of Bing tile servers.

    Mike Bostock committed Aug 3, 2010
  4. Simplify overlay example using Layer.

    Mike Bostock committed Aug 3, 2010
    We implement the static image overlay using a custom (but simple!) layer
    implementation that creates an image tile.
  5. Improve stability of mousewheel interaction.

    Mike Bostock committed Aug 3, 2010
    Previously, the location under the mouse could drift as the mousewheel was used
    to zoom in and out. Now we compute the location under the mouse on mousemove, so
    that it does not drift when the map is zoomed. The location is specified as an
    optional third argument to `map.zoomBy`.
    
    The `map.panBy` method is reimplemented to be slightly faster and more accurate
    by avoiding an extra point <-> location conversion.
    
    Most importantly, the hash control now ignores the 'hashchange' event that it
    generates when it changes the hash. Previously, this was causing noticeable
    aliasing on smooth zoom as any movement of the map would be rounded to the
    precision of the hash control.
  6. Set cursor to "move" while dragging.

    Mike Bostock committed Aug 3, 2010
Commits on Aug 2, 2010
  1. Rotation!

    Mike Bostock committed Aug 2, 2010
    Maps can now be rotated using the `angle` property. For simplicity, the layer
    implementation currently computes the bounding box to fill the rotated viewport;
    in a future commit we will use a scanline fill algorithm to avoid loading tiles
    outside the viewport.
    
    This commit also fixes a bug in the `coordinatePoint` and `pointCoordinate`
    methods, which were treating points pre-fractional zoom. Now points are always
    considered to be in screen space (pixel coordinates), consistent with the
    `locationPoint` and `pointLocation` methods. Note, however, that the
    tile-specific projection used by layers is still pre-transform.
Commits on Jul 28, 2010
  1. New layer `visible` property.

    Mike Bostock committed Jul 28, 2010
    A layer's visibility can now be toggled without adding or removing the layer
    from the map. This avoids inadvertantly changing the z-order of layers. In
    addition to removing the tiles from the SVG image, the layer container's
    visibility attribute is set to "hidden", such that if the user has extended the
    layer with additional elements, they become hidden as well.
Commits on Jul 27, 2010
  1. Refine the tile scale & rounding logic.

    Mike Bostock committed Jul 27, 2010
    We now apply the scale transform to the layer group elements, rather than to
    each tile individually. In addition, rather than rounding each tile's position,
    we round the tileCenter coordinate.
  2. Fix zoom transforms with non-tiled layers.

    Mike Bostock committed Jul 27, 2010
    Previously, if a zoom transform was used with a non-tiled layer, it could cause
    no tiles to be displayed. Now we guarantee that at least one (world-size) tile
    is visible.
  3. Improve performance of re-adding a layer.

    Mike Bostock committed Jul 27, 2010
    Previously, when re-adding a layer to its map, the layer would be removed from
    the map only to be immediately added back. This prevents the browser from
    efficiently updating the display. Now we do the minimal amount of work, while
    still guaranteeing that layers appear in the order they were added.
  4. Fix a bug in event dispatch.

    Mike Bostock committed Jul 27, 2010
    If an event listener is removed during an event dispatch, it shouldn't receive
    the active event. So now in addition to storing a defensive copy, we use a
    wrapper object for the event handler to store an `on` boolean. This is set to
    false when the listener is removed, preventing that handler from receiving the current event.
  5. Make a defensive copy of registered listeners.

    Mike Bostock committed Jul 27, 2010
    This way, if a listener is removed while events are being dispatched, we won't
    inadvertantly skip a listener.
  6. Cache reference to map.

    Mike Bostock committed Jul 27, 2010
    This way, if the layer is removed from the map by the time loaded tiles arrive,
    the map is still available for the purposes of projection.
  7. Add comment to point-coordinate methods.

    Mike Bostock committed Jul 27, 2010
  8. Fix a spurious key repeat in arrow control.

    Mike Bostock committed Jul 23, 2010
Commits on Jul 25, 2010
  1. Added Stamen to copyright

    Michal Migurski committed Jul 25, 2010
  2. Fixing the "logo" :)

    RandomEtc committed Jul 25, 2010
Commits on Jul 23, 2010
  1. Listen for hashchange events.

    Mike Bostock committed Jul 23, 2010
    Now, when the location.hash changes, the map center and zoom will change
    accordingly. This is particularly nice for pasting in a URL that only differs by
    hash. Also, the hash control now ignores the hash if any part of it isNaN, or if
    it contains fewer than three components.
Commits on Jul 18, 2010
  1. Switch CloudMade API key.

    Mike Bostock committed Jul 18, 2010
    Please get your own API key at http://cloudmade.com/register!
  2. Load State & County GeoJSON tiles from Google App Engine.

    Mike Bostock committed Jul 18, 2010
  3. Ignore empty GeoJSON features.

    Mike Bostock committed Jul 18, 2010
  4. Close Polygons, not MultiPolygons.

    Mike Bostock committed Jul 18, 2010
  5. Don't callback for empty responses.

    Mike Bostock committed Jul 18, 2010
    JSON.parse("") fails.
Commits on Jul 17, 2010
  1. Add lib/google-compiler.

    Mike Bostock committed Jul 17, 2010
  2. Make Markdown happy.

    Mike Bostock committed Jul 17, 2010
  3. Polymaps v1.0.0.

    Mike Bostock committed Jul 17, 2010
Commits on Jul 16, 2010
  1. Initial commit.

    joestump committed Jul 16, 2010