Closed GoogleCodeExporter closed 9 years ago
Sorry for the delay replying, only just noticed this. Have you seen this again
since? It's inside the Android core LocationManager library which of course
shouldn't happen.
Original comment by ken...@kentonprice.com
on 1 May 2013 at 8:12
it is happening on very rare occasions don't know possible rooted devices.
offtopic
have you received some reports that your lib is draining battery becouse of
gps is alive ? i had some htc jellybean device reports ...
i fixed that by adding fev lines that kill singleRequestUpdate in
LocationBroadcastService #134 after a while
locationManager.requestSingleUpdate(criteria, oneshotReceiver);
if (LocationLibrary.showDebugOutput)
Log.d(LocationLibraryConstants.TAG, TAG + ": schedule timer to kill
locationlistener");
new Timer().schedule(new TimerTask(){
public void run(){
try{
if (LocationLibrary.showDebugOutput)
Log.d(LocationLibraryConstants.TAG, TAG + ": remove updates after minute");
locationManager.removeUpdates(oneshotReceiver);
}catch(Exception e){
e.printStackTrace();
}
}
}, 60000);
Original comment by martins....@gmail.com
on 2 May 2013 at 6:58
Android 4.2.1 never stops asking for a one-shot update. This looks like a good
solution to it. I will include this in a future release. Probably within the
next month. Thanks for the tip!
Original comment by ken...@kentonprice.com
on 2 May 2013 at 12:33
I implemented your excellent "off-topic" suggestion in v15 :-)
Original comment by ken...@kentonprice.com
on 4 Jun 2013 at 12:39
Original issue reported on code.google.com by
martins....@gmail.com
on 14 Feb 2013 at 5:51