Bug 36029 - [Dialogs] ResourceListSelectionDialog has no API to set pattern
Summary: [Dialogs] ResourceListSelectionDialog has no API to set pattern
Status: VERIFIED FIXED
Alias: None
Product: Platform
Classification: Eclipse Project
Component: UI (show other bugs)
Version: 2.1   Edit
Hardware: PC Windows XP
: P4 enhancement with 2 votes (vote)
Target Milestone: 3.3 M6   Edit
Assignee: Szymon Brandys CLA
QA Contact:
URL:
Whiteboard:
Keywords: helpwanted
Depends on:
Blocks:
 
Reported: 2003-04-03 12:56 EST by Marcio CLA
Modified: 2013-02-04 11:11 EST (History)
4 users (show)

See Also:


Attachments
This is a patch that should resolve he problem (1.35 KB, patch)
2006-02-15 14:18 EST, Alex Chapiro CLA
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Marcio CLA 2003-04-03 12:56:23 EST
I want to use a ResourceListSelectionDialog bit have it open with the initial 
filter (pattern) of "*.e". The filter/pattern can't be passed as parameter to 
the constructor or as API. Subclasses can't get to the field either.

Please provide API or make the field protected so that subclasses can set it 
from their constructors.
Comment 1 Patrick Baker CLA 2003-11-27 11:39:20 EST
I agree with Marcio that this would be a really useful feature to have, and it 
is so easy to provide. Just add a new constructor, and possibly a new 'setter' 
method as well.

Please add the functionality to the ResourceListSelectionDialog directly. This 
isn't the kind of thing that you want plugin developers to add with a subclass. 
Subclassing is brittle, it is always possible for the implementors of 
ResourceListSelectionDialog to make a change that will break how some lowly 
plugin developer embellished it.
Comment 2 Tod Creasey CLA 2004-04-07 14:02:38 EDT
We likely will not have time to do this ourselves for 3.0. However if you have 
a suggested patch feel free to attach it.
Comment 3 Tod Creasey CLA 2004-06-28 11:28:24 EDT
Reopening now that 3.0 has shipped
Comment 4 Ed Willink CLA 2005-06-04 01:37:25 EDT
I have just stolen ResourceListSelectionDialog with remarkable ease to
create a selection for EMF elements within an EMF ResourceSet. But I had
to copy all the code.

There seems to be a much more general functionality here to select from a
hierarchy of objects that have labels.

So if use of IResource/IContainer is generalised to Object serviced by a
ContentProvider, externally settable LabelProvider, and a Filter rather
than an int typeMask, I could have used it unchanged. 
Comment 5 Susan McCourt CLA 2005-12-14 13:14:59 EST
investigate during M5 as part of the refactoring going on in bug 94382.
Comment 6 Susan McCourt CLA 2006-02-02 13:41:31 EST
sorry, this is being punted from my 3.2 plan in favor of other more pressing issues.
Comment 7 Alex Chapiro CLA 2006-02-15 14:18:46 EST
Created attachment 34789 [details]
This is a patch that should resolve he problem

Tested on 3.2M4. Should be valid for the HEAD branch because class ResourceListSelectionDialog has not been changed quite a while.
Comment 8 Susan McCourt CLA 2006-02-15 16:02:56 EST
Thanks for the patch.  I'm marking this bug M6 as a reminder to take a look.
Comment 9 Susan McCourt CLA 2006-03-15 17:50:25 EST
Not sure what I was thinking when I moved this back to M6, since M5 was API freeze.  Any exceptions must be PMC approved, so this one won't be looked at unless priority is raised.
Comment 10 Susan McCourt CLA 2006-07-10 17:25:41 EDT
moving Open Resource related bugs to Szymon.
Szymon, please move between you and Krystof as needed.  Let me know if you have any questions.  These are all the bugs I had related to OpenResource.
Comment 11 Krzysztof Michalski CLA 2007-03-26 05:15:31 EDT
Done, fixed for M6.
Comment 12 Szymon Brandys CLA 2007-03-26 05:15:51 EDT
Fixed in 3.3 M6
Comment 13 Heiko Kopp CLA 2013-02-02 12:34:31 EST
This is no longer fixed for Eclipse 4.2. The ResourceListSelectionDialog again lacks the possibility to set an initial Pattern.
Comment 14 Paul Webster CLA 2013-02-04 11:11:45 EST
(In reply to comment #13)
> This is no longer fixed for Eclipse 4.2. The ResourceListSelectionDialog
> again lacks the possibility to set an initial Pattern.

I went back through our releases, and although this bug is marked as fixed I cannot find this API actually added.

Unless they mean that because FilteredResourcesSelectionDialog replaces  ResourceListSelectionDialog this API is now available.

PW