Hi all,
> -MapPaneOL.prototype.getLayer = function(objRef,layerName) {
> - return objRef.model.map.getLayer(objRef.oLlayers[layerName].id);
> +MapPaneOL.prototype.getLayer = function(objRef,layerId) {
> + if(objRef.oLlayers[layerId] && objRef.oLlayers[layerId].id) {
> + return objRef.model.map.getLayer(objRef.oLlayers[layerId].id);
> + } else {
> + return false;
> + }
Just saw that this was also in the code before your changes. There
must be a thing I am missing, maybe you (or anyone else) can explain
where this .id thing comes from. To me it looks like getLayer cannot
work because of this.
> -MapPaneOL.prototype.moveLayerUp = function(objRef, layerName) {
> +MapPaneOL.prototype.moveLayerUp = function(objRef, layerId) {
> var map=objRef.model.map;
> - map.raiseLayer(objRef.oLlayers[layerName], 1);
> + map.raiseLayer(map.getLayer(objRef.oLlayers[layerId].id), 1);
Hm, here the .id is only in your code, not in the old one. And it is
not in moveLayerDown.
Regards,
Andreas.
-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2005.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
mapbuilder-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/mapbuilder-devel