[EMF Forms] Custom control get parent of an eStructuralFeature [message #1722675] |
Mon, 08 February 2016 03:55  |
Eclipse User |
|
|
|
Hi guys,
I have an Ecore model that has the following structure:
BoolEnum
-> TRUE
-> FALSE
BoolStringValue
value -> BoolEnum
DifferentType1
boolStringValue -> BoolStringValue
DifferentType2
boolStringValue -> BoolStringValue
In my new custom control I want to be able to render differently the value combobox (from BoolStringValue). But how can I know its parent, from where it comes from (DifferentType1/DifferentType2)?
This is the skeleton for isApplicable method:
.... isApplicable(){
if (eStructuralFeature.getName().equals("value") && eStructuralFeature.getEContainingClass() == (EClass) pack.getEClassifier("BoolStringValue") && (condition??) )
{
return 10;
}
And which SWT control renderer should apply here to create the control? Should I use a BooleanControlSWTRenderer?
Thank you very much,
S.
|
|
|
|
|
|
|
Powered by
FUDForum. Page generated in 0.10436 seconds