Fixes #2360
authorn.hoffmann <n.hoffmann@localhost>
Wed, 4 May 2011 14:31:34 +0000 (14:31 +0000)
committern.hoffmann <n.hoffmann@localhost>
Wed, 4 May 2011 14:31:34 +0000 (14:31 +0000)
.gitattributes
eu.etaxonomy.taxeditor.store/src/main/java/eu/etaxonomy/taxeditor/ui/section/occurrence/CollectionWizardPage.java
eu.etaxonomy.taxeditor.store/src/main/java/eu/etaxonomy/taxeditor/ui/section/occurrence/DerivedUnitBaseWizardPage.java
eu.etaxonomy.taxeditor.store/src/main/java/eu/etaxonomy/taxeditor/ui/section/occurrence/DerivedUnitFacadeWizardPage.java [deleted file]
eu.etaxonomy.taxeditor.store/src/main/java/eu/etaxonomy/taxeditor/ui/section/occurrence/FieldObservationDetailElement.java
eu.etaxonomy.taxeditor.store/src/main/java/eu/etaxonomy/taxeditor/ui/section/occurrence/FieldObservationWizardPage.java
eu.etaxonomy.taxeditor.store/src/main/java/eu/etaxonomy/taxeditor/ui/section/occurrence/GatheringEventDetailElement.java
eu.etaxonomy.taxeditor.store/src/main/java/eu/etaxonomy/taxeditor/ui/section/occurrence/GatheringEventWizardPage.java
eu.etaxonomy.taxeditor.store/src/main/java/eu/etaxonomy/taxeditor/ui/section/occurrence/GeneralDetailElement.java
eu.etaxonomy.taxeditor.store/src/main/java/eu/etaxonomy/taxeditor/ui/section/occurrence/GeneralWizardPage.java

index 2fd4eb49f6581f434b24e6e52bc16330eab1f496..9e3fd077d091d30774bd2530cadd040070ff080e 100644 (file)
@@ -1045,7 +1045,6 @@ eu.etaxonomy.taxeditor.store/src/main/java/eu/etaxonomy/taxeditor/ui/section/occ
 eu.etaxonomy.taxeditor.store/src/main/java/eu/etaxonomy/taxeditor/ui/section/occurrence/DerivedUnitBaseWizardPage.java -text
 eu.etaxonomy.taxeditor.store/src/main/java/eu/etaxonomy/taxeditor/ui/section/occurrence/DerivedUnitFacadeDetailElement.java -text
 eu.etaxonomy.taxeditor.store/src/main/java/eu/etaxonomy/taxeditor/ui/section/occurrence/DerivedUnitFacadeDetailSection.java -text
-eu.etaxonomy.taxeditor.store/src/main/java/eu/etaxonomy/taxeditor/ui/section/occurrence/DerivedUnitFacadeWizardPage.java -text
 eu.etaxonomy.taxeditor.store/src/main/java/eu/etaxonomy/taxeditor/ui/section/occurrence/DeterminationEventDetailElement.java -text
 eu.etaxonomy.taxeditor.store/src/main/java/eu/etaxonomy/taxeditor/ui/section/occurrence/DeterminationEventDetailSection.java -text
 eu.etaxonomy.taxeditor.store/src/main/java/eu/etaxonomy/taxeditor/ui/section/occurrence/FieldObservationDetailElement.java -text
index 676507a0b7846e37af1a1a7443e891350cf01977..b3408ba516975ecd901a653520eab68de15887bb 100644 (file)
@@ -16,8 +16,8 @@ import eu.etaxonomy.cdm.api.conversation.ConversationHolder;
 import eu.etaxonomy.cdm.model.occurrence.Collection;
 import eu.etaxonomy.taxeditor.ui.forms.AbstractCdmEntityWizardPage;
 import eu.etaxonomy.taxeditor.ui.forms.CdmFormFactory;
-import eu.etaxonomy.taxeditor.ui.forms.ICdmFormElement;
 import eu.etaxonomy.taxeditor.ui.forms.CdmFormFactory.DetailType;
+import eu.etaxonomy.taxeditor.ui.forms.ICdmFormElement;
 import eu.etaxonomy.taxeditor.ui.section.AbstractCdmDetailElement;
 
 /**
@@ -39,8 +39,17 @@ public class CollectionWizardPage extends AbstractCdmEntityWizardPage<Collection
        public CollectionWizardPage(CdmFormFactory formFactory,
                        ConversationHolder conversation, Collection entity) {
                super(formFactory, conversation, entity);
+               setPageComplete(true);
        }
 
+       /* (non-Javadoc)
+        * @see eu.etaxonomy.taxeditor.ui.forms.AbstractCdmEntityWizardPage#checkComplete()
+        */
+       @Override
+       protected void checkComplete() {
+               setPageComplete(true);
+       }
+       
        /* (non-Javadoc)
         * @see eu.etaxonomy.taxeditor.forms.AbstractCdmEntityWizardPage#createElement(eu.etaxonomy.taxeditor.forms.ICdmFormElement)
         */
