Using java Syntax Highlighting
- List<GeoPoint> listaPuntos;
Parsed in 0.029 seconds, using GeSHi 1.0.8.4
and I'm having a LocationListener to get updates on my location by GPS. Each time there is a location update I want to add that location to my list by converting to a GeoPoint like this:
Using java Syntax Highlighting
- private class miLocListener implements LocationListener {
- public void onLocationChanged(Location arg) {
- lastLocation = arg;
- Double latitud = arg.getLatitude() * 1E6;
- Double longitud = arg.getLongitude() * 1E6;
- GeoPoint tmpPoint = new GeoPoint( latitud.intValue(), longitud.intValue() );
- listaPuntos.add(tmpPoint);
- }
- @Override
- public void onProviderDisabled(String arg0) {}
- @Override
- public void onProviderEnabled(String provider){}
- @Override
- public void onStatusChanged(String provider, int status, Bundle extras){}
- }
Parsed in 0.032 seconds, using GeSHi 1.0.8.4
But the application keeps crashing when adding the point to the list: listaPuntos.add(tmpPoint);
If I remove that line, everything works fine but I don't get the list!
Please Help!!


