[fusion-trac] #367: MapMenu: warning message is pop-up when reloading the MapGroup with commercial layers.

Fusion trac_fusion at osgeo.org
Tue Mar 9 00:04:42 EST 2010


#367: MapMenu: warning message is pop-up when reloading the MapGroup with
commercial layers.
---------------------+------------------------------------------------------
 Reporter:  liuar    |         Owner:  madair    
     Type:  defect   |        Status:  new       
 Priority:  P2       |     Milestone:  2.0       
Component:  Widgets  |       Version:  2.0 - beta
 Severity:  Major    |    Resolution:            
 Keywords:           |   External_id:  1272713   
    State:  New      |       Browser:  All       
       Os:  All      |  
---------------------+------------------------------------------------------
Comment (by liuar):

 [Analysis][[BR]]
 In MapMenu.js[[BR]]
 [[BR]]
 var dest = new OpenLayers.Projection(data.maps[0].projCode); [[BR]]
 ce = ce.transform(this.oMap.oMapOL.baseLayer.projection, dest); [[BR]]
 [[BR]]
 but the layer's projCode implementation in openlayers.js used in Fusion
 makes the projCode always be EPSG:4326. so the transformation might be
 invalid, and the calculated extent might not make any sense.

 [Workaround]
 {{{
         if(data.maps[0].layerOptions.projection)
         {
             var dest = new
 OpenLayers.Projection(data.maps[0].layerOptions.projection);
             ce = ce.transform(this.oMap.oMapOL.baseLayer.projection,dest);
         }
 }}}[[BR]]

 we will transform the coordinate system only if the layer contians the
 projection info. Fo the other layers, just keep the original behavior.

-- 
Ticket URL: <http://trac.osgeo.org/fusion/ticket/367#comment:1>
Fusion <http://trac.osgeo.org/fusion>
Fusion is a web-mapping application development framework for MapServer and MapGuide OS.


More information about the fusion-trac mailing list