关于在BaseApplication中初始化的代码需要权限问题(Android 6.0下)
阿神
阿神 2017-04-17 17:18:57
0
2
710

RT,使用了一些例如崩溃跟踪之类的第三方类库,初始化时在BaseApplication中,权限按照老的权限系统写在清单文件中,但是由于需要一些要主动申请的权限,初始化总是会失败。
目前是在启动页检查权限,如果没有的话写入权限,但是这样第一次启动APP,初始化还是失败的(Application在启动页前面加载的时候还没有被赋予权限)。
请问该怎么处理呢?
(我知道该targetSDKVersion的方法,但是显然适配6.0才是比较好的解决方案)

阿神
阿神

闭关修行中......

reply all(2)
黄舟

If the third party creates the file during initialization, it can only prevent it from being initialized in the Application and change it to other interfaces. Otherwise, it can only wait for the third party to realize this problem and make modifications.

洪涛

When using third-party packages, generally official documents have instructions. You can inherit the Application you need and then inherit it in multiple layers.

Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template