Hi,
I have just implemented dragdrop from a custom control and in IE this seems to
work pretty much out of the box by just calling setDroppable and setDraggable
icw some drag events.
In several other browsers I kept getting the "invalid drag" cursor and was able
to locate the issue in the "qx.event.handler.DragDrop" code where extra events
are registered in _onMouseMove during the drag operation. The logic that checks
if the operation is valid is located in the mouseover event, but this event is
not triggered in many browsers.
As a workaround I implemented a mouse move on my own control and forwarded the
event to the drag drop handler like this:
var mgr =
qx.event.Registration.getManager(this).getHandler(qx.event.handler.DragDrop);
if (mgr) {
var target = null;
var fEl = this.__innnerControl.getFocusElement();
if (fEl) {
target = fEl.getDomElement();
}
var event = qx.event.Registration.createEvent("mousemove",
qx.event.type.Mouse, [{}, target, target, false, true]);
// Fake the mouse-over event on the DragDrop handler to set private
property "__validDrop" to true
mgr._onMouseOver(event);
}
Where the __innerControl is my own control and I do this on all non-mshtml
browsers. Now it works perfectly, but I don't think I should have to do this.
What are your ideas on this? I'm using Qx version 1.4.1 by the way and looking
at upgrading to the current version so I don't know if this is already fixed
there.
Best regards,
Jeroen
------------------------------------------------------------------------------
October Webinars: Code for Performance
Free Intel webinars can help you accelerate application performance.
Explore tips for MPI, OpenMP, advanced profiling, and more. Get the most from
the latest Intel processors and coprocessors. See abstracts and register >
http://pubads.g.doubleclick.net/gampad/clk?id=60135991&iu=/4140/ostg.clktrk
_______________________________________________
qooxdoo-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel