问题描述
我通过很多的权限标记为 PROTECTION_NORMAL
和 PROTECTION_DANGEROUS
在的ListView 。当点击我的应用程序调用
ActivityCompat.requestPermission()
。
所有的权限,我测试了(我的意思是所有的正常
和危险
的)工作正常在我的模拟器,除了一些权限
-
CHANGE_NETWORK_STATE
请求 CHANGE_NETWORK_STATE
总是返回 PackageManager.PERMISSION_DENIED
(甚至没有提示)。 我希望它默认授予的权限,因为它的标记正常
,或者如果文件是错误的,要被提示为它呢。
-
GET_ACCOUNTS
请求 GET_ACCOUNTS
和提示后,但文档列出了该许可为正常
不是危险
(对话框询问访问您的联系人)。 我希望它默认授予的权限,因为它的标记正常
,而不是被提示输入了。
-
READ_CELL_BROADCASTS
时的上市从<$权限C $ C>短信权限组,但该权限不存在于 Manifest.permission
包。
是的,所有权限都在我的的AndroidManifest.xml 的。
问题
- 我是唯一一个有此?
- 在它是仿真器的具体情况?
- 是文档故障或为preVIEW建错了吗?
事实上,他们是。
原来,这些都是工作正在进行中,大多承认错误。
- https://开头code.google.com / P / Android的开发技术preVIEW /问题/详细信息?ID = 2993
- https://开头code.google.com / P / Android的开发技术preVIEW /问题/详细信息?ID = 3083
我贴的 GET_ACCOUNTS
一个新的bug,这是尚未报道。
大多是固定的最终发布/文档(又名不是preVIEW)。
I'm running through many permissions tagged PROTECTION_NORMAL
and PROTECTION_DANGEROUS
in a ListView
. Upon click my application calls ActivityCompat.requestPermission()
.
All permissions I tested (by that I mean all normal
and dangerous
permissions for API-7 and above I could find) are working fine on my Emulator, except for some:
CHANGE_NETWORK_STATE
Requesting CHANGE_NETWORK_STATE
always returns PackageManager.PERMISSION_DENIED
(without even prompting). I would expect it granted by default since it's flagged normal
, or if the documentation is wrong, to be prompted for it then.
GET_ACCOUNTS
Requesting GET_ACCOUNTS
works after prompting, but the documentation lists this permission as normal
not dangerous
(the dialog asks for "access your contacts"). I would expect it granted by default since it's flagged normal
and not to be prompted for it.
READ_CELL_BROADCASTS
Is listed as a permission from the SMS
permission group, but that permission does not exists in the Manifest.permission
package.
Yes, all permissions are in my AndroidManifest.xml.
Questions
- Am I the only one to have this?
- Is it emulator-specific?
- Is the documentation faulty or is the preview build wrong?
Indeed they are.
Turns out those are work-in-progress and mostly acknowledge bugs.
- https://code.google.com/p/android-developer-preview/issues/detail?id=2993
- https://code.google.com/p/android-developer-preview/issues/detail?id=3083
I posted a new bug for GET_ACCOUNTS
, that was yet to be reported.
Mostly to be fixed for final release / documentation (aka NOT preview).
这篇关于某些权限“的ProtectionLevel似乎错误地记录或实施的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!