|
|
@@ -121,7 +121,7 @@ public class CommonUserItemView extends ConstraintLayout {
|
|
|
typedArray.recycle();
|
|
|
}
|
|
|
|
|
|
- private void setDetailTextDrawable(Drawable drawable,int padding){
|
|
|
+ public void setDetailTextDrawable(Drawable drawable,int padding){
|
|
|
if (drawable == null)
|
|
|
return;
|
|
|
drawable.setBounds(0,0,drawable.getMinimumWidth(),drawable.getMinimumHeight());
|
|
|
@@ -129,6 +129,22 @@ public class CommonUserItemView extends ConstraintLayout {
|
|
|
detailText.setCompoundDrawablePadding(padding);
|
|
|
}
|
|
|
|
|
|
+ public void setDetailTextDrawableRight(Drawable drawable,int padding){
|
|
|
+ if (drawable == null)
|
|
|
+ return;
|
|
|
+ drawable.setBounds(0,0,drawable.getMinimumWidth(),drawable.getMinimumHeight());
|
|
|
+ detailText.setCompoundDrawables(null,null,drawable,null);
|
|
|
+ detailText.setCompoundDrawablePadding(padding);
|
|
|
+ }
|
|
|
+
|
|
|
+ public void setTitleTextDrawable(Drawable drawable,int padding){
|
|
|
+ if (drawable == null)
|
|
|
+ return;
|
|
|
+ drawable.setBounds(0,0,drawable.getMinimumWidth(),drawable.getMinimumHeight());
|
|
|
+ titleText.setCompoundDrawables(drawable,null,null,null);
|
|
|
+ titleText.setCompoundDrawablePadding(padding);
|
|
|
+ }
|
|
|
+
|
|
|
public void setTitleText(String title){
|
|
|
titleText.setText(title);
|
|
|
}
|