update WFS to new clone()
git-svn-id: http://svn.openlayers.org/trunk/openlayers@957 dc9f47b5-9b13-0410-9fdd-eb0c1a62fdaf
This commit is contained in:
@@ -83,22 +83,28 @@ OpenLayers.Layer.WFS.prototype =
|
||||
},
|
||||
|
||||
/**
|
||||
* @param {String} name
|
||||
* @param {hash} params
|
||||
*
|
||||
* @returns A clone of this OpenLayers.Layer.WMS, with the passed-in
|
||||
* parameters merged in.
|
||||
* @type OpenLayers.Layer.WMS
|
||||
*/
|
||||
clone: function (name, params) {
|
||||
var mergedParams = {}
|
||||
Object.extend(mergedParams, this.params);
|
||||
Object.extend(mergedParams, params);
|
||||
var obj = new OpenLayers.Layer.WFS(name, this.url, mergedParams);
|
||||
if (this.tileSize)
|
||||
obj.setTileSize(this.tileSize);
|
||||
* @param {Object} obj
|
||||
*
|
||||
* @returns An exact clone of this OpenLayers.Layer.WMS
|
||||
* @type OpenLayers.Layer.WMS
|
||||
*/
|
||||
clone: function (obj) {
|
||||
|
||||
if (obj == null) {
|
||||
obj = new OpenLayers.Layer.WFS(this.name,
|
||||
this.url,
|
||||
this.params,
|
||||
this.options);
|
||||
}
|
||||
|
||||
//get all additions from superclasses
|
||||
obj = OpenLayers.Layer.Grid.prototype.clone.apply(this, [obj]);
|
||||
|
||||
// copy/set any non-init, non-simple values here
|
||||
|
||||
return obj;
|
||||
},
|
||||
},
|
||||
|
||||
|
||||
/**
|
||||
* addTile creates a tile, initializes it (via 'draw' in this case), and
|
||||
|
||||
Reference in New Issue
Block a user