index 7bc85b998e2ee51e1a635234774a040afe2e119a..b9470a610997115e41eb28e740ec783d1a5ceba7 100644 (file)
@@ -16,8 +16,8 @@ import eu.etaxonomy.cdm.api.conversation.ConversationHolder;
 import eu.etaxonomy.cdm.api.facade.DerivedUnitFacade;
 import eu.etaxonomy.taxeditor.ui.forms.AbstractCdmEntityWizardPage;
 import eu.etaxonomy.taxeditor.ui.forms.CdmFormFactory;
-import eu.etaxonomy.taxeditor.ui.forms.ICdmFormElement;
 import eu.etaxonomy.taxeditor.ui.forms.CdmFormFactory.DetailType;
+import eu.etaxonomy.taxeditor.ui.forms.ICdmFormElement;
 import eu.etaxonomy.taxeditor.ui.section.AbstractCdmDetailElement;
 
 /**
@@ -36,8 +36,17 @@ public class DerivedUnitBaseWizardPage extends AbstractCdmEntityWizardPage<Deriv
                        ConversationHolder conversation, DerivedUnitFacade entity) {
                super(formFactory, conversation, entity);
                setTitle("Derived Unit Details");
+               setPageComplete(true);
        }
 
+       /* (non-Javadoc)
+        * @see eu.etaxonomy.taxeditor.ui.forms.AbstractCdmEntityWizardPage#checkComplete()
+        */
+       @Override
+       protected void checkComplete() {
+               setPageComplete(true);
+       }
+       
        /* (non-Javadoc)
         * @see eu.etaxonomy.taxeditor.forms.AbstractCdmEntityWizardPage#createElement(eu.etaxonomy.taxeditor.forms.ICdmFormElement)
         */
diff --git a/eu.etaxonomy.taxeditor.store/src/main/java/eu/etaxonomy/taxeditor/ui/section/occurrence/DerivedUnitFacadeWizardPage.java b/eu.etaxonomy.taxeditor.store/src/main/java/eu/etaxonomy/taxeditor/ui/section/occurrence/DerivedUnitFacadeWizardPage.java
deleted file mode 100644 (file)
index a0313aa..0000000
+++ /dev/null
@@ -1,55 +0,0 @@
-// $Id$
-/**
-* Copyright (C) 2007 EDIT
-* European Distributed Institute of Taxonomy 
-* http://www.e-taxonomy.eu
-* 
-* The contents of this file are subject to the Mozilla Public License Version 1.1
-* See LICENSE.TXT at the top of this package for the full license terms.
-*/
-
-package eu.etaxonomy.taxeditor.ui.section.occurrence;
-
-import org.eclipse.swt.SWT;
-
-import eu.etaxonomy.cdm.api.conversation.ConversationHolder;
-import eu.etaxonomy.cdm.model.occurrence.DerivedUnitBase;
-import eu.etaxonomy.taxeditor.ui.forms.AbstractCdmEntityWizardPage;
-import eu.etaxonomy.taxeditor.ui.forms.CdmFormFactory;
-import eu.etaxonomy.taxeditor.ui.forms.ICdmFormElement;
-import eu.etaxonomy.taxeditor.ui.forms.CdmFormFactory.DetailType;
-import eu.etaxonomy.taxeditor.ui.section.AbstractCdmDetailElement;
-
-/**
- * <p>DerivedUnitFacadeWizardPage class.</p>
- *
- * @author n.hoffmann
- * @created Jun 16, 2010
- * @version 1.0
- */
-@Deprecated // use the specific pages instead (e.g. GeneralWizardPage, GatheringEventPage, s.o.)
-public class DerivedUnitFacadeWizardPage extends AbstractCdmEntityWizardPage<DerivedUnitBase> {
-
-       /**
-        * <p>Constructor for DerivedUnitFacadeWizardPage.</p>
-        *
-        * @param formFactory a {@link eu.etaxonomy.taxeditor.ui.forms.CdmFormFactory} object.
-        * @param conversation a {@link eu.etaxonomy.cdm.api.conversation.ConversationHolder} object.
-        * @param entity a {@link eu.etaxonomy.cdm.model.occurrence.DerivedUnitBase} object.
-        */
-       public DerivedUnitFacadeWizardPage(CdmFormFactory formFactory, ConversationHolder conversation, DerivedUnitBase entity) {
-               super(formFactory, conversation, entity);
-               setTitle("Derived Unit");
-       }
-       
-       /* (non-Javadoc)
-        * @see eu.etaxonomy.taxeditor.forms.AbstractCdmEntityWizardPage#createElement(eu.etaxonomy.taxeditor.forms.ICdmFormElement)
-        */
-       /** {@inheritDoc} */
-       @Override
-       public AbstractCdmDetailElement createElement(ICdmFormElement rootElement) {
-               DerivedUnitFacadeDetailElement derivedUnitFacadeDetailElement = (DerivedUnitFacadeDetailElement) formFactory.createCdmDetailElement(DetailType.DERIVED_UNIT_FACADE, rootElement, SWT.NULL);
-               derivedUnitFacadeDetailElement.setEntity(entity);
-               return derivedUnitFacadeDetailElement;
-       }
-}
index ab8cd328e2426f83239abf01626e725d088ac8df..cbf150ff11fb645d87214617df0e6b73156d6664 100644 (file)
@@ -14,6 +14,7 @@ import eu.etaxonomy.cdm.api.facade.DerivedUnitFacade;
 import eu.etaxonomy.taxeditor.store.CdmStore;
 import eu.etaxonomy.taxeditor.ui.forms.CdmFormFactory;
 import eu.etaxonomy.taxeditor.ui.forms.CdmFormFactory.TermComboType;
