Fix for "WFS.setOpacity() doen't work properly". (Closes #1868) r=elemoine

git-svn-id: http://svn.openlayers.org/trunk/openlayers@8952 dc9f47b5-9b13-0410-9fdd-eb0c1a62fdaf
This commit is contained in:
crschmidt
2009-03-06 13:14:34 +00:00
parent 9b6894644b
commit d2656e002a
2 changed files with 32 additions and 0 deletions

View File

@@ -551,6 +551,22 @@ OpenLayers.Layer.WFS = OpenLayers.Class(
return extent;
},
/**
* APIMethod: setOpacity
* Call the setOpacity method of the appropriate parent class to set the
* opacity.
*
* Parameter:
* opacity - {Float}
*/
setOpacity: function (opacity) {
if (this.vectorMode) {
OpenLayers.Layer.Vector.prototype.setOpacity.apply(this, [opacity]);
} else {
OpenLayers.Layer.Markers.prototype.setOpacity.apply(this, [opacity]);
}
},
CLASS_NAME: "OpenLayers.Layer.WFS"
});