Bug 309985 - [CommonNavigator] Drop feedback is copy (+) instead of none on an empty Project Explorer
Summary: [CommonNavigator] Drop feedback is copy (+) instead of none on an empty Proje...
Status: NEW
Alias: None
Product: Platform
Classification: Eclipse Project
Component: UI (show other bugs)
Version: 3.6   Edit
Hardware: PC Windows XP
: P3 normal (vote)
Target Milestone: ---   Edit
Assignee: Platform UI Triaged CLA
QA Contact:
URL:
Whiteboard: dnd
Keywords:
Depends on:
Blocks:
 
Reported: 2010-04-21 11:27 EDT by Dani Megert CLA
Modified: 2019-09-06 15:30 EDT (History)
2 users (show)

See Also:


Attachments
Patch that makes the operation change appropriately given the target. (3.98 KB, text/plain)
2010-04-21 14:41 EDT, Serge Beauchamp CLA
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Dani Megert CLA 2010-04-21 11:27:44 EDT
I20100414-1200.

1. start new workspace
2. open Project Explorer
3. drag a file from the OS file explore to the Project Explorer
==> a [+] feedback appears giving the impression that copy is possible [BUG]
4. drop it
==> a dialog appears [BUG]
Comment 1 Francis Upton IV CLA 2010-04-21 11:30:41 EDT
Serge, do you think this is yours or do you want me to have a look?
Comment 2 Serge Beauchamp CLA 2010-04-21 14:04:55 EDT
This is basically the same bug as bug 302441
Comment 3 Serge Beauchamp CLA 2010-04-21 14:07:57 EDT
From looking at the code, I think there's some limitations that prevent the DROP_MOVE operation to be set.

Anyhow, fundamentally, this is a limitation of SWT that it doesn't have a DROP_PROMPT operation.

Otherwise, in Windows Explorer for example, the 'prompt' drag and drop cursor is the same as the 'copy' one (when drag and drop with the right click).
Comment 4 Francis Upton IV CLA 2010-04-21 14:12:04 EDT
(In reply to comment #3)
> From looking at the code, I think there's some limitations that prevent the
> DROP_MOVE operation to be set.
Can you elaborate on this?

By default it should be a move right, unless control is pressed then it's a copy? (on Windows).
Comment 5 Serge Beauchamp CLA 2010-04-21 14:41:40 EDT
Created attachment 165620 [details]
Patch that makes the operation change appropriately given the target.

For this to work, it requires a API addition in CommonDropAdapterAssistant.java.

The getDragOperation() method should be integrated into ImportTypeDialog in 3.7 and made API.
Comment 6 Francis Upton IV CLA 2010-04-21 14:46:28 EDT
(In reply to comment #5)
> Created an attachment (id=165620) [details]

> For this to work, it requires a API addition in
> CommonDropAdapterAssistant.java.
We don't need to make this API, just mark it @noreference (I think), and then you will need to add an API filter to the o.e.ui.navigator.resources for the exception.
Comment 7 Dani Megert CLA 2010-04-22 03:04:40 EDT
IMPORTANT NOTE (not sure whether this was understood): This bug is only about moving over the EMPTY Project Explorer (or if there are elements, when not moving over one of them). In that scenario we must show the DROP_NONE feedback and not show [+] and then a dialog.
Comment 8 Dani Megert CLA 2010-04-22 03:05:12 EDT
This used to work just fine before, so I don't see why we would need new API for this.
Comment 9 Serge Beauchamp CLA 2010-04-22 06:48:42 EDT
(In reply to comment #7)
> IMPORTANT NOTE (not sure whether this was understood): This bug is only about
> moving over the EMPTY Project Explorer (or if there are elements, when not
> moving over one of them). In that scenario we must show the DROP_NONE feedback
> and not show [+] and then a dialog.

Ah, sorry, I didn't get that, I though it was about the drop operation over a given container
Comment 10 Dani Megert CLA 2010-04-22 06:56:54 EDT
And while looking at your patch for bug 301187 I think we should not touch the DND feedback i.e. not show LINK feedback when link is set. If we'd do so, it has many consequences and also results in different code paths which aren't covered yet. We should probably wait with that for 3.7.
Comment 11 Dani Megert CLA 2010-04-24 06:49:21 EDT
This is a regression which must be fixed for 3.6.
Comment 12 Francis Upton IV CLA 2010-04-24 10:14:39 EDT
(In reply to comment #11)
> This is a regression which must be fixed for 3.6.
Ok, I don't really understand what's going on here, who is going to fix this today?
Comment 13 Dani Megert CLA 2010-04-25 11:53:22 EDT
Too late for M7. Moving to RC1. +1 to fix this during RC1 since this is an ugly regression introduced during M6. Serge, I guess you know best which changes you made to DnD for the link/group support.
Comment 14 Dani Megert CLA 2010-04-25 12:01:33 EDT
>Too late for M7. Moving to RC1. +1 to fix this during RC1 since this is an ugly
>regression introduced during M6.
Oops, sorry guys: t looks like that bug (giving copy feedback is in since the beginning and since 3.5 we show the dialog on drop (before nothing happened).
Comment 15 Francis Upton IV CLA 2010-04-25 12:11:57 EDT
(In reply to comment #14)
> >Too late for M7. Moving to RC1. +1 to fix this during RC1 since this is an ugly
> >regression introduced during M6.
> Oops, sorry guys: t looks like that bug (giving copy feedback is in since the
> beginning and since 3.5 we show the dialog on drop (before nothing happened).

Guess it's my problem now. :)
Comment 16 Eclipse Webmaster CLA 2019-09-06 15:30:55 EDT
This bug hasn't had any activity in quite some time. Maybe the problem got resolved, was a duplicate of something else, or became less pressing for some reason - or maybe it's still relevant but just hasn't been looked at yet.

If you have further information on the current state of the bug, please add it. The information can be, for example, that the problem still occurs, that you still want the feature, that more information is needed, or that the bug is (for whatever reason) no longer relevant.