Skip to content
This repository has been archived by the owner on Nov 2, 2018. It is now read-only.

Recursively computing layout when RelativeLayout and android:layout_above #88

Open
ypresto opened this issue Jul 3, 2015 · 0 comments

Comments

@ypresto
Copy link
Contributor

ypresto commented Jul 3, 2015

I found memory is growing and GC is running when FreeFlow is shown even if I didn't touch to the device.
Allocation tracking says FreeFlow is computing layout constantly.

image

It was because FreeFlowContainer is placed in RelativeLayout and layout_above is used.
(I placed LinearLayout with fixed height of 76dp, which contains Buttons, on the bottom of fragment.)
For workaround I applied below diff to my xml file.

    <FreeFlowContainer
         android:layout_width="match_parent"
-        android:layout_height="wrap_content"
+        android:layout_height="match_parent"
         android:layout_alignParentTop="true"
-        android:layout_above="@id/footerButton"
+        android:layout_alignParentBottom="true"
+        android:layout_marginBottom="76dp"

This issue also causes bug that sometimes onItemSelected() is not called.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant