Re: [android-developers] Re: GPS does not stop after ending my app

2011-03-21 Thread TreKing
On Mon, Mar 21, 2011 at 1:38 PM, Stephan Wiesner  wrote:

> Got it. I have to use
> MyLocationOverlay.disableMyLocation()
>

LOL - that you were using MyLocationOverlay would have been good to know. It
manages it's own listener, as you saw.

-
TreKing  - Chicago
transit tracking app for Android-powered devices

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

[android-developers] Re: GPS does not stop after ending my app

2011-03-21 Thread Stephan Wiesner
Got it. I have to use
MyLocationOverlay.disableMyLocation()

as well. Works fine now.

Thanks for your advice!
Stephan

On Mar 21, 4:49 pm, TreKing  wrote:
> On Mon, Mar 21, 2011 at 10:32 AM, Stephan Wiesner <
>
> testexpe...@googlemail.com> wrote:
> > only it does not stop the GPS :-(
>
> I would double check your code and make sure you're not adding an extra
> listener somewhere. Also wait a few seconds for the GPS icon to go away
> before assuming it's not working. Debug your code and make sure all your
> points are being hit as expected. Inspect the values for anything strange.
>
> --- 
> --
> TreKing  - Chicago
> transit tracking app for Android-powered devices

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


Re: [android-developers] Re: GPS does not stop after ending my app

2011-03-21 Thread TreKing
On Mon, Mar 21, 2011 at 10:32 AM, Stephan Wiesner <
testexpe...@googlemail.com> wrote:

> only it does not stop the GPS :-(


I would double check your code and make sure you're not adding an extra
listener somewhere. Also wait a few seconds for the GPS icon to go away
before assuming it's not working. Debug your code and make sure all your
points are being hit as expected. Inspect the values for anything strange.

-
TreKing  - Chicago
transit tracking app for Android-powered devices

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

[android-developers] Re: GPS does not stop after ending my app

2011-03-21 Thread Stephan Wiesner
only it does not stop the GPS :-(


On Mar 21, 3:03 pm, TreKing  wrote:
> On Mon, Mar 21, 2011 at 8:53 AM, Stephan Wiesner 
> > wrote:
> > so if I provide "this" on both methods it should work, should it not?
>
> Yes. I would pair onStart() with onStop() or onPause() with onResume().
>
> --- 
> --
> TreKing  - Chicago
> transit tracking app for Android-powered devices

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


Re: [android-developers] Re: GPS does not stop after ending my app

2011-03-21 Thread TreKing
On Mon, Mar 21, 2011 at 8:53 AM, Stephan Wiesner  wrote:

> so if I provide "this" on both methods it should work, should it not?


Yes. I would pair onStart() with onStop() or onPause() with onResume().

-
TreKing  - Chicago
transit tracking app for Android-powered devices

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

[android-developers] Re: GPS does not stop after ending my app

2011-03-21 Thread Stephan Wiesner
Hi TreKing,
thanks for your answer. I removed the new GeoUpdateHandler, but that
does not help.

My Activity extends LocationListener:
public class ShowMap extends MapActivity implements LocationListener

so if I provide "this" on both methods it should work, should it not?


@Override
protected void onStart() {
super.onStart();

locationManager.requestLocationUpdates(LocationManager.NETWORK_PROVIDER,
1000 * 60, 20,
this);
log("onstart");
}


@Override
protected void onPause() {
super.onPause();
locationManager.removeUpdates(this);
log("pause");
}

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en