Merge all changes from the naturaldocs sandbox. This brings all the work that

has been done in the NaturalDocs branch back to trunk. Thanks to everyone who
helped out in making this happen. (I could list people, but the list would
be long, and I'm already mentally on vacation.)


git-svn-id: http://svn.openlayers.org/trunk/openlayers@3545 dc9f47b5-9b13-0410-9fdd-eb0c1a62fdaf
This commit is contained in:
crschmidt
2007-06-29 15:59:20 +00:00
parent f1c61fd0d6
commit 3948913bfc
107 changed files with 8658 additions and 4011 deletions

View File

@@ -3,9 +3,12 @@
* for the full text of the license. */
/**
* @class
*
* @requires OpenLayers/Control.js
*
* Class: OpenLayers.Control.MouseDefaults
*
* Inherits from:
* - <OpenLayers.Control>
*/
OpenLayers.Control.MouseDefaults = OpenLayers.Class.create();
OpenLayers.Control.MouseDefaults.prototype =
@@ -15,21 +18,27 @@ OpenLayers.Control.MouseDefaults.prototype =
This class is DEPRECATED in 2.4 and will be removed by 3.0.
If you need this functionality, use Control.Navigation instead!!! */
/** @type Boolean */
/**
* Property: performedDrag
* {Boolean}
*/
performedDrag: false,
/** @type function */
/**
* Property: wheelObserver
* {Function}
*/
wheelObserver: null,
/**
* @constructor
* Constructor: OpenLayers.Control.MouseDefaults
*/
initialize: function() {
OpenLayers.Control.prototype.initialize.apply(this, arguments);
},
/**
*
* APIMethod: destroy
*/
destroy: function() {
@@ -58,7 +67,7 @@ OpenLayers.Control.MouseDefaults.prototype =
},
/**
*
* Method: draw
*/
draw: function() {
this.map.events.register( "click", this, this.defaultClick );
@@ -73,7 +82,7 @@ OpenLayers.Control.MouseDefaults.prototype =
},
/**
*
* Method: registerWheelEvents
*/
registerWheelEvents: function() {
@@ -86,9 +95,13 @@ OpenLayers.Control.MouseDefaults.prototype =
},
/**
* @param {Event} evt
* Method: defaultClick
*
* @type Boolean
* Parameters:
* evt - {Event}
*
* Returns:
* {Boolean}
*/
defaultClick: function (evt) {
if (!OpenLayers.Event.isLeftClick(evt)) return;
@@ -98,7 +111,10 @@ OpenLayers.Control.MouseDefaults.prototype =
},
/**
* @param {Event} evt
* Method: defaultDblClick
*
* Parameters:
* evt - {Event}
*/
defaultDblClick: function (evt) {
var newCenter = this.map.getLonLatFromViewPortPx( evt.xy );
@@ -108,7 +124,10 @@ OpenLayers.Control.MouseDefaults.prototype =
},
/**
* @param {Event} evt
* Method: defaultMouseDown
*
* Parameters:
* evt - {Event}
*/
defaultMouseDown: function (evt) {
if (!OpenLayers.Event.isLeftClick(evt)) return;
@@ -134,7 +153,10 @@ OpenLayers.Control.MouseDefaults.prototype =
},
/**
* @param {Event} evt
* Method: defaultMouseMove
*
* Parameters:
* evt - {Event}
*/
defaultMouseMove: function (evt) {
// record the mouse position, used in onWheelEvent
@@ -168,7 +190,10 @@ OpenLayers.Control.MouseDefaults.prototype =
},
/**
* @param {Event} evt
* Method: defaultMouseUp
*
* Parameters:
* evt - {<OpenLayers.Event>}
*/
defaultMouseUp: function (evt) {
if (!OpenLayers.Event.isLeftClick(evt)) return;
@@ -185,7 +210,10 @@ OpenLayers.Control.MouseDefaults.prototype =
},
/**
* @param {Event} evt
* Method: defaultMouseOut
*
* Parameters:
* evt - {Event}
*/
defaultMouseOut: function (evt) {
if (this.mouseDragStart != null &&
@@ -198,7 +226,9 @@ OpenLayers.Control.MouseDefaults.prototype =
},
/** User spun scroll wheel up
/**
* Method: defaultWheelUp
* User spun scroll wheel up
*
*/
defaultWheelUp: function(evt) {
@@ -208,8 +238,9 @@ OpenLayers.Control.MouseDefaults.prototype =
}
},
/** User spun scroll wheel down
*
/**
* Method: defaultWheelDown
* User spun scroll wheel down
*/
defaultWheelDown: function(evt) {
if (this.map.getZoom() > 0) {
@@ -218,8 +249,9 @@ OpenLayers.Control.MouseDefaults.prototype =
}
},
/** Zoombox function.
*
/**
* Method: zoomBoxEnd
* Zoombox function.
*/
zoomBoxEnd: function(evt) {
if (this.mouseDragStart != null) {
@@ -245,6 +277,7 @@ OpenLayers.Control.MouseDefaults.prototype =
},
/**
* Method: removeZoomBox
* Remove the zoombox from the screen and nullify our reference to it.
*/
removeZoomBox: function() {
@@ -258,9 +291,12 @@ OpenLayers.Control.MouseDefaults.prototype =
*/
/** Catch the wheel event and handle it xbrowserly
*
* @param {Event} e
/**
* Method: onWheelEvent
* Catch the wheel event and handle it xbrowserly
*
* Parameters:
* e - {Event}
*/
onWheelEvent: function(e){