Bug 323679 - [build path] Add Filter field to Project Properties - Libraries
Summary: [build path] Add Filter field to Project Properties - Libraries
Status: ASSIGNED
Alias: None
Product: JDT
Classification: Eclipse Project
Component: UI (show other bugs)
Version: 3.6   Edit
Hardware: All Windows 7
: P3 enhancement (vote)
Target Milestone: ---   Edit
Assignee: Patrik Suzzi CLA
QA Contact:
URL:
Whiteboard:
Keywords: bugday, helpwanted
: 471412 (view as bug list)
Depends on:
Blocks:
 
Reported: 2010-08-26 03:03 EDT by Jan Hoppe CLA
Modified: 2015-11-23 15:27 EST (History)
7 users (show)

See Also:


Attachments
My Libraries (123.42 KB, image/png)
2010-08-26 03:06 EDT, Jan Hoppe CLA
no flags Details
Video of the filtering solution implemented, 400kb (392.02 KB, video/mp4)
2015-11-06 18:24 EST, Patrik Suzzi CLA
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Jan Hoppe CLA 2010-08-26 03:03:10 EDT
Add Filter field to Project Properties - Libraries.

I often do not find a specific entry in those dozen entries in my project propery. A filter field would help a lot! By the way it's an eclipse standard!

Thanks,
Jan


-- Configuration Details --
Product: Eclipse 1.3.0.20100617-0520 (org.eclipse.epp.package.java.product)
Installed Features:
 org.eclipse.jdt 3.6.0.v20100526-0800-7z8XFUJFMTfCWGoVuHImpms9H155



-- Configuration Details --
Product: Eclipse 1.3.0.20100617-0520 (org.eclipse.epp.package.java.product)
Installed Features:
 org.eclipse.jdt 3.6.0.v20100526-0800-7z8XFUJFMTfCWGoVuHImpms9H155
Comment 1 Jan Hoppe CLA 2010-08-26 03:06:26 EDT
Created attachment 177495 [details]
My Libraries
Comment 2 Frederic Fusier CLA 2010-08-26 07:46:52 EDT
Move to JDT/UI
Comment 3 Markus Keller CLA 2010-08-27 05:42:41 EDT
Fair request.
Comment 4 Noopur Gupta CLA 2015-06-30 04:38:55 EDT
*** Bug 471412 has been marked as a duplicate of this bug. ***
Comment 5 Patrik Suzzi CLA 2015-11-06 03:15:24 EST
I am taking a stab on this. 

The UI is defined in LibrariesWorkbookPage, which contains a 
TreeListDialogField that is the "Control" with the tree showing the Libraries.

My approach would be to use a FilteredTree instead of a Tree used in 
TreeListDialogField.createTreeViewer()

Suggestions and comments are welcome.
Comment 6 Patrik Suzzi CLA 2015-11-06 18:24:09 EST
Created attachment 257798 [details]
Video of the filtering solution implemented, 400kb

As explained in [1] I used FilteredTree; as in reference [2] I added a PatternFilter; as in reference [3] I checked the prerequisites, including tree leaves implementing ILabelProvider. 
Im my implementation i did the following choices: 
- I used the boolean filteringEnabled to represent need of having the list filtered, as TreeListDialogField.createTreeViewer(.) is reused
- I used advanced layouting, as FilteredTree.createControl(..) is setting bad (grid) layout data, for things in this case.


[1] http://eclipsesource.com/blogs/2012/10/26/filtering-tables-in-swtjface/
[2] http://help.eclipse.org/juno/index.jsp?topic=%2Forg.eclipse.platform.doc.isv%2Freference%2Fapi%2Forg%2Feclipse%2Fui%2Fdialogs%2FFilteredTree.html
[3] http://help.eclipse.org/juno/index.jsp?topic=%2Forg.eclipse.platform.doc.isv%2Freference%2Fapi%2Forg%2Feclipse%2Fui%2Fdialogs%2FPatternFilter.html
Comment 7 Eclipse Genie CLA 2015-11-06 18:28:07 EST
New Gerrit change created: https://git.eclipse.org/r/59877
Comment 8 Patrik Suzzi CLA 2015-11-16 17:44:03 EST
There is a Gerrit change pending for this helpwanted bug  :)
Comment 9 Noopur Gupta CLA 2015-11-23 15:27:41 EST
(In reply to Eclipse Genie from comment #7)
> New Gerrit change created: https://git.eclipse.org/r/59877

I didn't check the code yet. On trying out the patch, found the following issue:
- Type a filter text (example: *e4) => filtered results will be displayed.
- Now, click on "Clear" to clear the filter text.
Issue: All the filtered library nodes from the previous step are now left in expanded state in the tree.