Search in sources :

Example 6 with EntityEditDomain

use of org.whole.lang.ui.viewers.EntityEditDomain in project whole by wholeplatform.

the class E4GraphicalViewer method linkEditDomain.

public LightweightEditDomain linkEditDomain(IEntityPartViewer viewer) {
    EntityEditDomain editDomain = getEditDomain();
    if (editDomain != null)
        editDomain.removeViewer(this);
    editDomain = viewer.getEditDomain();
    editDomain.addViewer(this);
    return editDomain;
}
Also used : EntityEditDomain(org.whole.lang.ui.viewers.EntityEditDomain)

Example 7 with EntityEditDomain

use of org.whole.lang.ui.viewers.EntityEditDomain in project whole by wholeplatform.

the class FramesChangeEventHandler method resfreshNotation.

public void resfreshNotation(final IEntity source) {
    EntityEditDomain editDomain = context.get(IEntityPartViewer.class).getEditDomain();
    if (editDomain.isDisabled() || !isVariabilityDescendant(source))
        return;
    UISynchronize uiSynchronize = context.get(UISynchronize.class);
    uiSynchronize.syncExec(() -> editDomain.setDisabled(true));
    FramesUtils.updateSubset(source);
    uiSynchronize.asyncExec(() -> editDomain.setDisabled(false));
}
Also used : EntityEditDomain(org.whole.lang.ui.viewers.EntityEditDomain) IEntityPartViewer(org.whole.lang.ui.viewers.IEntityPartViewer) UISynchronize(org.eclipse.e4.ui.di.UISynchronize)

Aggregations

EntityEditDomain (org.whole.lang.ui.viewers.EntityEditDomain)7 IEntityPartViewer (org.whole.lang.ui.viewers.IEntityPartViewer)3 UISynchronize (org.eclipse.e4.ui.di.UISynchronize)2 PostConstruct (javax.annotation.PostConstruct)1 IPartFocusListener (org.whole.lang.ui.editparts.IPartFocusListener)1 WholeEditPartFactory (org.whole.lang.ui.editparts.WholeEditPartFactory)1 IModelInputListener (org.whole.lang.ui.input.IModelInputListener)1