May be you will have to look at the below files and APIs.
frameworks/base/location/java/com/android/internal/location/
GpsLocationProvider.java
frameworks/base/core/jni/android_location_GpsLocationProvider.cpp
class MyGPSActivity extends MapActivity implements LocationListener {
...
/* This method is called when use position will get changed */
public void onLocationChanged(Location location) {
}
public void onProviderDisabled(String provider) {
}
public void onProviderEnabled(String provider) {
}
public void onStatusChanged(String provider, int status, Bundle
extras) {
}
protected boolean isRouteDisplayed() {
return false;
}
}
-
On Mar 2, 2:51 am, Burak Simsek <[email protected]> wrote:
> Hi I am trying to write a widget to show GPS Status. In case user
> change GPS enable status I want my widget to be updated.
>
> In other words: I want to update my widget when gps status has
> changed. Do I need to write a BroadcastReceiver? If yes what action
> will it receive?
>
> Thanks for your answers.
--
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en