Augustyniak / RATreeView

Library providing easy-to-use interface for displaying tree structures on iOS and tvOS.
MIT License
2.49k stars 466 forks source link

IsItemExpanded #172

Closed MobileMon closed 8 years ago

MobileMon commented 8 years ago

How can I tell if an item is expanded

I use treeView.isCellExpanded but the problem is it only lets me know after the animation for expansion is complete. I need to know before the animation is complete so I can show different states of an open close button (+, -)

joshjack commented 8 years ago

Why not do that before you expand the item? You know which item will be expanded when the users taps; or during the initial render.

On Fri, Apr 22, 2016 at 1:28 PM, MobileMon notifications@github.com wrote:

How can I tell if an item is expanded

I use treeView.isCellExpanded but the problem is it only lets me know after the animation for expansion is complete. I need to know before the animation is complete so I can show different states of an open close button (+, -)

— You are receiving this because you are subscribed to this thread. Reply to this email directly or view it on GitHub https://github.com/Augustyniak/RATreeView/issues/172

Joshua Jackson, PhD

Senior Research Engineer

(800) 604-1822 (256) 648-5109

josh@nside.io www.nSide.io http://www.nside.io/

http://www.nside.io/ 4031 Parkway Dr, Suite B, Florence, AL 35630

https://www.facebook.com/nsidemapping http://www.linkedin.com/company/nside/ http://twitter.com/nSide__Out Confidentiality Warning: This e-mail contains information intended only for the use of the individual or entity named above. If the reader of this e-mail is not the intended recipient or the employee or agent responsible for delivering it to the intended recipient, any dissemination, publication or copying of this e-mail is strictly prohibited. The sender does not accept any responsibility for any loss, disruption or damage to your data or computer system that may occur while using data contained in, or transmitted with, this e-mail. If you have received this e-mail in error, please immediately notify us by return e-mail. Thank you.

MobileMon commented 8 years ago

Hmm ok I guess that works. I can just store the state on the data object and set it in willSelectRowForItem, reload that item, then continue with didselectitem

A little laborious to do this work but it works. Still feel like the treeview should be responsible for this