Project

General

Profile

« Previous | Next » 

Revision af7453f9

Added by Katja Luther almost 6 years ago

ref #6390: add all name related parts to details view of misapp

View differences:

eu.etaxonomy.taxeditor.store/src/main/java/eu/etaxonomy/taxeditor/view/detail/CdmSectionPart.java
34 34
import eu.etaxonomy.taxeditor.ui.section.key.ScopeRestrictionSection;
35 35
import eu.etaxonomy.taxeditor.ui.section.key.TaxonomicScopeSection;
36 36
import eu.etaxonomy.taxeditor.ui.section.name.NameDetailSection;
37
import eu.etaxonomy.taxeditor.ui.section.name.NameRelationshipDetailSection;
38
import eu.etaxonomy.taxeditor.ui.section.name.NomenclaturalStatusSection;
37 39
import eu.etaxonomy.taxeditor.ui.section.name.NonViralNameDetailSection;
40
import eu.etaxonomy.taxeditor.ui.section.name.ProtologueSection;
41
import eu.etaxonomy.taxeditor.ui.section.name.TypeDesignationSection;
38 42
import eu.etaxonomy.taxeditor.ui.section.occurrence.GeoScopeDetailSection;
39 43
import eu.etaxonomy.taxeditor.ui.section.occurrence.IDerivedUnitFacadeDetailSection;
44
import eu.etaxonomy.taxeditor.ui.section.reference.NomenclaturalReferenceDetailSection;
40 45
import eu.etaxonomy.taxeditor.ui.section.taxon.TaxonRelationshipDetailSection;
41 46

  
42 47
/**
......
111 116
			((NonViralNameDetailSection) formSection)
112 117
					.setTaxonBase( ((TaxonRelationship)input).getFromTaxon());
113 118
			return true;
119
		}else if ((input instanceof TaxonRelationship)
120
				&& (formSection instanceof NomenclaturalReferenceDetailSection)) {
121
			((NomenclaturalReferenceDetailSection) formSection)
122
					.setTaxonBase( ((TaxonRelationship)input).getFromTaxon());
123
			return true;
124
		}else if ((input instanceof TaxonRelationship)
125
				&& (formSection instanceof NomenclaturalStatusSection)) {
126
			((NomenclaturalStatusSection) formSection)
127
					.setTaxonBase( ((TaxonRelationship)input).getFromTaxon());
128
			return true;
129
		}else if ((input instanceof TaxonRelationship)
130
				&& (formSection instanceof ProtologueSection)) {
131
			((ProtologueSection) formSection)
132
					.setTaxonBase( ((TaxonRelationship)input).getFromTaxon());
133
			return true;
134
		}else if ((input instanceof TaxonRelationship)
135
				&& (formSection instanceof TypeDesignationSection)) {
136
			((TypeDesignationSection) formSection)
137
					.setTaxonBase( ((TaxonRelationship)input).getFromTaxon());
138
			return true;
139
		}else if ((input instanceof TaxonRelationship)
140
				&& (formSection instanceof NameRelationshipDetailSection)) {
141
			((NameRelationshipDetailSection) formSection)
142
					.setTaxonBase( ((TaxonRelationship)input).getFromTaxon());
143
			return true;
114 144
		}
115 145

  
116

  
146
		
117 147
		formSection.setEntity((T) input);
118 148

  
119 149
		return true;
eu.etaxonomy.taxeditor.store/src/main/java/eu/etaxonomy/taxeditor/view/detail/DetailsViewer.java
778 778
                .createNonViralNameDetailSection(getConversationHolder(), parent, this, true,
779 779
                        ExpandableComposite.TWISTIE | ExpandableComposite.EXPANDED);
780 780
        addPart(nonViralNameSection);
781
//        formFactory.createHorizontalSeparator(parent, SWT.BORDER);
782
//        //if (!PreferencesUtil.getPreferenceStore().getBoolean(IPreferenceKeys.SHOW_SIMPLE_NAME_DETAILS_SECTION) || (PreferencesUtil.getPreferenceStore().getBoolean(IPreferenceKeys.SHOW_SIMPLE_NAME_DETAILS_SECTION) && PreferencesUtil.getPreferenceStore().getBoolean(IPreferenceKeys.SHOW_NAME_DETAILS_SECTION_NOMENCLATURAL_REFERENCE))){
783
//        NomenclaturalReferenceDetailSection referenceDetailSection = formFactory.createNomenclaturalReferenceDetailSection(getConversationHolder(), parent, this,
784
//        		ExpandableComposite.TWISTIE | ExpandableComposite.EXPANDED);
785
//        formFactory.createHorizontalSeparator(parent, SWT.BORDER);
786
//        addPart(referenceDetailSection);
781
        formFactory.createHorizontalSeparator(parent, SWT.BORDER);
782
        //if (!PreferencesUtil.getPreferenceStore().getBoolean(IPreferenceKeys.SHOW_SIMPLE_NAME_DETAILS_SECTION) || (PreferencesUtil.getPreferenceStore().getBoolean(IPreferenceKeys.SHOW_SIMPLE_NAME_DETAILS_SECTION) && PreferencesUtil.getPreferenceStore().getBoolean(IPreferenceKeys.SHOW_NAME_DETAILS_SECTION_NOMENCLATURAL_REFERENCE))){
783
        NomenclaturalReferenceDetailSection referenceDetailSection = formFactory.createNomenclaturalReferenceDetailSection(getConversationHolder(), parent, this,
784
        		ExpandableComposite.TWISTIE | ExpandableComposite.EXPANDED);
785
        formFactory.createHorizontalSeparator(parent, SWT.BORDER);
786
        addPart(referenceDetailSection);
787 787

  
788
        //if ( !PreferencesUtil.getPreferenceStore().getBoolean(IPreferenceKeys.SHOW_SIMPLE_NAME_DETAILS_SECTION) || (PreferencesUtil.getPreferenceStore().getBoolean(IPreferenceKeys.SHOW_SIMPLE_NAME_DETAILS_SECTION) && PreferencesUtil.getPreferenceStore().getBoolean(IPreferenceKeys.SHOW_NAME_DETAILS_SECTION_NOMENCLATURAL_STATUS))){
789
            NomenclaturalStatusSection nomenclaturalStatusSection = formFactory.createNomenclaturalStatusSection(getConversationHolder(), parent,
790
            		ExpandableComposite.TWISTIE | ExpandableComposite.EXPANDED);
791
            formFactory.createHorizontalSeparator(parent, SWT.BORDER);
792
            addPart(nomenclaturalStatusSection);
793
    //}
794

  
795
	//if (!PreferencesUtil.getPreferenceStore().getBoolean(IPreferenceKeys.SHOW_SIMPLE_NAME_DETAILS_SECTION) || (PreferencesUtil.getPreferenceStore().getBoolean(IPreferenceKeys.SHOW_SIMPLE_NAME_DETAILS_SECTION) && PreferencesUtil.getPreferenceStore().getBoolean(IPreferenceKeys.SHOW_NAME_DETAILS_SECTION_PROTOLOGUE))){
796
		ProtologueSection protologSection = formFactory.createProtologueSection(getConversationHolder(), parent, ExpandableComposite.TWISTIE);
797
		formFactory.createHorizontalSeparator(parent, SWT.BORDER);
798
		addPart(protologSection);
799
	//}
800

  
801
	//if (!PreferencesUtil.getPreferenceStore().getBoolean(IPreferenceKeys.SHOW_SIMPLE_NAME_DETAILS_SECTION) || (PreferencesUtil.getPreferenceStore().getBoolean(IPreferenceKeys.SHOW_SIMPLE_NAME_DETAILS_SECTION) &&  PreferencesUtil.getPreferenceStore().getBoolean(IPreferenceKeys.SHOW_NAME_DETAILS_SECTION_TYPE_DESIGNATION))){
802
		TypeDesignationSection typeDesignationSection = formFactory.createTypeDesignationSection(getConversationHolder(), parent, ExpandableComposite.TWISTIE);
803
		formFactory.createHorizontalSeparator(parent, SWT.BORDER);
804
		addPart(typeDesignationSection);
805
	//}
806

  
807
	//if (!PreferencesUtil.getPreferenceStore().getBoolean(IPreferenceKeys.SHOW_SIMPLE_NAME_DETAILS_SECTION) || (PreferencesUtil.getPreferenceStore().getBoolean(IPreferenceKeys.SHOW_SIMPLE_NAME_DETAILS_SECTION) && PreferencesUtil.getPreferenceStore().getBoolean(IPreferenceKeys.SHOW_NAME_DETAILS_SECTION_NAME_RELATIONSHIP))){
808
		NameRelationshipDetailSection nameRelationshipSection = formFactory.createNameRelationshipDetailSection(getConversationHolder(), parent, ExpandableComposite.TWISTIE);
809
		formFactory.createHorizontalSeparator(parent, SWT.BORDER);
810
		addPart(nameRelationshipSection);
811
	//}
812

  
813
        
788 814
        //}
789 815
    }
790 816

  

Also available in: Unified diff