运行不起来,总是强制关闭。主要代码如下:
locationManager=(LocationManager)getSystemService(Context.LOCATION_SERVICE);
locationButton=(Button)findViewById(R.id.locationButtonId);
locationButton.setOnClickListener(new LocationButtonListener());
        //GeoPoint对象,通过经纬度指定地图上的点
        GeoPoint point=new GeoPoint((int)(latitude*1E6),(int)(longitude*1E6));
        MapView mapView=(MapView)findViewById(R.id.map_view);
        MapController mapControl=mapView.getController();
        mapView.displayZoomControls(true);
        mapControl.animateTo(point);
        mapControl.setZoom(7);
        
        //调用mapView对象的get方法,得到所有图层对象
        List<Overlay> mapOverlays=mapView.getOverlays();
        Drawable drawable=getResources().getDrawable(R.drawable.icon);
        FirstOverlay firstOverlay=new FirstOverlay(drawable,this);
        OverlayItem overlayItem=new OverlayItem(point,"Hello","I,m in xxx");
        firstOverlay.addOverlay(overlayItem);
        mapOverlays.add(firstOverlay);