import org.eclipse.ui.PartInitException;
import org.eclipse.ui.forms.editor.FormEditor;
+import eu.etaxonomy.cdm.api.application.CdmApplicationState;
+import eu.etaxonomy.cdm.api.application.CdmChangeEvent;
+import eu.etaxonomy.cdm.api.application.CdmChangeEvent.Action;
import eu.etaxonomy.cdm.api.conversation.ConversationHolder;
import eu.etaxonomy.cdm.api.conversation.IConversationEnabled;
import eu.etaxonomy.cdm.model.common.CdmBase;
// commit the conversation and start a new transaction immediately
input.merge();
+
conversation.commit(true);
+ CdmApplicationState.getCurrentDataChangeService()
+ .fireChangeEvent(new CdmChangeEvent(Action.Update, input.getTaxonNode() , MultiPageTaxonEditor.class), true);
monitor.worked(1);
this.setDirty(false);
@Override
public void changed(Object element) {
// setDirty(true);
- dirty = true;
- super.editorDirtyStateChanged();
+ // if the attribute is null then do not set the dirty flag -> hotfix for the problem that for tasks done in service methods the changes are saved automatically
+ if (element != null){
+ dirty = true;
+ super.editorDirtyStateChanged();
+ }
+
if (element instanceof TaxonBase) {
TaxonNameEditor page = (TaxonNameEditor) getPage(Page.NAME);
AbstractGroupedContainer container = page.getContainer((TaxonBase) element);
return true;
}
+ /* (non-Javadoc)
+ * @see eu.etaxonomy.taxeditor.model.IPartContentHasMedia#canAttachMedia()
+ */
+ @Override
+ public boolean canAttachMedia() {
+ return true;
+ }
+
}