Merge pull request #294 from kapouer/patch-1
layer srs is inherited from map srs
This commit is contained in:
commit
2c9692b029
@ -22,7 +22,7 @@ tree.LayerXML = function(obj, styles) {
|
||||
' name="' + obj.name + '"\n' +
|
||||
prop_string +
|
||||
((typeof obj.status === 'undefined') ? '' : ' status="' + obj.status + '"\n') +
|
||||
' srs="' + obj.srs + '">\n ' +
|
||||
((typeof obj.srs === 'undefined') ? '' : ' srs="' + obj.srs + '"') + '>\n ' +
|
||||
styles.reverse().map(function(s) {
|
||||
return '<StyleName>' + s + '</StyleName>';
|
||||
}).join('\n ') +
|
||||
|
11
test/rendering/issue294.mml
Normal file
11
test/rendering/issue294.mml
Normal file
@ -0,0 +1,11 @@
|
||||
{
|
||||
"srs": "+proj=merc +a=6378137 +b=6378137 +lat_ts=0.0 +lon_0=0.0 +x_0=0.0 +y_0=0.0 +k=1.0 +units=m +nadgrids=@null +wktext +no_defs +over",
|
||||
"Stylesheet": [],
|
||||
"Layer": [{
|
||||
"name": "world",
|
||||
"Datasource": {
|
||||
"file": "http://tilemill-data.s3.amazonaws.com/test_data/shape_demo.zip",
|
||||
"type": "shape"
|
||||
}
|
||||
}]
|
||||
}
|
15
test/rendering/issue294.result
Normal file
15
test/rendering/issue294.result
Normal file
@ -0,0 +1,15 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<!DOCTYPE Map[]>
|
||||
<Map srs="+proj=merc +a=6378137 +b=6378137 +lat_ts=0.0 +lon_0=0.0 +x_0=0.0 +y_0=0.0 +k=1.0 +units=m +nadgrids=@null +wktext +no_defs +over" maximum-extent="-20037508.34,-20037508.34,20037508.34,20037508.34">
|
||||
|
||||
|
||||
<Layer name="world"
|
||||
>
|
||||
|
||||
<Datasource>
|
||||
<Parameter name="file"><![CDATA[[absolute path]]]></Parameter>
|
||||
<Parameter name="type"><![CDATA[shape]]></Parameter>
|
||||
</Datasource>
|
||||
</Layer>
|
||||
|
||||
</Map>
|
Loading…
Reference in New Issue
Block a user