Expected resource of type styleable [ResourceType]
错误原因最近在项目中由于要使用沉浸式通知栏,所以使用了一个工具类SystemBarTintManager,而这个工具类在项目打包的过程中提示了一个错误:Expected resource of type styleable

在stackoverflow中发现很多人反馈这个问题,解决方案是在使用 TypedArray 的方法声明处顶部加上 @SuppressWarnings(“ResourceType”) 忽略该警告,然后就可以正常签名编译。具体做法如下:
@SuppressWarnings("ResourceType")
public SystemBarTintManager(Activity activity) {
……
} 来自 “ ITPUB博客 ” ,链接:https://blog.itpub.net/3209/viewspace-2799821/ ,如需转载,请注明出处,否则将追究法律责任。