开发者

Flex tree droplocation indicator stuck (edit 2/4/10, almost a totaly different question)

开发者 https://www.devze.com 2022-12-17 09:30 出处:网络
OK I\'ve got a little more research on this done so I\'m going to totally rephrase the question: I have two trees, I want to be able to drag items from one tree to the other. In the receiving tree I h

OK I've got a little more research on this done so I'm going to totally rephrase the question:

I have two trees, I want to be able to drag items from one tree to the other. In the receiving tree I have some logic that allows or denys the drop. I am using the native cursor feedback Like this :

DragManager.showFeedback(DragManager.COPY);
DragManager.showFeedback(DragManage开发者_高级运维r.NONE);

When the logic determines NONE it properly rejects the item except the drop position indicator sticks like in the screenshot.

I know now that neither dragComplete, nor dragDrop are being fired in this situation, so I have no function to put code into that would clean that up. So how can I listen for this drag rejection?

ScreenShot shows app After drop

alt text http://img687.imageshack.us/img687/2245/treeindicatorstuck.png

Thanks ~Mike

PS with my other question: how-do-i-detect-that-drag-and-drop-operation-ended We have a way of getting an event to fire so we can clean up the tree control. I'm attaching an event listener to the stage so that as the mouse is moved (maybe I'll put it on a timer)it will constantly check if dragmanager.isdragging if it's not it will fire the tree.hideDropFeedBack. This still begs the question, what event is changing the isDragging Boolean and how do I listen for it?


You need to call tree.hideDropFeedback(); or event.target.hideDropFeedback(); to remove the drop indicators.

0

精彩评论

暂无评论...
验证码 换一张
取 消