feat: 增强BackgroundUtils属性获取功能
- 新增 getAttributeValueType() 函数,返回当前属性值类型 - 新增 getResId() 和 getColor() 公共函数,用于获取具体的属性值
This commit is contained in:
@@ -93,6 +93,18 @@ public class BackgroundUtils {
|
||||
return drawableType;
|
||||
}
|
||||
|
||||
public DrawableType getAttributeValueType() {
|
||||
return drawableType;
|
||||
}
|
||||
|
||||
public int getResId() {
|
||||
return resId;
|
||||
}
|
||||
|
||||
public int getColor() {
|
||||
return color;
|
||||
}
|
||||
|
||||
public void saveToPreferences() {
|
||||
if (context == null) return;
|
||||
SharedPreferences prefs = context.getSharedPreferences(PREF_NAME, Context.MODE_PRIVATE);
|
||||
|
||||
Reference in New Issue
Block a user