English 中文(简体)
如何在鼠标光标上设置拖放/可拖放事件
原标题:How to set the Droppable/Draggable Event on the mouse cursor

我使用 Ajax 行为在 Wicket 中实施了拖放效果。 如果我在树节点上拖动图像, 所接受的可下载位置在图像中间。 如何在光标上设置此位置( event)? 谢谢 。

问题回答

我也找到了,解决办法是:

DroppableAjaxBehavior b = new DroppableAjaxBehavior() {
    @Override
    public void onDrop(Component droppedComponent, AjaxRequestTarget target) {
        //do something to handle event
    }
};

b.setTolerance(ToleranceEnum.POINTER);




相关问题
Where to get the "latest" ASP .NET Preview DLL and Script

I have been trying to download the ASP .NET AJAX Futures but I can only see old versions of the DLL via sample tutorials from other websites. I need the DLL to use the Drag and Drop feature according ...

To MVVM or not to MVVM that is the question [closed]

I am rewriting my windows forms based application and I am going to use WPF. The application relies heavily on drag and drop techniques, in a very graphically environment. The uses "Design" reports ...

Make table rows sortable with YUI

Currently I have a table similar to below: <table id="tbl"> <thead> <tr><th>Example Title</th><th>Title2</th></tr> </thead> &...

Drag & drop with .ui files

I m having big troubles with drag & drop. I ve created a new Qt Designer Form Class in which I have one QListWidget and one QWidget. Now I want to enable dragging & dropping between these two ...

Java中校正

当我把档案从桌面上拖到浏览器时,我把浏览器放在重点(Safari或PireFox,现在),我知道一切工作权(拖拉,有回信等)。 我也能够......

热门标签