The DragPan control pans the map with a drag of the mouse.
| OpenLayers. | The DragPan control pans the map with a drag of the mouse. |
| Properties | |
| type | {OpenLayers.Control.TYPES} |
| panned | {Boolean} The map moved. |
| interval | {Integer} The number of milliseconds that should ellapse before panning the map again. |
| documentDrag | {Boolean} If set to true, mouse dragging will continue even if the mouse cursor leaves the map viewport. |
| kinetic | {OpenLayers.Kinetic} The OpenLayers.Kinetic object. |
| enableKinetic | {Boolean} Set this option to enable “kinetic dragging”. |
| kineticInterval | {Integer} Interval in milliseconds between 2 steps in the “kinetic scrolling”. |
| Functions | |
| draw | Creates a Drag handler, using panMap and panMapDone as callbacks. |
| panMapStart | |
| panMap | |
| panMapDone | Finish the panning operation. |
{Boolean} Set this option to enable “kinetic dragging”. Can be set to true or to an object. If set to an object this object will be passed to the {OpenLayers.Kinetic} constructor. Defaults to false.
draw: function()
Creates a Drag handler, using panMap and panMapDone as callbacks.
panMapDone: function( xy )
Finish the panning operation. Only call setCenter (through panMap) if the map has actually been moved.
| xy | {OpenLayers.Pixel} Pixel of the mouse position |
Creates a Drag handler, using panMap and panMapDone as callbacks.
draw: function()
panMap: function( xy )
Finish the panning operation.
panMapDone: function( xy )
panMapStart: function()