Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 325623 - [Quick type hierarchy] Hide non implementing classes
Summary: [Quick type hierarchy] Hide non implementing classes
Status: RESOLVED FIXED
Alias: None
Product: CDT
Classification: Tools
Component: cdt-source-nav (show other bugs)
Version: 8.0   Edit
Hardware: All All
: P3 enhancement (vote)
Target Milestone: 8.0   Edit
Assignee: Markus Schorn CLA
QA Contact: Markus Schorn CLA
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-09-17 12:35 EDT by Marc-André Laperle CLA
Modified: 2010-09-29 00:09 EDT (History)
0 users

See Also:


Attachments
Hide non implememting classes (2.09 KB, patch)
2010-09-25 17:45 EDT, Marc-André Laperle CLA
no flags Details | Diff
Test project (5.49 KB, application/zip)
2010-09-25 17:47 EDT, Marc-André Laperle CLA
no flags Details
Hide non implememting classes (1.69 KB, patch)
2010-09-25 17:52 EDT, Marc-André Laperle CLA
no flags Details | Diff
Hide non-implementing leave nodes (7.29 KB, patch)
2010-09-28 05:00 EDT, Markus Schorn CLA
mschorn.eclipse: iplog-
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Marc-André Laperle CLA 2010-09-17 12:35:16 EDT
When using quick type hierarchy on big hierarchies that only have some classes implementing/overriding the method of interest, it will display a lot of "grey" nodes of non implementing classes making it tedious to navigate. I suggest adding an option to hide the branches that do not contain any implementing classes.

Small example:

Class1
   Class2 (green)
   Class3 (grey, hide it)
      Class4 (grey, hide it)
   Class5 (grey, hide it)
   Class6 (grey, don't hide it because of Class7)
      Class7 (green)
Comment 1 Marc-André Laperle CLA 2010-09-25 17:45:23 EDT
Created attachment 179577 [details]
Hide non implememting classes

This patch removes the nodes of non implementing classes. I'm not sure it's worth it to add an option for this. Any opinion?
Comment 2 Marc-André Laperle CLA 2010-09-25 17:47:55 EDT
Created attachment 179578 [details]
Test project
Comment 3 Marc-André Laperle CLA 2010-09-25 17:52:20 EDT
Created attachment 179579 [details]
Hide non implememting classes
Comment 4 Markus Schorn CLA 2010-09-28 04:41:26 EDT
(In reply to comment #1)
> Created an attachment (id=179577) [details]
> Hide non implememting classes
> This patch removes the nodes of non implementing classes. I'm not sure it's
> worth it to add an option for this. Any opinion?

I don't think we need the option.
Comment 5 Markus Schorn CLA 2010-09-28 05:00:10 EDT
Created attachment 179721 [details]
Hide non-implementing leave nodes

I have replaced your patch for the following reasons:
* Your patch is incomplete (misses some change to THNode). 
* The model is used for both the type-hierarchy view and the quick type hierarchy. In the view, the non-implementors must not be removed. 
* I think the non-implementing leaves should be shown in the super-type hierarchy, which will be availabe with the implementation of bug 325488.
Comment 6 Markus Schorn CLA 2010-09-28 05:17:42 EDT
Fixed in 8.0 > 20100928.
Comment 8 Marc-André Laperle CLA 2010-09-29 00:09:21 EDT
Thanks a lot Markus!