Eclipse E4 - UIEvents Mpart Closure/Opening

Eclipse E4 - UIEvents Mpart Closure/Opening

有人知道是否有跟踪 MPart closure/opening 的 UIEvents 吗?

顺便说一句,我不需要@PreDestroy 方法。我有一些要在 MPart class.

之外执行的操作

谢谢

而不是 UIEvents 使用 EPartService IPartListener:

@Inject
EPartService partService;


partService.addPartListener(listener);

IPartListener 包含对部件进行所有重大更改的方法。

注意:这是org.eclipse.e4.ui.workbench.modeling.IPartListener不是org.eclipse.ui.IPartListener