int () { for (View v = this; v != null; ) { View parent = v.getParent(); if (parent instanceof FlowView) { int childCount = parent.getViewCount(); for (int i = 0; i < childCount; i++) { if (parent.getView(i) == v) { return ((FlowView)parent).getFlowSpan(i); } } } v = parent; } return 0; }