public class mapcode extends Activity { globalvar appState; int stats=0; private MapView mapView; private IMapController mapController; private SimpleLocationOverlay mMyLocationOverlay; private ScaleBarOverlay mScaleBarOverlay; ItemizedIconOverlay<OverlayItem> currentLocationOverlay; DefaultResourceProxyImpl resourceProxy; protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); requestWindowFeature(Window.FEATURE_INDETERMINATE_PROGRESS); setContentView(R.layout.map); appState = ((globalvar) getApplicationContext()); mapView = (MapView) this.findViewById(R.id.mapview); mapView.setTileSource(TileSourceFactory.MAPNIK);
mapView.invalidate (); // for markers to appear}
source share