OpenLayers.Control.DragPan

The DragPan control pans the map with a drag of the mouse.

Inherits from

Summary
OpenLayers.Control.DragPanThe 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.
Functions
drawCreates a Drag handler, using panMap and panMapDone as callbacks.
panMap
panMapDoneFinish the panning operation.

Properties

type

{OpenLayers.Control.TYPES}

panned

{Boolean} The map moved.

interval

{Integer} The number of milliseconds that should ellapse before panning the map again.  Set this to increase dragging performance.  Defaults to 25 milliseconds.

Functions

draw

draw: function()

Creates a Drag handler, using panMap and panMapDone as callbacks.

panMap

panMap: function(xy)

Parameters

xy{OpenLayers.Pixel} Pixel of the mouse position

panMapDone

panMapDone: function(xy)

Finish the panning operation.  Only call setCenter (through panMap) if the map has actually been moved.

Parameters

xy{OpenLayers.Pixel} Pixel of the mouse position
draw: function()
Creates a Drag handler, using panMap and panMapDone as callbacks.
panMap: function(xy)
panMapDone: function(xy)
Finish the panning operation.
Controls affect the display or behavior of the map.
This class represents a screen coordinate, in x and y coordinates
Close