be3fb5e3 by chiangbt

添加了OSM图层,GeoQ图层和高德图层

1 parent a03b6542
......@@ -29,6 +29,7 @@ dependencies {
compile 'com.github.arimorty:floatingsearchview:2.1.1'
compile 'com.amitshekhar.android:android-networking:0.2.0'
compile 'com.github.chyrta:AndroidOnboarder:0.6'
compile 'cn.carbs.android:MDDialog:1.0.0'
implementation fileTree(dir: 'libs', include: ['*.jar'])
//noinspection GradleCompatible
......
......@@ -11,13 +11,10 @@ import com.esri.android.map.LocationDisplayManager;
import com.esri.android.map.MapView;
import com.esri.android.runtime.ArcGISRuntime;
import com.esri.core.geometry.Point;
import com.pashanhoo.landsurvey.layers.Geoq.GeoQMapLayerTypes;
import com.pashanhoo.landsurvey.layers.Geoq.GeoQMapsTiledServiceLayer;
import com.pashanhoo.landsurvey.layers.gaode.GaodeMapLayerTypes;
import com.pashanhoo.landsurvey.layers.gaode.GaodeMapsTiledServiceLayer;
import com.pashanhoo.landsurvey.layers.geoq.GeoQMapLayerTypes;
import com.pashanhoo.landsurvey.layers.geoq.GeoQMapsTiledServiceLayer;
import com.pashanhoo.landsurvey.layers.google.GoogleMapLayerTypes;
import com.pashanhoo.landsurvey.layers.google.GoogleMapsTiledServiceLayer;
import com.pashanhoo.landsurvey.layers.tianditu.TDTTileinfo;
import com.pashanhoo.landsurvey.utils.AppInfo;
import com.pashanhoo.landsurvey.utils.GISHelper;
import com.pashanhoo.landsurvey.utils.JZLocationConverter;
......@@ -45,12 +42,14 @@ public class GoogleMapActivity extends AppCompatActivity {
// mapView.addLayer(GOOGLE_IMAGE_Layer);
// GoogleMapsTiledServiceLayer GOOGLE_ANNO_Layer = new GoogleMapsTiledServiceLayer(GoogleMapLayerTypes.IMAGE_ANNO_GOOGLE_MAP);
// mapView.addLayer(GOOGLE_ANNO_Layer);
GoogleMapsTiledServiceLayer OSM_Layer = new GoogleMapsTiledServiceLayer(GoogleMapLayerTypes.OSM_Map);
mapView.addLayer(OSM_Layer);
// GaodeMapsTiledServiceLayer gaodeMapsTiledServiceLayer = new GaodeMapsTiledServiceLayer(GaodeMapLayerTypes.VECTOR_Gaode_MAP);
// mapView.addLayer(gaodeMapsTiledServiceLayer);
GeoQMapsTiledServiceLayer geoQMapsTiledServiceLayer = new GeoQMapsTiledServiceLayer(GeoQMapLayerTypes.ChinaOnlineCommunity_Mobile);
mapView.addLayer(geoQMapsTiledServiceLayer);
// GeoQMapsTiledServiceLayer geoQMapsTiledServiceLayer = new GeoQMapsTiledServiceLayer(GeoQMapLayerTypes.ChinaOnlineCommunity_Mobile);
// mapView.addLayer(geoQMapsTiledServiceLayer);
mapView.setMaxResolution(156543.03392800014);
mapView.setMinResolution(0.29858214164761665);
......
package com.pashanhoo.landsurvey.layers.Geoq;
package com.pashanhoo.landsurvey.layers.geoq;
import com.pashanhoo.landsurvey.layers.BaseTiledMapServiceType;
......
package com.pashanhoo.landsurvey.layers.Geoq;
package com.pashanhoo.landsurvey.layers.geoq;
import android.annotation.SuppressLint;
import android.content.ContentValues;
......@@ -13,7 +13,6 @@ import com.esri.core.geometry.SpatialReference;
import com.esri.core.internal.io.handler.ResponseListener;
import com.esri.core.internal.io.handler.a;
import com.esri.core.io.UserCredentials;
import com.pashanhoo.landsurvey.layers.gaode.GaodeMapLayerTypes;
import com.pashanhoo.landsurvey.utils.AppInfo;
import com.pashanhoo.landsurvey.utils.GADBHelper;
......
......@@ -15,7 +15,9 @@ public enum GoogleMapLayerTypes implements BaseTiledMapServiceType {
/** * Google topographic map service ======= topographic map */
TERRAIN_GOOGLE_MAP,
/** * Google road POI map service = = = = net road map */
IMAGE_ANNO_GOOGLE_MAP;
IMAGE_ANNO_GOOGLE_MAP,
OSM_Map;
@Override
public String getName()
......
......@@ -147,6 +147,9 @@ public class GoogleMapsTiledServiceLayer extends TiledServiceLayer {
url = "http://mt" + (col % 4) + ".google.cn/vt/lyrs=s@131,h@209000000&hl=zh-CN&gl=CN&src=app&" + "x=" + col + "&" + "y=" + row + "&" + "z=" + level + "&" + "s=" + s;
// url = "http://webst02.is.autonavi.com/appmaptile?style=8&x=" + col + "&y=" + row + "&z=" + level;
break;
case OSM_Map:
url = "https://c.tile.openstreetmap.org/"+ level +"/"+ col +"/"+ row +".png";
break;
}
try {
......