I'm developing an Android 2.2 app using an AR Kit (you can find it here).
This KIT is an eclipse project that has two classes that listenning to GPS RECEIVER.
These classes are ARLayout.java (a View) and HoldMeUp.java (Main Activity).
I've seen that ARLayout.java needs to update its data using GPS location, so it implements LocationListener.
HoldMeUp also needs to use GPS location, so it has a LocationListener.
I'm updating HoldMeUp to swith off GPS when app goes onPause. I can stop HoldMeUp LocationListener, but I can't stop ARLayour LocationListener.
I have some questions about it:
Q. Do above specified classes use GPS simultaneously? If yes then you should create an object of ARLayout class and define some public method like public void UpdateGPSState(GPS Paremeters) and call it from main activity's onLocationChangeListner or other Location Listner Functions.. Once there is an update in main activity your function call will automatically update ARLayout's GPS requirements.