| Summary: | Enhance ISTDataViewersField with a new method, in order to support columns hideen by default | ||
|---|---|---|---|
| Product: | [Tools] Linux Tools | Reporter: | Xavier Raynaud <xraynaud> |
| Component: | GProf | Assignee: | Xavier Raynaud <xraynaud> |
| Status: | CLOSED FIXED | QA Contact: | Xavier Raynaud <xraynaud> |
| Severity: | enhancement | ||
| Priority: | P3 | CC: | akurtakov, jerome.correnoz, lilia.ghachem |
| Version: | unspecified | ||
| Target Milestone: | 2.0 | ||
| Hardware: | All | ||
| OS: | All | ||
| Whiteboard: | |||
|
Description
Xavier Raynaud
Jerome/Lilia: I opened this RFE for you. Are you OK for this enhancement ? Xavier (In reply to comment #1) > Jerome/Lilia: > > I opened this RFE for you. > Are you OK for this enhancement ? > > Xavier Absolutely OK for me. I needed such behavior in a recently implemented Debug view where I had to define for each column a constructor (AbstractSTDataViewersField) with boolean as a parameter for showing/not. Thanks Xavier! Hi Lilia, Ok, many thanks. I'm not sure to understand your comment. Do you have already implemented this feature ? Or is it only an identified requirement from your side ? Xavier Sorry if I was not clear.
Actually, it is a requirement I identified and which I implemented in my plugin not in dataviewers side. your solution sounds better.
Some code snippets in my current implementation:
public abstract class MyAbstractField extends AbstractSTDataViewersField {
public myAbstractField (boolean show) {
super();
setShowing(show);
}
[...]
}
public class myFieldx extends MyAbstractField {
public myFieldx (boolean b){
super(b);
}
[...]
}
public class myViewer extends AbstractSTTableViewer {
public ISTDataViewersField[] getAllFields() {
return new ISTDataViewersField[] {
new myField1(true);
new myField2(true);
new myField3(false);
new myField4(false);
}
}
thus, by default, the two last columns hidden.
I hope it is clearer now?
Lilia
a patch has been submitted here: https://git.eclipse.org/r/#/c/11672/ fixed by rev 444a56364afb015c59f7b73d52707913404f07ca |