-
Notifications
You must be signed in to change notification settings - Fork 110
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Creation of more/less accordions #2
Comments
Hi jt234, Thanks for this, need to have a look but it should be fairly simple to be allowed to add more sections in runtime. Recently I added some methods to be allowed to hide sections so maybe that's a temporary options for you (create all what you need, then hide and show on demand). Cheers, |
Hi hamsterready, I think it would be a nice feature to be able to have the ability, as you have stated, to add more accordion sections programmatically. I might have a go at creating the encasing <com.sentaca.android.accordion.widget.AccordionView ... > </com.sentaca.android.accordion.widget.AccordionView> programmatically (although I highly doubt this will work, in fact I know it wont) just to see if I can get it to work. But when it comes to it, I think that the use of your hidden sections will have to be a temporary fix for me. Thanks for your quick feedback. Cheers, |
After a bit of research and working code I have found that it is more idealistic to utilize the android ExpandableListView. You would be able to create an accordion type view while also being able to create/remove accordion elements programmatically. |
Hi jt234, First version was based on ListView but I have hit some major issues with passing events to ui components added to this kind of accordion. Possibly was doing something wrong :) |
i have to create a dynamic Accordian, means each time when accordian will shown it has different number of section. |
Thanks hamsterready,
and modified the children layout . thanks a lot for such a wonderful code. |
The number of accordion views is locked to the amount of elements you have in the string array labelled accordion_sections.
To give the developer more flexibility it could be ideal to remove this connection from the string array as I have done.
I was just wondering if there would be any problem in doing this.
My first thought may be a problem with the value returned by getChildCount().
Any thoughts/ideas wouldn't go unnoticed,
Cheers,
jt234
The text was updated successfully, but these errors were encountered: