Changeset 3885


Ignore:
Timestamp:
Jul 28, 2008, 3:10:57 PM (12 years ago)
Author:
yura
Message:
Location:
devel-tools/trunk/eclipse/org.refal.rfpdt.ui/src/org/refal/rfpdt/ui/preferences
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • devel-tools/trunk/eclipse/org.refal.rfpdt.ui/src/org/refal/rfpdt/ui/preferences/IPreferenceConstants.java

    r3878 r3885  
    88public interface IPreferenceConstants {
    99    public String PREFIX = "org.refal.rfpdt.editor."; //$NON-NLS-1$
    10 
    11     public String USE_PROJECT_SPECIFIC = PREFIX + "projectSpecific"; //$NON-NLS-1$
    1210
    1311    public String AUTOCLOSE_BRACES = PREFIX + "autoCloseBraces"; //$NON-NLS-1$
  • devel-tools/trunk/eclipse/org.refal.rfpdt.ui/src/org/refal/rfpdt/ui/preferences/PropertiesAndPreferencePage.java

    r3883 r3885  
    6464
    6565    private void disableFields () {
     66        projectPropertiesField.setBooleanValue(false);
    6667        if (controlEnableState == null)
    6768            controlEnableState = ControlEnableState.disable(control);
     
    114115            c1.setLayout(new GridLayout());
    115116            c1.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
    116 
    117             projectPropertiesField = new ModifiableBooleanFieldEditor(IPreferenceConstants.USE_PROJECT_SPECIFIC,
    118                     "Enable project specific settings", c1);
    119             addField(projectPropertiesField);
     117           
     118            String[] keys = keys();
     119            boolean projectPropertiesFieldValue = keys != null && keys.length > 0 && store.contains(keys()[0]);
     120            projectPropertiesField = new ModifiableBooleanFieldEditor("", "Enable project specific settings", c1);
    120121            projectPropertiesField.addSelectionListener(projectSpecificListner = new SelectionListener() {
    121122                public void widgetSelected (SelectionEvent e) {
     
    130131                }
    131132            });
     133            projectPropertiesField.setBooleanValue(projectPropertiesFieldValue);
    132134
    133135            title = new Link(labelComposite, SWT.NONE);
Note: See TracChangeset for help on using the changeset viewer.