Android-请求小米的许可

发布于 2025-01-27 11:36:12 字数 293 浏览 4 评论 0原文

在编程中请求访问权限的适当方法是什么?

以下所有其他设备上的代码段将带您进入屏幕,并具有可访问性的选项。但是在小米设备上,它将使用以下选项到屏幕:“卷快捷方式”,“可访问性菜单”和“下载服务”,这些选项都不能启用可访问性系统。

Intent intent = new Intent("android.settings.ACCESSIBILITY_SETTINGS");
startActivity(intent);
startActivityForResult(intent, 0);

很多人!

what is the proper way to request accessibility permission on xiaomi/miui devices programmatically?

The code snippet below on all other devices takes you to the screen with the option to enable accessibility. But on Xiaomi devices it takes to a screen with the following options: "Volume Shortcut", "Accessibility Menu" and "Downloaded Services", and none of these options enable the accessibility system.

Intent intent = new Intent("android.settings.ACCESSIBILITY_SETTINGS");
startActivity(intent);
startActivityForResult(intent, 0);

Thaks a lot!

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

悲凉≈ 2025-02-03 11:36:12

是的,我遇到了同样的问题,但是当您单击“下载服务”时,您可以查看所有应用程序索取可访问性许可。

Yes I had same problem but when you click on 'download service' you can get to see all apps asking for accessibility permission.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文