Merge pull request #871 from marcjansen/measure-api

Measure API enhancements
This commit is contained in:
Marc Jansen
2013-02-07 01:20:08 -08:00
+6 -4
View File
@@ -49,14 +49,14 @@ OpenLayers.Control.Measure = OpenLayers.Class(OpenLayers.Control, {
callbacks: null, callbacks: null,
/** /**
* Property: displaySystem * APIProperty: displaySystem
* {String} Display system for output measurements. Supported values * {String} Display system for output measurements. Supported values
* are 'english', 'metric', and 'geographic'. Default is 'metric'. * are 'english', 'metric', and 'geographic'. Default is 'metric'.
*/ */
displaySystem: 'metric', displaySystem: 'metric',
/** /**
* Property: geodesic * APIProperty: geodesic
* {Boolean} Calculate geodesic metrics instead of planar metrics. This * {Boolean} Calculate geodesic metrics instead of planar metrics. This
* requires that geometries can be transformed into Geographic/WGS84 * requires that geometries can be transformed into Geographic/WGS84
* (if that is not already the map projection). Default is false. * (if that is not already the map projection). Default is false.
@@ -226,8 +226,10 @@ OpenLayers.Control.Measure = OpenLayers.Class(OpenLayers.Control, {
* Method: measureImmediate * Method: measureImmediate
* Called each time the measurement sketch is modified. * Called each time the measurement sketch is modified.
* *
* Parameters: point - {<OpenLayers.Geometry.Point>} The point at the * Parameters:
* mouseposition. feature - {<OpenLayers.Feature.Vector>} The sketch feature. * point - {<OpenLayers.Geometry.Point>} The point at the mouse position.
* feature - {<OpenLayers.Feature.Vector>} The sketch feature.
* drawing - {Boolean} Indicates whether we're currently drawing.
*/ */
measureImmediate : function(point, feature, drawing) { measureImmediate : function(point, feature, drawing) {
if (drawing && !this.handler.freehandMode(this.handler.evt)) { if (drawing && !this.handler.freehandMode(this.handler.evt)) {