use of org.whole.lang.ui.viewers.EntityEditDomain in project whole by wholeplatform.
the class DerivedLinkableSelectionListener method updateLinkType.
@Override
public void updateLinkType(LinkType linkType) {
super.updateLinkType(linkType);
if (linkType.isNotLinked()) {
viewer.setEditDomain(new EntityEditDomain());
viewer.setEntityContents(EntityUtils.clone(viewer.getEntityContents()));
fireViewerUnlinked();
} else if (lastSelection != null)
updateViewerContents(true);
}
use of org.whole.lang.ui.viewers.EntityEditDomain in project whole by wholeplatform.
the class E4GraphicalViewer method initialize.
@PostConstruct
protected void initialize() {
if (domain == null)
domain = new EntityEditDomain();
partFocusListeners = new ArrayList<IPartFocusListener>();
modelInputListeners = new ArrayList<IModelInputListener>();
referencedResources = new HashSet<String>();
createControl2(parent);
domain.addViewer(this);
setEditPartFactory(new WholeEditPartFactory());
setRootEditPart(createRootEditPart());
configureViewer(domain);
}
use of org.whole.lang.ui.viewers.EntityEditDomain in project whole by wholeplatform.
the class E4TreeViewer method linkEditDomain.
public LightweightEditDomain linkEditDomain(IEntityPartViewer viewer) {
EntityEditDomain editDomain = getEditDomain();
if (editDomain != null)
editDomain.removeViewer(this);
editDomain = viewer.getEditDomain();
editDomain.addViewer(this);
return editDomain;
}
use of org.whole.lang.ui.viewers.EntityEditDomain in project whole by wholeplatform.
the class AbstractRunnableWithProgress method asyncExec.
public void asyncExec(String message) {
IEntityPartViewer viewer = (IEntityPartViewer) bm.wGetValue("viewer");
EntityEditDomain editDomain = viewer.getEditDomain();
if (isTransactional())
editDomain.setDisabled(true);
EntityEditDomainJob.asyncExec(message, editDomain, this);
}
use of org.whole.lang.ui.viewers.EntityEditDomain in project whole by wholeplatform.
the class AbstractRunnableWithProgress method syncExec.
public synchronized IBindingScope syncExec(long timeout) {
IEntityPartViewer viewer = (IEntityPartViewer) bm.wGetValue("viewer");
EntityEditDomain editDomain = viewer.getEditDomain();
UISynchronize uiSynchronize = context.get(UISynchronize.class);
try {
context.set(UISynchronize.class, NoUISynchronize.instance);
EntityEditDomainJob.syncExec("boh", editDomain, this);
} finally {
context.set(UISynchronize.class, uiSynchronize);
}
return bm;
}
Aggregations