Project

General

Profile

Revision 4f2c16a0

ID4f2c16a0f0b83e0c6c73ae1259e945dd83097493
Parent a1171a3c
Child 1e03f16d

Added by Patrick Plitzner 8 months ago

ref #8476, #8474, #7994, #8477 Add checkboxes for term tree flags

View differences:

eu.etaxonomy.taxeditor.store/src/main/java/eu/etaxonomy/taxeditor/ui/section/feature/FeatureTreeDetailElement.java
14 14
import eu.etaxonomy.taxeditor.model.ColorResources;
15 15
import eu.etaxonomy.taxeditor.preference.Resources;
16 16
import eu.etaxonomy.taxeditor.ui.element.CdmFormFactory;
17
import eu.etaxonomy.taxeditor.ui.element.CheckboxElement;
17 18
import eu.etaxonomy.taxeditor.ui.element.ICdmFormElement;
18 19
import eu.etaxonomy.taxeditor.ui.section.AbstractIdentifiableEntityDetailElement;
19 20

  
......
25 26
 */
26 27
public class FeatureTreeDetailElement extends AbstractIdentifiableEntityDetailElement<TermTree> {
27 28

  
29
    private CheckboxElement allowDuplicates;
30
    private CheckboxElement orderRelevant;
31
    private CheckboxElement isFlat;
32

  
28 33
	public FeatureTreeDetailElement(CdmFormFactory formFactory,
29 34
			ICdmFormElement formElement) {
30 35
		super(formFactory, formElement);
......
43 48
                formElement, "Title Cache", entity.getTitleCache(),
44 49
                entity.isProtectedTitleCache(), style);
45 50
	    toggleable_cache.getBtnToggleProtectTitleCache().setEnabled(false);
51

  
52
	    allowDuplicates = formFactory.createCheckbox(formElement, "Allow duplicates", entity.isAllowDuplicates(), style);
53
	    orderRelevant = formFactory.createCheckbox(formElement, "Order relevant", entity.isOrderRelevant(), style);
54
	    isFlat = formFactory.createCheckbox(formElement, "Is flat", entity.isFlat(), style);
46 55
    }
47 56

  
48 57
	@Override
......
56 65
	    if (eventSource == toggleable_cache) {
57 66
	            handleToggleableCacheField();
58 67
        }
68
	    else if (eventSource == allowDuplicates) {
69
	        getEntity().setAllowDuplicates(allowDuplicates.getSelection());
70
	    }
71
	    else if (eventSource == orderRelevant) {
72
	        getEntity().setOrderRelevant(orderRelevant.getSelection());
73
	    }
74
	    else if (eventSource == isFlat) {
75
	        getEntity().setFlat(isFlat.getSelection());
76
	    }
59 77
	}
60 78

  
61 79
}

Also available in: Unified diff

Add picture from clipboard (Maximum size: 40 MB)