View Full Version : How to differentiate when TreePanel itemappend events are fired?

8 Nov 2013, 10:13 AM
The TreePanel's itemappend event is fired both when the underlying TreeStore is loaded and each node is added to the panel, and when a node is dragged and dropped.

I want to fire a custom event in the itemappend listener, but only when a node is dropped - not after a store.load() itemappend.

Is there an existing way to differentiate between what event fires the TreePanel's itemappend? Store.isLoading() is already false by the time itemappend is fired. I could set a variable based on what I'm trying to do (like when the selection changes), but that seems a little hacky.

8 Nov 2013, 11:46 AM
Could you listen to the TreeView's drop (http://docs.sencha.com/extjs/4.2.2/#!/api/Ext.tree.plugin.TreeViewDragDrop-event-drop) event instead?