public class XViewHelper
extends java.lang.Object
| 构造器和说明 |
|---|
XViewHelper() |
| 限定符和类型 | 方法和说明 |
|---|---|
static void |
expendTouchArea(android.view.View view,
int expendSize)
扩展点击区域的范围
|
static void |
setBackground(android.view.View view,
android.graphics.drawable.Drawable drawable) |
static void |
setBackgroundColorKeepPadding(android.view.View view,
int color) |
static void |
setBackgroundKeepingPadding(android.view.View view,
android.graphics.drawable.Drawable drawable) |
public static void expendTouchArea(android.view.View view,
int expendSize)
view - 需要扩展的元素,此元素必需要有父级元素expendSize - 需要扩展的尺寸(以sp为单位的)public static void setBackground(android.view.View view,
android.graphics.drawable.Drawable drawable)
public static void setBackgroundKeepingPadding(android.view.View view,
android.graphics.drawable.Drawable drawable)
public static void setBackgroundColorKeepPadding(android.view.View view,
int color)