Summary: | [Wizards] WizardResourceImportPage's contructor does not attempt to find a common IContainer amongst multiple selected resources. | ||||||
---|---|---|---|---|---|---|---|
Product: | [Eclipse Project] Platform | Reporter: | Dominique Emond <dremond> | ||||
Component: | UI | Assignee: | Platform UI Triaged <platform-ui-triaged> | ||||
Status: | NEW --- | QA Contact: | |||||
Severity: | normal | ||||||
Priority: | P3 | CC: | Michael.Valenta, Tod_Creasey | ||||
Version: | 3.2 | ||||||
Target Milestone: | --- | ||||||
Hardware: | All | ||||||
OS: | All | ||||||
Whiteboard: | hasPatch | ||||||
Attachments: |
|
Description
Dominique Emond
2006-01-27 17:02:19 EST
Created attachment 33966 [details]
Patch for org\eclipse\ui\dialogs\WizardResourceImportPage.java
Could you provide a description of the problem? Currently the import wizard will only populate the "Into folder" field if 1 resource is pre-selected by the user in a view. (The logic for this lies in the WizardResourceImportPage constructor). For a logical element (which uses the new ResourceMapping concept), it is possible for it to be mapped to 1-to-N resources. Having said that, what currently happens is when the user selects 1 logical element that has several resources backing it, the WizardResourceImportPage receives a structured selection of size > 1 and the current code sets currentResourceSelection to null (basically ignores this selection), and the "Into folder" field stays blank. The WizardResourceImportPage should really try to determine a container common to all selected resources. Example : If 2 resources from 1 logical element sit in the same project, then that project should be the common container, and it should show up in the "Into folder". If none can be found (as in the case where 2 logical elements are selected from DIFFERENT projects), only then set currentResourceSelection to null, and cause the "Into folder" field to stay blank. Copying Tod, as he has done some of the logical resource changes in the UI. I am giving this bug to Tod as he is working on the logical->physical resources problem. Hi Tod, We were hoping this fix could make it in mid-Feburary. Is this possible? Please advise. Thank you. :) As this is an API change it is pretty late in the game to get this in (API freeze is in 3 hours). Do you need that method to be protected? If it can be private we have more flexibility. In WizardResourceImportPage, you can make the method private: as show below: private IResource getCommonIResource(IStructuredSelection selection) { That's fine with me. Thanks. :) Why is it you want this behavioural change BTW. We generally do not try to find common parents for something like this as it is so easy to select something that is not what the user wanted. If they have a single selection they are clear. Hi, Our reasons are listed in Comment #3. But to re-iterate briefly... We want the import wizard activated off our logical view to behave the "same" as when activated off the navigator view (non-logical view). If our single logical element has 2 resources backing it (the user can only see the single logical element), and the user has it selected before right-clicking and selecting Import..., the user should see the project name of those 2 backing resources in the Into folder; JUST LIKE the user would see the project name of a single resource appear in the Into Folder field of the Import wizard if 1 single file was selected before the wizard was chosen. Prakash is now responsible for watching bugs in the [Wizards] component area. 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. |