use of org.eclipse.emf.eef.runtime.impl.operation.WizardEditingOperation in project InformationSystem by ObeoNetwork.
the class CustomEditingPolicy method execute.
/**
* (non-Javadoc)
*
* @see org.eclipse.emf.eef.runtime.policies.PropertiesEditingPolicy#execute()
*/
@Override
public void execute() {
EditingDomain editingDomain = EEFUtils.getEditingDomain(editionContext);
if (editingDomain != null) {
DomainPropertiesEditionContext domainPropertiesEditionContext = new DomainPropertiesEditionContext(null, null, editingDomain, editionContext.getAdapterFactory(), editionContext.getEObject());
WizardEditingOperation operation = new WizardEditingOperation(domainPropertiesEditionContext);
try {
operation.execute(new NullProgressMonitor(), null);
} catch (ExecutionException e) {
EEFRuntimePlugin.getDefault().logError("An error occured during wizard editing.", e);
}
} else {
super.execute();
}
}
use of org.eclipse.emf.eef.runtime.impl.operation.WizardEditingOperation in project InformationSystem by ObeoNetwork.
the class CustomEditingPolicy method execute.
/**
* (non-Javadoc)
*
* @see org.eclipse.emf.eef.runtime.policies.PropertiesEditingPolicy#execute()
*/
@Override
public void execute() {
EditingDomain editingDomain = EEFUtils.getEditingDomain(editionContext);
if (editingDomain != null) {
DomainPropertiesEditionContext domainPropertiesEditionContext = new DomainPropertiesEditionContext(null, null, editingDomain, editionContext.getAdapterFactory(), editionContext.getEObject());
WizardEditingOperation operation = new WizardEditingOperation(domainPropertiesEditionContext);
try {
operation.execute(new NullProgressMonitor(), null);
} catch (ExecutionException e) {
EEFRuntimePlugin.getDefault().logError("An error occured during wizard editing.", e);
}
} else {
super.execute();
}
}
use of org.eclipse.emf.eef.runtime.impl.operation.WizardEditingOperation in project InformationSystem by ObeoNetwork.
the class EditRequirementAction method run.
/**
* {@inheritDoc}
*
* @see org.eclipse.jface.action.Action#run()
*/
@Override
public void run() {
RequirementLink eObjectLink = (RequirementLink) linksView.getSelectedEntries().get(0);
TransactionalEditingDomain editingDomain = TransactionUtil.getEditingDomain(linksView.getInput());
DomainPropertiesEditionContext propertiesEditionContext = new DomainPropertiesEditionContext(null, null, editingDomain, linksView.getAdapterFactory(), eObjectLink.getRequirement());
WizardEditingOperation operation = new RequirementEditingOperation(propertiesEditionContext);
try {
operation.execute(new NullProgressMonitor(), null);
linksView.refresh();
} catch (ExecutionException e) {
// $NON-NLS-1$
EEFRuntimePlugin.getDefault().logError("An error occured during wizard editing.", e);
}
}
use of org.eclipse.emf.eef.runtime.impl.operation.WizardEditingOperation in project InformationSystem by ObeoNetwork.
the class LinkedRequirementsView method createDoubleClickAction.
/**
* {@inheritDoc}
*
* @see org.obeonetwork.tools.linker.ui.view.EObjectLinksView#createDoubleClickAction()
*/
@Override
protected Action createDoubleClickAction() {
return new Action() {
/**
* {@inheritDoc}
*
* @see org.eclipse.jface.action.Action#run()
*/
@Override
public void run() {
if (getSelectedEntries().size() > 0) {
RequirementLink eObjectLink = (RequirementLink) getSelectedEntries().get(0);
TransactionalEditingDomain editingDomain = TransactionUtil.getEditingDomain(getInput());
DomainPropertiesEditionContext propertiesEditionContext = new DomainPropertiesEditionContext(null, null, editingDomain, adapterFactory, eObjectLink.getRequirement());
WizardEditingOperation operation = new RequirementEditingOperation(propertiesEditionContext);
try {
operation.execute(new NullProgressMonitor(), null);
refresh();
} catch (ExecutionException e) {
// $NON-NLS-1$
EEFRuntimePlugin.getDefault().logError("An error occured during wizard editing.", e);
}
}
}
};
}
use of org.eclipse.emf.eef.runtime.impl.operation.WizardEditingOperation in project InformationSystem by ObeoNetwork.
the class CustomEditingPolicy method execute.
/**
* (non-Javadoc)
*
* @see org.eclipse.emf.eef.runtime.policies.PropertiesEditingPolicy#execute()
*/
@Override
public void execute() {
EditingDomain editingDomain = EEFUtils.getEditingDomain(editionContext);
if (editingDomain != null) {
DomainPropertiesEditionContext domainPropertiesEditionContext = new DomainPropertiesEditionContext(null, null, editingDomain, editionContext.getAdapterFactory(), editionContext.getEObject());
WizardEditingOperation operation = new WizardEditingOperation(domainPropertiesEditionContext);
try {
operation.execute(new NullProgressMonitor(), null);
} catch (ExecutionException e) {
EEFRuntimePlugin.getDefault().logError("An error occured during wizard editing.", e);
}
} else {
super.execute();
}
}
Aggregations