See "Technique to Avoid, #2" here: http://android-developers.blogspot.com/2009/04/future-proofing-your-apps.html
On Jun 22, 2:44 pm, Hastala <[email protected]> wrote: > So I can't make toggle app for GPS? > > On 5月30日, 上午10时00分, Jeff Sharkey <[email protected]> wrote: > > > Presumable the user has disabled them for good reason, and apps should > > not toggle them behind the users back. > > > You could show a dialog to the user, explaining that you'd > > likelocationenabled, and then launch into the Settings app using the > > "android.settings.LOCATION_SOURCE_SETTINGS" Intent. > > > j > > > On Fri, May 29, 2009 at 6:06 PM, Will <[email protected]> wrote: > > > > How do Ienable/disableGPSand Wifi providers? I check to see if they > > > are enabled by using this code: > > > > locationManager.isProviderEnabled("gps") > > > locationManager.isProviderEnabled("network") > > > > If both are false, I'd like to turnenabletheGPSproviderand/or the > > > Networkproviderso that the above checks would return true. Is this > > > possible? If so, what permissions does it require? > > > > I've searched the API and can't find any solutions. Thanks for any > > > help in advance. > > > -- > > Jeff Sharkey > > [email protected] > > --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---

