bytedance / bytedance/CodeLocator
在 android 25 的版本以下 CodeLocatorLayoutInflator 调用 createView 会报 nullpoint
Open
- Dominant language
- Java
- Stars
- 2.2k
- Forks
- 182
- PR merge metrics
- No merged PRs in 30d
Description
具体原因是 Android 25 版本以下 LayoutInflater 实现不同 ,args[0] 为 context 的初始化方式不同,最后导致new view的时候报 NullPointerExeception,我找不到修复的办法,目前是简单关闭了HookInflater 功能来绕过的
绕过代码如下
```java
if(Build.VERSION.SDK_INT <= Build.VERSION_CODES.N_MR1) {
CLog.i(TAG, "CodeLocator 关闭对这个 ${Build.VERSION.SDK_INT} 版本的支持,会导致不能换肤")
CodeLocator.config(CodeLocatorConfig.Builder().enableHookInflater(false).build())
}
```
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.