Flex:AdvancedDataGrid 树 dropParent
我有一个 AdvancedDataGrid 树,以 ArrayCollection 作为其数据提供者。例如,现在我将一片叶子从一个节点拖到另一个节点。为了捕获该事件,我添加了一个监听器来拖拽完成。
AdvancedDG.addEventListener(DragEvent.DRAG_COMPLETE, dRAG_COMPLETE_Handler);
公共函数 dRAG_COMPLETE_Handler(事件:DragEvent):void { var dropNode:Object = event.dropParent; <-- ??? 我
的问题:我想知道叶子被丢弃的新节点。实际上,我希望万一有一个像 dropParent 这样的属性。事实并非如此。
为我糟糕的英语感到遗憾。
I have an AdvancedDataGrid tree with a ArrayCollection as its dataprovider. Now, for instance, i drag a leaf from one node to another node. To catch the event I'm adding a Listener to dragComplete.
advancedDG.addEventListener(DragEvent.DRAG_COMPLETE, dRAG_COMPLETE_Handler);
public function dRAG_COMPLETE_Handler(event: DragEvent):void{
var dropNode:Object = event.dropParent; <-- ???
}
My Problem: I want to know the new node where the leaf was dropped. Actually i would have expected that in the event there is a property like dropParent. This is not the case.
Sry for my bad English.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
我会将监听器更改为dragDrop。现在你的拖动事件将有一个event.currentTarget,它是处理dragDrop事件的项目,你应该能够使用这个event.currentTarget来找到你正在寻找的父节点。
我希望我正确理解了你的问题并且这会有所帮助。
~迈克
I would change the listener to dragDrop. Now your drag event will have a event.currentTarget, which is the item processing the dragDrop event you should be able to use this event.currentTarget to find the parent node you are looking for.
I hope I have understood your question correctly and that this helps.
~Mike