Project

General

Profile

« Previous | Next » 

Revision 572814ac

Added by Andreas Müller about 6 years ago

cleanup

View differences:

eu.etaxonomy.taxeditor.navigation/src/main/java/eu/etaxonomy/taxeditor/navigation/l10n/messages_de.properties
119 119
SetSecundumForSubtreeOperation_CHANGE_SEC_OP=Secundum Referenz f?r alle Kinder ?ndern
120 120
SetSecundumForSubtreeOperation_SET_SEC_TASK=Secundum Referenz f?r Teilbaum setzen
121 121
SetSecundumForSubtreeHandler_CONFIG_DIALOG_TITLE=Setze Secundum Referenz f?r Teilbaum
122
SetPublishFlagForSubtreeOperation_SET_SEC_TASK=Publish Flag f?r Teilbaum setzenS
122
SetPublishFlagForSubtreeOperation_SET_SEC_TASK=Publish Flag f?r Teilbaum setzen
123 123
TaxonLinkHelper_CREATE_FAIL=Konnte Taxon nicht erstellen
124 124
TaxonNavigator_LOAD_DATASOURCE=Lade Datenquellen
125 125
TaxonNavigator_RESTORE=Taxonnavigator wiederherstellen
eu.etaxonomy.taxeditor.store/src/main/java/eu/etaxonomy/taxeditor/ui/element/VerbatimDateDetailSection.java
10 10

  
11 11
import org.eclipse.swt.widgets.Text;
12 12

  
13
import eu.etaxonomy.cdm.model.common.TimePeriod;
14 13
import eu.etaxonomy.cdm.model.common.VerbatimTimePeriod;
15 14
import eu.etaxonomy.cdm.strategy.parser.TimePeriodParser;
16 15

  
......
62 61
		return result;
63 62
	}
64 63

  
65
//
66
//    /**
67
//     * <p>
68
//     * Setter for the field <code>timePeriod</code>.
69
//     * </p>
70
//     *
71
//     * @param timePeriod
72
//     *            a {@link eu.etaxonomy.cdm.model.common.TimePeriod} object.
73
//     */
74
//
75
//    public void setEntity(VerbatimTimePeriod timePeriod) {
76
//        setEntityInternally(timePeriod);
77
//        updateTitle();
78
//        getText_parseText().setText(timePeriod.toString());
79
//
80
//    }
81 64
    
82 65
    @Override
83 66
    protected void handleEvent(Object eventSource) {
84 67

  
85 68
        if (eventSource == text_VerbatimDate) {
86
            TimePeriod entity = getEntity();
87
            if(entity instanceof VerbatimTimePeriod){
88
                ((VerbatimTimePeriod)entity).setVerbatimDate(text_VerbatimDate.getText());
89
            }else{
90
                VerbatimTimePeriod newEntity = newInstance();
91
                newEntity.setEnd(entity.getEnd());
92
                newEntity.setStart(entity.getStart());
93
                newEntity.setFreeText(entity.getFreeText());
94
                newEntity.setVerbatimDate(text_VerbatimDate.getText());
95
                setEntity(newEntity);
96
            }
69
            VerbatimTimePeriod entity = getEntity();
70
            entity.setVerbatimDate(text_VerbatimDate.getText());
97 71
        }
98 72
        super.handleEvent(eventSource);
99 73

  
......
108 82
        super.setEntityInternally(timePeriod);
109 83
        ((Text) text_VerbatimDate.getMainControl()).setSelection(super.getCursorPosition());
110 84
        text_VerbatimDate.setText(timePeriod.getVerbatimDate());
111
//        super.setEntity(timePeriod);
112 85
    }
113 86

  
114 87
}

Also available in: Unified diff