Skip to content

Refactor interaction handlers to never unbind their event listeners #2891

@mcwhittemore

Description

@mcwhittemore

mapbox-gl-js version: 0.21.0

Steps to Trigger Behavior

https://jsbin.com/havivaruwe/edit?html,output

  1. map.doubleClickZoom.disable();
  2. on double click
    • map.fitBounds(...)
    • map.doubleClickZoom.enable();
  3. zoom back out
  4. on double click
    • map.fitBounds(...)

Expected Behavior

I expect the fit bounds call to bring me to the bounds

Actual Behavior

the double click zoom happens.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions