Nfc Toggle in Android 4.x+?

我怕爱的太早我们不能终老 提交于 2019-12-23 04:37:04

问题


I know it is programmatically possible to disable NFC in Gingerbread, but has anyone managed to create a work around to accomplish the same for ICS and above?

I'm ok if it involves changing the source code of the OS also if someone has ventured into that :)


回答1:


Starting from Gingerbread 2.3.5 an app needs the special permission "android.permission.WRITE_SECURE_SETTINGS" to change the state of NFC. Normally, only apps signed by Google can have this permission, but I assume that if you root your device, you can probably circumvent that by adding your app to the system image or adding your signature key to some list that is stored somewhere. This answer also seems relevant: https://stackoverflow.com/a/3477237/1202968



来源:https://stackoverflow.com/questions/11292435/nfc-toggle-in-android-4-x

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!