+import eu.etaxonomy.taxeditor.ui.forms.CdmPropertyChangeEvent;
 import eu.etaxonomy.taxeditor.ui.forms.ICdmFormElement;
 import eu.etaxonomy.taxeditor.ui.forms.NumberWithLabelElement;
 import eu.etaxonomy.taxeditor.ui.forms.TextWithLabelElement;
@@ -54,7 +55,7 @@ public class FieldObservationDetailElement extends AbstractCdmDetailElement<Deri
                        ICdmFormElement formElement) {
                super(formFactory, formElement);
        }
-       
+               
        /** {@inheritDoc} */
        @Override
        protected void createControls(ICdmFormElement formElement,
@@ -94,5 +95,6 @@ public class FieldObservationDetailElement extends AbstractCdmDetailElement<Deri
                else if(eventSource == combo_sex){
                        getEntity().setSex(combo_sex.getSelection());
                }
+               firePropertyChangeEvent(new CdmPropertyChangeEvent(this, null));
        }
 }
index d9d1fcadf1997248e3df2b8f74bedde60e243d44..8b9ee4e97ff5361a08ea83a4a8ccfa2994723278 100644 (file)
@@ -16,8 +16,8 @@ import eu.etaxonomy.cdm.api.conversation.ConversationHolder;
 import eu.etaxonomy.cdm.api.facade.DerivedUnitFacade;
 import eu.etaxonomy.taxeditor.ui.forms.AbstractCdmEntityWizardPage;
 import eu.etaxonomy.taxeditor.ui.forms.CdmFormFactory;
-import eu.etaxonomy.taxeditor.ui.forms.ICdmFormElement;
 import eu.etaxonomy.taxeditor.ui.forms.CdmFormFactory.DetailType;
+import eu.etaxonomy.taxeditor.ui.forms.ICdmFormElement;
 import eu.etaxonomy.taxeditor.ui.section.AbstractCdmDetailElement;
 
 /**
@@ -36,8 +36,17 @@ public class FieldObservationWizardPage extends AbstractCdmEntityWizardPage<Deri
                        ConversationHolder conversation, DerivedUnitFacade entity) {
                super(formFactory, conversation, entity);
                setTitle("Field Observation Details");
+               setPageComplete(true);
        }
 
+       /* (non-Javadoc)
+        * @see eu.etaxonomy.taxeditor.ui.forms.AbstractCdmEntityWizardPage#checkComplete()
+        */
+       @Override
+       protected void checkComplete() {
+               setPageComplete(true);
+       }
+       
        /* (non-Javadoc)
         * @see eu.etaxonomy.taxeditor.forms.AbstractCdmEntityWizardPage#createElement(eu.etaxonomy.taxeditor.forms.ICdmFormElement)
         */
index 34ac3a9777a7d4923b6d7647c764cf71054cd788..73a01940ba71b3e9b0ffe6cc0f32593083a36e0a 100644 (file)
@@ -17,6 +17,7 @@ import eu.etaxonomy.taxeditor.preference.Resources;
 import eu.etaxonomy.taxeditor.store.StoreUtil;
 import eu.etaxonomy.taxeditor.ui.forms.CdmFormFactory;
 import eu.etaxonomy.taxeditor.ui.forms.CdmFormFactory.EntityDetailType;
+import eu.etaxonomy.taxeditor.ui.forms.CdmPropertyChangeEvent;
 import eu.etaxonomy.taxeditor.ui.forms.ICdmFormElement;
 import eu.etaxonomy.taxeditor.ui.forms.NumberWithLabelElement;
 import eu.etaxonomy.taxeditor.ui.forms.TextWithLabelElement;
