allow user to set the slide factor in keyboarddefauls
git-svn-id: http://svn.openlayers.org/trunk/openlayers@646 dc9f47b5-9b13-0410-9fdd-eb0c1a62fdaf
This commit is contained in:
@@ -7,6 +7,9 @@ OpenLayers.Control.KeyboardDefaults = Class.create();
|
||||
OpenLayers.Control.KeyboardDefaults.prototype =
|
||||
Object.extend( new OpenLayers.Control(), {
|
||||
|
||||
/** @type int */
|
||||
slideFactor: 50,
|
||||
|
||||
/**
|
||||
* @constructor
|
||||
*/
|
||||
@@ -28,7 +31,7 @@ OpenLayers.Control.KeyboardDefaults.prototype =
|
||||
*/
|
||||
defaultKeyDown: function (evt) {
|
||||
|
||||
var slide = this.getResolution() * 50;
|
||||
var slide = this.getResolution() * this.slideFactor;
|
||||
var center = this.getCenter();
|
||||
|
||||
var newCenter = center.copyOf();
|
||||
|
||||
Reference in New Issue
Block a user