Code example for LocationClient

Methods: getLastLocation, isConnected

0
        setContentView(R.layout.map);
    } 
 
    public Location getLocation()
    { 
        if (mLocationClient != null && mLocationClient.isConnected())
            return mLocationClient.getLastLocation();
        return null; 
    } 
 
    private void draw() 
    { 
        mMap.clear();
        mMap.moveCamera(CameraUpdateFactory.newLatLngZoom(new LatLng(43.6044, 1.44194), 5.0f));
 
        Geocoder fwdGeocoder = new Geocoder(this, Locale.FRENCH);
        Livraison liv = Tournee.getInstance().getPileLivraison().peek();
        List<Address> adresses = null;
 
        try 
        {