cleanup
authorAndreas Müller <a.mueller@bgbm.org>
Tue, 30 Jun 2020 12:50:28 +0000 (14:50 +0200)
committerAndreas Müller <a.mueller@bgbm.org>
Tue, 30 Jun 2020 12:50:28 +0000 (14:50 +0200)
eu.etaxonomy.taxeditor.editor/src/main/java/eu/etaxonomy/taxeditor/editor/name/operation/CreateNewTaxonBaseOperation.java
eu.etaxonomy.taxeditor.store/src/main/java/eu/etaxonomy/taxeditor/view/sessions/InspectSessionsDialog.java

index 22ffbc1..9e6038c 100755 (executable)
@@ -16,45 +16,30 @@ import eu.etaxonomy.cdm.model.common.CdmBase;
 import eu.etaxonomy.cdm.model.name.TaxonName;
 import eu.etaxonomy.cdm.model.taxon.Synonym;
 import eu.etaxonomy.cdm.model.taxon.Taxon;
-import eu.etaxonomy.taxeditor.editor.EditorUtil;
 import eu.etaxonomy.taxeditor.editor.name.e4.TaxonNameEditorE4;
+import eu.etaxonomy.taxeditor.model.AbstractUtility;
 import eu.etaxonomy.taxeditor.operation.AbstractPostTaxonOperation;
 import eu.etaxonomy.taxeditor.operation.IPostOperationEnabled;
 
 /**
  * @author k.luther
  * @since 02.05.2018
- *
  */
 public abstract class CreateNewTaxonBaseOperation extends AbstractPostTaxonOperation {
 
-    /**
-     * @param label
-     * @param undoContext
-     * @param taxonUuid
-     */
     public CreateNewTaxonBaseOperation(String label, IUndoContext undoContext, UUID taxonUuid) {
         super(label, undoContext, taxonUuid);
 
     }
 
-    /**
-     * @param label
-     * @param undoContext
-     * @param taxon
-     * @param postOperationEnabled
-     */
     public CreateNewTaxonBaseOperation(String label, IUndoContext undoContext, Taxon taxon,
             IPostOperationEnabled postOperationEnabled) {
         super(label, undoContext, taxon, postOperationEnabled);
     }
 
-    /**
-     * @param newTaxonBase
-     */
     protected void addToSaveList(CdmBase newCdmBase) {
         TaxonNameEditorE4 editor = null;
-        Object activePart = EditorUtil.getActivePart();
+        Object activePart = AbstractUtility.getActivePart();
         if (activePart instanceof TaxonNameEditorE4){
            editor = (TaxonNameEditorE4) activePart;
            if (newCdmBase instanceof Synonym){
@@ -67,5 +52,4 @@ public abstract class CreateNewTaxonBaseOperation extends AbstractPostTaxonOpera
            editor.setDirty();
         }
     }
-
 }
index 316002d..ee26362 100644 (file)
@@ -157,54 +157,31 @@ public class InspectSessionsDialog extends Dialog {
 
     class SessionsTreeContentProvider implements ITreeContentProvider {
 
-
-
-        /* (non-Javadoc)
-         * @see org.eclipse.jface.viewers.IContentProvider#dispose()
-         */
         @Override
         public void dispose() {
 
         }
 
-        /* (non-Javadoc)
-         * @see org.eclipse.jface.viewers.IContentProvider#inputChanged(org.eclipse.jface.viewers.Viewer, java.lang.Object, java.lang.Object)
-         */
         @Override
-        public void inputChanged(Viewer viewer, Object oldInput, Object newInput) {
-
-
-        }
+        public void inputChanged(Viewer viewer, Object oldInput, Object newInput) {}
 
-        /* (non-Javadoc)
-         * @see org.eclipse.jface.viewers.ITreeContentProvider#getElements(java.lang.Object)
-         */
         @Override
         public Object[] getElements(Object inputElement) {
             return (CdmEntityInfo[])inputElement;
         }
 
-        /* (non-Javadoc)
-         * @see org.eclipse.jface.viewers.ITreeContentProvider#getChildren(java.lang.Object)
-         */
         @Override
         public Object[] getChildren(Object parentElement) {
             List<CdmEntityInfo> children = ((CdmEntityInfo)parentElement).getChildren();
             return children.toArray();
         }
 
-        /* (non-Javadoc)
-         * @see org.eclipse.jface.viewers.ITreeContentProvider#getParent(java.lang.Object)
-         */
         @Override
         public Object getParent(Object element) {
             CdmEntityInfo cei = (CdmEntityInfo)element;
             return cei.getParent();
         }
 
-        /* (non-Javadoc)
-         * @see org.eclipse.jface.viewers.ITreeContentProvider#hasChildren(java.lang.Object)
-         */
         @Override
         public boolean hasChildren(Object element) {
             List<CdmEntityInfo> children = ((CdmEntityInfo)element).getChildren();
@@ -223,7 +200,6 @@ public class InspectSessionsDialog extends Dialog {
                 return (CdmModelFieldPropertyFromClass) e.getObjectValue();
             }
         }
-
     }
 
     class SessionsTreeLabelProvider extends StyledCellLabelProvider implements ILabelProvider {
@@ -240,24 +216,16 @@ public class InspectSessionsDialog extends Dialog {
             super.update(cell);
         }
 
-        /* (non-Javadoc)
-         * @see org.eclipse.jface.viewers.ILabelProvider#getImage(java.lang.Object)
-         */
         @Override
         public Image getImage(Object element) {
             // TODO Auto-generated method stub
             return null;
         }
 
-        /* (non-Javadoc)
-         * @see org.eclipse.jface.viewers.ILabelProvider#getText(java.lang.Object)
-         */
         @Override
         public String getText(Object element) {
             CdmEntityInfo cei = (CdmEntityInfo)element;
             return cei.getLabel();
         }
     }
-}
-
-
+}
\ No newline at end of file