I need to reference the Part
object that created an SWT element. The Part
is creating a Label
in Part
's @PostConstruct
like that (e4):
public class SomePart {
@PostConstruct
public void postConstruct(Composite parent) {
...
Label someLabel = new Label(parent);
...
}
}
Need to get part that created someLabel
like this:
(SomePart) someLabel.getMyParentPartPlease()
Also need to get such reference in RCP 3.x, but I will be realy happy to get help on any RCP version.