import eu.etaxonomy.taxeditor.editor.name.e4.dnd.NameEditorDragListenerE4;
import eu.etaxonomy.taxeditor.editor.name.e4.dnd.NameEditorDragSourceEffect;
import eu.etaxonomy.taxeditor.editor.name.operation.CreateSynonymInNewGroupOperation;
+import eu.etaxonomy.taxeditor.event.EventUtility;
+import eu.etaxonomy.taxeditor.event.WorkbenchEventConstants;
import eu.etaxonomy.taxeditor.model.AbstractUtility;
import eu.etaxonomy.taxeditor.model.IElementHasDetails;
import eu.etaxonomy.taxeditor.model.NameHelper;
public void focusLost(FocusEvent e) {
super.focusLost(e);
persistName();
-// EventUtility.postAsyncEvent(WorkbenchEventConstants.REFRESH_DETAILS, true);
+ EventUtility.postAsyncEvent(WorkbenchEventConstants.REFRESH_DETAILS, true);
}
};
import org.eclipse.e4.core.contexts.ContextInjectionFactory;
import org.eclipse.e4.core.contexts.IEclipseContext;
import org.eclipse.e4.ui.model.application.ui.basic.MPart;
+import org.eclipse.jface.viewers.ISelection;
import org.eclipse.jface.viewers.IStructuredSelection;
import org.eclipse.jface.viewers.StructuredSelection;
+import org.eclipse.jface.viewers.TreeSelection;
+import org.eclipse.jface.viewers.TreeViewer;
import org.eclipse.swt.SWTException;
import org.eclipse.swt.widgets.Composite;
if (activePart == thisPart){
return;
}
+
+
Object partObject = getPartObject(activePart);
if (partObject instanceof SupplementalDataPartE4 ) {
// do not show empty page
return;
}
+
+ if (partObject instanceof AbstractCdmEditorPart && ((AbstractCdmEditorPart)partObject).getViewer() instanceof TreeViewer ) {
+ //active part is factual data view or media view
+ IStructuredSelection structuredSelection = createSelection(selection);
+ if (structuredSelection != null && !structuredSelection.isEmpty()) {
+ //if the active part is empty the selection is still the previous selection
+ if (!(structuredSelection instanceof TreeSelection)) {
+ return;
+ }
+ }
+
+ }
if(partObject instanceof IPartContentHasDetails){
IStructuredSelection structuredSelection = createSelection(selection);