@@ -153,5 +154,6 @@ public class GatheringEventDetailElement extends
                        getEntity().setGatheringEventDescription(
                                        text_gatheringEventDescription.getText());
                }
+               firePropertyChangeEvent(new CdmPropertyChangeEvent(this, null));
        }
 }
index 6c493ecb1c5978e82a5715752f463e9d651b1a3c..71a5a86e0ea18c4becf2b99ff02b9d27334c3b52 100644 (file)
@@ -16,8 +16,8 @@ import eu.etaxonomy.cdm.api.conversation.ConversationHolder;
 import eu.etaxonomy.cdm.api.facade.DerivedUnitFacade;
 import eu.etaxonomy.taxeditor.ui.forms.AbstractCdmEntityWizardPage;
 import eu.etaxonomy.taxeditor.ui.forms.CdmFormFactory;
-import eu.etaxonomy.taxeditor.ui.forms.ICdmFormElement;
 import eu.etaxonomy.taxeditor.ui.forms.CdmFormFactory.DetailType;
+import eu.etaxonomy.taxeditor.ui.forms.ICdmFormElement;
 import eu.etaxonomy.taxeditor.ui.section.AbstractCdmDetailElement;
 
 /**
@@ -36,8 +36,17 @@ public class GatheringEventWizardPage extends AbstractCdmEntityWizardPage<Derive
                        ConversationHolder conversation, DerivedUnitFacade entity) {
                super(formFactory, conversation, entity);
                setTitle("Gathering Event Details");
+               setPageComplete(true);
        }
 
+       /* (non-Javadoc)
+        * @see eu.etaxonomy.taxeditor.ui.forms.AbstractCdmEntityWizardPage#checkComplete()
+        */
+       @Override
+       protected void checkComplete() {
+               setPageComplete(true);
+       }
+       
        /* (non-Javadoc)
         * @see eu.etaxonomy.taxeditor.forms.AbstractCdmEntityWizardPage#createElement(eu.etaxonomy.taxeditor.forms.ICdmFormElement)
         */
index f358256bdb59cc78ef1ad0809dc3c64c66e3761a..54c84b9e1b3f59a8d6896eea38c392a442cfcce8 100644 (file)
@@ -13,6 +13,7 @@ package eu.etaxonomy.taxeditor.ui.section.occurrence;
 import eu.etaxonomy.cdm.api.facade.DerivedUnitFacade;
 import eu.etaxonomy.taxeditor.ui.forms.CdmFormFactory;
 import eu.etaxonomy.taxeditor.ui.forms.CdmFormFactory.SelectionType;
+import eu.etaxonomy.taxeditor.ui.forms.CdmPropertyChangeEvent;
 import eu.etaxonomy.taxeditor.ui.forms.ICdmFormElement;
 import eu.etaxonomy.taxeditor.ui.forms.LanguageStringWithLabelElement;
 import eu.etaxonomy.taxeditor.ui.forms.NumberWithLabelElement;
@@ -132,6 +133,7 @@ public class GeneralDetailElement extends
                if (eventSource != toggleableText_titleCache) {
                        toggleableText_titleCache.setText(getEntity().getTitleCache());
                }
+               firePropertyChangeEvent(new CdmPropertyChangeEvent(this, null));
        }
 
 }
index f434bcf78fda5a3aea687123f4690f01b6da405b..c4a5299a8dbf88d5eeb843ff5e83b21efd417219 100644 (file)
@@ -16,8 +16,8 @@ import eu.etaxonomy.cdm.api.conversation.ConversationHolder;
 import eu.etaxonomy.cdm.api.facade.DerivedUnitFacade;
 import eu.etaxonomy.taxeditor.ui.forms.AbstractCdmEntityWizardPage;
 import eu.etaxonomy.taxeditor.ui.forms.CdmFormFactory;
-import eu.etaxonomy.taxeditor.ui.forms.ICdmFormElement;
 import eu.etaxonomy.taxeditor.ui.forms.CdmFormFactory.DetailType;
+import eu.etaxonomy.taxeditor.ui.forms.ICdmFormElement;
 import eu.etaxonomy.taxeditor.ui.section.AbstractCdmDetailElement;
 
 /**
@@ -38,6 +38,14 @@ public class GeneralWizardPage extends AbstractCdmEntityWizardPage<DerivedUnitFa
                setTitle("General Specimen Data");
        }
 
+       /* (non-Javadoc)
+        * @see eu.etaxonomy.taxeditor.ui.forms.AbstractCdmEntityWizardPage#checkComplete()
+        */
+       @Override
+       protected void checkComplete() {
+               setPageComplete(true);
+       }
+       
        /* (non-Javadoc)
         * @see eu.etaxonomy.taxeditor.forms.AbstractCdmEntityWizardPage#createElement(eu.etaxonomy.taxeditor.forms.ICdmFormElement)
         */