隐藏意图的权限在Android中? [英] Hiding permission intent in Android?

查看:89
本文介绍了隐藏意图的权限在Android中?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我们知道,Android操作系统有一定的限制,以programmetically操作设备硬件,就像它显示意图,用户需要为是真正的回归到具体的意图,我-E:

As we know, Android OS has some restrictions to operate device hardwares programmetically, like it shows intent to user which requires YES for return true to the specific intent, i-e:

Intent enableBtIntent = new Intent(BluetoothAdapter.ACTION_REQUEST_ENABLE);
startActivityForResult(enableBtIntent, 1);

我想隐藏从用户这一意图,并希望返回true,因为如果用户点击YES,
有没有什么办法,以code这样?

I want to hide this intent from user, and want to return true, as if user click YES, is there any way to code like this ?

我不是问开启蓝牙未经许可,像( myBlueToothAdapter.enable()作品),我要隐藏另一个意图它的工作原理与此相同的..

I am not asking about turn ON bluetooth without permission, like( myBlueToothAdapter.enable() works) I have to hide another intent which works same as this one..

希望有人能指导我的正确方法。先谢谢了。

Hope someone can guide me to the proper way. Thanks in advance.

推荐答案

为Android到位的安全机制注定会禁止这一点。

The security mechanisms in place for Android would inherently forbid this.

这篇关于隐藏意图的权限在Android中?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