public static interface RecyclerView.ChildDrawingOrderCallback
| android.support.v7.widget.RecyclerView.ChildDrawingOrderCallback |
一个回调界面,可用于更改RecyclerView子项的绘制顺序。
它使用getChildDrawingOrder(int, int)方法工作,所以适用于该方法的任何情况也适用于此回调。 例如,如果由于高程覆盖此回调的结果而导致其高程值不同,则更改两个视图的绘制顺序不会产生任何影响。
公共方法(Public methods) |
|
|---|---|
abstract int |
onGetChildDrawingOrder(int childCount, int i) 返回为此迭代绘制的子的索引。 |
int onGetChildDrawingOrder (int childCount,
int i)
返回为此迭代绘制的子的索引。 如果要更改儿童的绘图顺序,请覆盖此选项。 默认情况下,它返回i。
| 参数(Parameters) | |
|---|---|
childCount |
int
|
i |
int: The current iteration. |
| 返回(Returns) | |
|---|---|
int |
The index of the child to draw this iteration. |