开发者

How to toggle GPS from an Android appwidget? [duplicate]

This question alread开发者_如何学编程y has answers here: Closed 11 years ago.

Possible Duplicate:

Enable GPS programatically like Tasker

I am making an app that shows gps icon as widget on home-screen. Now, i want to toggle GPS on or off when clicking this icon. I am stuck here. Any help?


You cannnot turn on/off GPS in android, see How can I enable or disable the GPS programmatically on Android? or Is there way to programmatically enable GPS on Android 2.1 & above?

Summary is that you have to use a security hole or that you have to be a system application (application has to come within the system image). For standard apps it is not possible.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