Ignore:
Timestamp:
2016-08-23T22:07:06+02:00 (8 years ago)
Author:
Don-vip
Message:

fix #13429 - Clean validator tree and use listener to find changes (patch by michael2402) - gsoc-core

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/org/openstreetmap/josm/gui/preferences/validator/ValidatorTestsPreference.java

    r10611 r10880  
    5858        testPanel.setBorder(BorderFactory.createEmptyBorder(5, 5, 5, 5));
    5959
    60         prefUseIgnore = new JCheckBox(tr("Use ignore list."), Main.pref.getBoolean(ValidatorPreference.PREF_USE_IGNORE, true));
     60        prefUseIgnore = new JCheckBox(tr("Use ignore list."), ValidatorPreference.PREF_USE_IGNORE.get());
    6161        prefUseIgnore.setToolTipText(tr("Use the ignore list to suppress warnings."));
    6262        testPanel.add(prefUseIgnore, GBC.eol());
    6363
    64         prefUseLayer = new JCheckBox(tr("Use error layer."), Main.pref.getBoolean(ValidatorPreference.PREF_LAYER, true));
     64        prefUseLayer = new JCheckBox(tr("Use error layer."), ValidatorPreference.PREF_LAYER.get());
    6565        prefUseLayer.setToolTipText(tr("Use the error layer to display problematic elements."));
    6666        testPanel.add(prefUseLayer, GBC.eol());
     
    7171
    7272        prefOtherUpload = new JCheckBox(tr("Show informational level on upload."),
    73                 Main.pref.getBoolean(ValidatorPreference.PREF_OTHER_UPLOAD, false));
     73                ValidatorPreference.PREF_OTHER_UPLOAD.get());
    7474        prefOtherUpload.setToolTipText(tr("Show the informational tests in the upload check windows."));
    7575        testPanel.add(prefOtherUpload, GBC.eol());
     
    117117        Main.pref.putCollection(ValidatorPreference.PREF_SKIP_TESTS, tests);
    118118        Main.pref.putCollection(ValidatorPreference.PREF_SKIP_TESTS_BEFORE_UPLOAD, testsBeforeUpload);
    119         Main.pref.put(ValidatorPreference.PREF_USE_IGNORE, prefUseIgnore.isSelected());
     119        ValidatorPreference.PREF_USE_IGNORE.put(prefUseIgnore.isSelected());
    120120        ValidatorPreference.PREF_OTHER.put(prefOther.isSelected());
    121         Main.pref.put(ValidatorPreference.PREF_OTHER_UPLOAD, prefOtherUpload.isSelected());
    122         Main.pref.put(ValidatorPreference.PREF_LAYER, prefUseLayer.isSelected());
     121        ValidatorPreference.PREF_OTHER_UPLOAD.put(prefOtherUpload.isSelected());
     122        ValidatorPreference.PREF_LAYER.put(prefUseLayer.isSelected());
    123123        return false;
    124124    }
Note: See TracChangeset for help on using the changeset viewer.