PDA

View Full Version : Check if row is expanded?



deving
3 Apr 2013, 10:47 AM
Is there a way to check if the row is expanded before toggling it using the row expander plug in? Or is there a method that just expands it (and does nothing if it's already expanded) or just collapses it (and does nothing if it's already collapsed)?

Thank you!

krullj
4 Apr 2013, 6:04 PM
If you look in the rowexpander source, it looks like they check whether or not a row is expanded in the following:

isCollapsed = row.hasCls(me.rowCollapsedCls)

You can see the rest of it here, in the toggleRow method: http://docs.sencha.com/ext-js/4-2/source/RowExpander.html#Ext-grid-plugin-RowExpander