Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 266548 - [target] Move... target button allows targets to be moved on top of each other
Summary: [target] Move... target button allows targets to be moved on top of each other
Status: RESOLVED FIXED
Alias: None
Product: PDE
Classification: Eclipse Project
Component: UI (show other bugs)
Version: 3.5   Edit
Hardware: PC Linux
: P3 normal (vote)
Target Milestone: 3.5 M6   Edit
Assignee: Ankur Sharma CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2009-02-27 14:50 EST by Curtis Windatt CLA
Modified: 2009-03-06 11:28 EST (History)
0 users

See Also:


Attachments
Full Patch (11.04 KB, patch)
2009-03-05 15:40 EST, Ankur Sharma CLA
curtis.windatt.public: iplog+
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Curtis Windatt CLA 2009-02-27 14:50:28 EST
Move... button was added in bug 264901.  Since we are on a preference page we don't actually create the new files in the workspace until OK or Apply is pressed.

The move... dialog only checks workspace files conflicts.  So it is possible to move two target definitions to the same place.  When this happens, one overwrites the other which is lost forever.

This is an uncommon case, but it is easily fixable.  We just need to pass the list of 'moved' targets to the Move wizard.  It can do an additional check to see if the path the user has chosen is already in the list and set an error message on the wizard.
Comment 1 Curtis Windatt CLA 2009-02-27 14:51:32 EST
Ankur, since you did the move button do you want to do this one?
Comment 2 Ankur Sharma CLA 2009-03-05 15:40:44 EST
Created attachment 127708 [details]
Full Patch
Comment 3 Curtis Windatt CLA 2009-03-06 11:27:55 EST
Applied patch to HEAD with some changes.  The patch did not hook up the preference page to use the functionality.  To make hooking it up easier, I changed the filter list to be a collection so we can just pass in the location values stored in the fMoved map in the preference page.