Comments (9)
Thank you for reporting.
Yes,
It is difficult to adjust size if a height of child elements don't be fixed when onMeasure()
is called.
I'll try to fix this issue.
Please send your PR if you have a good idea. :-)
from expandablelayout.
You can see, when I make the first child item VIEW.GONE,
the relativelayout does not work well, it's too high, the red part.
Tonight I use some time to read your code.
I find childPositionList hold the real height of every child item sum.
So why not use it as relativelayout's height or width?
The key code in onMeasure method:
layoutSize = getCurrentPosition();
What about:
layoutSize = getChildPosition(childPositionList.size()-1);
Then, every child item can be VIEW.GONE.
And the example i commented 4 day ago may also be solved.
At last, it's just a idea.
from expandablelayout.
I'm so sorry!
I was thinking I fixed this line.
Thank you so much!
I updated this library which is v1.4.1.
Please check it.
from expandablelayout.
wrap_content not working on v1.4.1 @AAkira
from expandablelayout.
i am using ExpandableRelativeLayout
from expandablelayout.
there is a huge space at bottom of layout
from expandablelayout.
OK, it worked after i added RelativeLayout inside ExpandableRelativeLayout(wrap_content). All other views are inside RelativeLayout(wrap_content)
from expandablelayout.
@AAkira First of all nice library 👍
It seems like 'wrap_content' in ExpandableRelativeLayout is not working in 1.4.3. I downgraded it to 1.4.1 and its all working fine.
from expandablelayout.
I'm sorry that I didn't notice.
I fixed it in v1.5.0.
Please check it.
from expandablelayout.
Related Issues (20)
- Very nice
- Option onClick
- How collapse when activity viewed? HOT 1
- Collapse at certain height? HOT 1
- Recyclerview collapse mode : Unwanted negative space HOT 1
- Change the arrow icon
- Measured height for programatically added view is larger than actual size
- expand issue HOT 6
- Expandable Relative Layout not shows data in recyclerView got from server HOT 1
- After update 27 api its not supporting, what is another solutions?
- app get crashed when i add more than 5 elements in recycler view
- After changing one of children's visibility ExpandableLinearLayout is not resized
- Expand single child at a time in Expandable Linear Layout
- Expandable ExpandedLinearLayout object height HOT 1
- expand and collapse does not work in android 9 HOT 1
- IllegalStateException: at com.github.aakira.expandablelayout.ExpandableLinearLayout.onMeasure (ExpandableLinearLayout.java:140) HOT 2
- ExpandableLinearLayout in recycler view affects animations HOT 1
- Expand issue
- JCenter is at end of life
- JCenter replacement
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from expandablelayout.