Project

General

Profile

« Previous | Next » 

Revision fbd932cc

Added by Katja Luther over 5 years ago

ref #7849: disable apply button until something was changed in preference page

View differences:

eu.etaxonomy.taxeditor.store/src/main/java/eu/etaxonomy/taxeditor/databaseAdmin/preferencePage/SpecimenAdminPreferences.java
32 32
    Composite composite;
33 33
    CdmPreference showSpecimenPref = null;
34 34

  
35
//    @Override
36
//    protected Control createContents(Composite parent) {
37
//
38
//        getValues();
39
//        composite = createComposite(parent);
40
//        composite.setEnabled(isShowSpecimenRelatedIssues);
41
//        final Button showSpecimenButton = new Button(parent, SWT.CHECK);
42
//
43
//        showSpecimenButton.setText(Messages.DatabasePreferncesPage_Show_Specimen);
44
//
45
//        showSpecimenButton.setSelection(isShowSpecimenRelatedIssues);
46
//        showSpecimenButton.addSelectionListener(new SelectionAdapter(){
47
//             @Override
48
//             public void widgetSelected(SelectionEvent e) {
49
//                 isShowSpecimenRelatedIssues = showSpecimenButton.getSelection();
50
//                 if(isShowSpecimenRelatedIssues){
51
//                     composite.setVisible(true);
52
//                     composite.setEnabled(true);
53
//                 }else{
54
//                     composite.setVisible(false);
55
//                     composite.setEnabled(false);
56
//                 }
57
//              }
58
//         });
59
//        if (isAdminPreference){
60
//            createAllowOverrideButton(parent);
61
//        }
62
//
63
//        GridData gridData = createTextGridData();
64
//
65
//        Label separator= new Label(composite, SWT.HORIZONTAL | SWT.SEPARATOR);
66
//        separator.setLayoutData(gridData);
67
//
68
//        final Button showCollectingAreaInGeneralSectionButton = new Button(composite, SWT.CHECK);
69
//
70
//        showCollectingAreaInGeneralSectionButton.setText(Messages.DatabasePreferncesPage_Show_Collecting_Areas_in_general_section);
71
//
72
//        showCollectingAreaInGeneralSectionButton.setSelection(isShowCollectingAreaInGeneralSection);
73
//        showCollectingAreaInGeneralSectionButton.addSelectionListener(new SelectionAdapter(){
74
//             @Override
75
//             public void widgetSelected(SelectionEvent e) {
76
//                 isShowCollectingAreaInGeneralSection = showCollectingAreaInGeneralSectionButton.getSelection();
77
//
78
//              }
79
//         });
80
//
81
//        if (isAdminPreference){
82
//            createAllowOverrideButton(composite);
83
//        }
84
//        final Button determinationOnlyForFieldUnitsButton = new Button(composite, SWT.CHECK);
85
//
86
//        determinationOnlyForFieldUnitsButton.setText(Messages.DatabasePreferncesPage_Determination_only_for_field_unnits);
87
//
88
//        determinationOnlyForFieldUnitsButton.setSelection(isDeterminationOnlyForFieldUnits);
89
//        determinationOnlyForFieldUnitsButton.addSelectionListener(new SelectionAdapter(){
90
//             @Override
91
//             public void widgetSelected(SelectionEvent e) {
92
//                 isDeterminationOnlyForFieldUnits = determinationOnlyForFieldUnitsButton.getSelection();
93
//             }
94
//         });
95
//        if (isAdminPreference){
96
//            createAllowOverrideButton(composite);
97
//        }
98
//
99
//        final Button showTaxonAssociationButton = new Button(composite, SWT.CHECK);
100
//
101
//        showTaxonAssociationButton.setText(Messages.DatabasePreferncesPage_Taxon_Associations);
102
//
103
//        showTaxonAssociationButton.setSelection(isShowTaxonAssociation);
104
//        showTaxonAssociationButton.addSelectionListener(new SelectionAdapter(){
105
//             @Override
106
//             public void widgetSelected(SelectionEvent e) {
107
//                 isShowTaxonAssociation = showTaxonAssociationButton.getSelection();
108
//
109
//              }
110
//         });
111
//
112
//        if (isAdminPreference){
113
//            createAllowOverrideButton(composite);
114
//        }
115
//
116
//        final Button showLifeFormButton = new Button(composite, SWT.CHECK);
117
//        showLifeFormButton.setText(Messages.DatabasePreferncesPage_Life_Form);
118
//        showLifeFormButton.setSelection(isShowLifeForm);
119
//        showLifeFormButton.addSelectionListener(new SelectionAdapter(){
120
//             @Override
121
//             public void widgetSelected(SelectionEvent e) {
122
//                 isShowLifeForm = showLifeFormButton.getSelection();
123
//
124
//              }
125
//         });
126
//        if (isAdminPreference){
127
//            createAllowOverrideButton(composite);
128
//        }
129
//
130
//
131
//        return composite;
132
//    }
133

  
134 35
    @Override
135 36
    public void init() {
136 37
        super.init();

Also available in: Unified diff