use of org.whole.lang.ui.editpolicies.SuspensionFeedbackEditPolicy in project whole by wholeplatform.
the class E4DebugGraphicalPart method updateUI.
protected void updateUI() {
updateActions();
IEventBroker eventBroker = context.get(IEventBroker.class);
ExecutionState execution = executions.peek();
if (execution != null) {
final IEntity sourceEntity = execution.getSourceEntity();
IEntity contents = EntityUtils.getCompoundRoot(sourceEntity);
getViewer().setContents(contents);
getViewer().setInteractive(contents, false, true, false);
context.get(UISynchronize.class).asyncExec(new Runnable() {
@Override
public void run() {
IEntity adaptee = sourceEntity.wGetAdaptee(false);
IEntityPart sourceEntityPart = getViewer().getEditPartRegistry().get(adaptee);
sourceEntityPart.installEditPolicy(SuspensionFeedbackEditPolicy.SUSPENSION_FEEDBACK_ROLE, new SuspensionFeedbackEditPolicy(getSuspensionKind(), execution.getThrowable()));
getViewer().reveal(sourceEntity);
}
});
eventBroker.post(IE4UIConstants.TOPIC_UPDATE_VARIABLES, execution.getVariablesModel());
} else {
getViewer().setEntityContents(createDefaultContents());
eventBroker.post(IE4UIConstants.TOPIC_UPDATE_VARIABLES, null);
}
}
Aggregations