diff --git a/library/src/main/java/com/github/aakira/expandablelayout/ExpandableRelativeLayout.java b/library/src/main/java/com/github/aakira/expandablelayout/ExpandableRelativeLayout.java index 7c3de98..5a87e1f 100644 --- a/library/src/main/java/com/github/aakira/expandablelayout/ExpandableRelativeLayout.java +++ b/library/src/main/java/com/github/aakira/expandablelayout/ExpandableRelativeLayout.java @@ -109,7 +109,7 @@ protected void onMeasure(int widthMeasureSpec, int heightMeasureSpec) { } childPositionList.add(sumSize + childSize + childMargin); } - layoutSize = getCurrentPosition(); + layoutSize = childPositionList.get(childPositionList.size() - 1); if (0 < layoutSize) { isCalculatedSize = true;