I am here because they use the flexviewer-2.4 framework, their built-in config. xml Method for adding map layers. I used the method that cannot be successfully added. The built-in Loading Method of the Framework is.
1. Add one to the config. X and ML files:
<Layer label = "Place Name" type = "GoogleMap" style = "Address" visible = "false"/>
2. Add a new URL in the googlemaplayer. As file:
Else if (mapstyle = "Address") {// Road Map url = "http: // MT" + (COL % 4) + "bytes" + "x =" + Col + "&" + "Y =" + row + "&" + "z =" + level + "&" + "s = "+ S ;} // obtain the image map else if (mapstyle = "image") {// URL = "http: // MT" + (COL % 4) + ".google.cn/vt/lyrs%s@106&hl;zh-cn≷cn&src=app&" + "x =" + Col + "&" + "Y =" + row + "&" + "z =" + level + "&" + "s = "+ S ;}
After setting, you can add the path map to map. layers.
I add this layer by myself by using GoogleMap in mapmanager:
Private var poigooglemap: googlemaplayer; Private function googlemappoilayer (): void {poigooglemap = new googlemaplayer (); poigooglemap. name = "road"; poigooglemap. mapstyle = "Address"; poigooglemap. addeventlistener (layerevent. load_error, layer_loaderrorevent); poigooglemap. addeventlistener (layerevent. load, layer_loadevent); map. addlayer (poigooglemap );}
This is my method. Customize your own load. Do not use the default loading method.
The effect is the same as that in Google Maps.
Google's:
Custom: