modify Grid to use HTTPRequest, update WMS & WFS with their necessary specifications -- capitalizing all parameters and adding SRS param from getProjection()

git-svn-id: http://svn.openlayers.org/trunk/openlayers@888 dc9f47b5-9b13-0410-9fdd-eb0c1a62fdaf
This commit is contained in:
euzuro
2006-07-06 01:28:48 +00:00
parent 5debdb69ec
commit b848e824d7
3 changed files with 71 additions and 59 deletions

View File

@@ -117,6 +117,38 @@ OpenLayers.Layer.WFS.prototype =
},
/**
* Catch changeParams and uppercase the new params to be merged in
* before calling changeParams on the super class.
*
* Once params have been changed, we will need to re-init our tiles
*
* @param {Object} params Hash of new params to use
*/
mergeNewParams:function(params) {
var upperParams = OpenLayers.Util.upperCaseObject(params);
var newArguments = [upperParams];
OpenLayers.Layer.Grid.prototype.mergeNewParams.apply(this, newArguments);
this._initTiles();
},
/** combine the layer's url with its params and these newParams.
*
* Add the SRS parameter from getProjection() -- this is probably
* more eloquently done via a setProjection() method, but this
* works for now and always.
*
* @param {Object} newParams
*
* @type String
*/
getFullRequestString:function(newParams) {
this.params.SRS = this.map.getProjection();
return OpenLayers.Layer.Grid.prototype.getFullRequestString.apply(
this, arguments);
},
/** @final @type String */
CLASS_NAME: "OpenLayers.Layer.WFS"
}