Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 348609 - Drag start fails on Linux and Mac
Summary: Drag start fails on Linux and Mac
Status: RESOLVED FIXED
Alias: None
Product: e4
Classification: Eclipse Project
Component: UI (show other bugs)
Version: unspecified   Edit
Hardware: All All
: P3 major (vote)
Target Milestone: 4.1 RC4   Edit
Assignee: Eric Moffatt CLA
QA Contact: Eric Moffatt CLA
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-06-07 12:47 EDT by Eric Moffatt CLA
Modified: 2011-06-08 08:45 EDT (History)
3 users (show)

See Also:
emoffatt: pmc_approved?
gheorghe: review+


Attachments
Patch to use DragDetect events to start the drag (8.46 KB, patch)
2011-06-07 12:52 EDT, Eric Moffatt CLA
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Eric Moffatt CLA 2011-06-07 12:47:28 EDT
The basic issues was that we were using 'hand rolled' display filters to start the drag. On Linux this failed because the eventing is asynchronous but the 'DnDInfo' was always set using the Display methods (i.e. getCursorControl(), getCursorLocation()...). By the time the mouse down event arrived the cursor had already been moved to a location where the element under (likely a part) was not a valid 'draggable' element...

Selineo fixed me up with the correct pattern which is to use the 'dragDetect' event instead.
Comment 1 Eric Moffatt CLA 2011-06-07 12:52:33 EDT
Created attachment 197521 [details]
Patch to use DragDetect events to start the drag


This patch removes *all* the display filters (a very good thing) and replaces them with a model listener that adds a 'dragDetect' listener to all rendered MPartStack's CTF.

While this is cleaner we'll have to revisit this post-4.1 since the 'pure Tracker' approach this patch uses *cannot* support more dynamic DnD operations (like 'hosted' drags...).
Comment 2 Eric Moffatt CLA 2011-06-07 15:09:35 EDT
Committed in >20110607. Applied the patch.

This has been tested but should be verified once the new build comes out...
Comment 3 Eric Moffatt CLA 2011-06-07 15:09:56 EDT
Marking FIXED.
Comment 4 Remy Suen CLA 2011-06-08 08:45:48 EDT
(In reply to comment #1)
> Created attachment 197521 [details]
> Patch to use DragDetect events to start the drag

This change has caused a regression when trying to split yourself in the shared area, see bug 348720.