[OpenMap Users] LocationLayer.useDeclutterMatrix is not synched with jcheckbox from getGUI

From: Carsten Ø. Madsen <com_at_navicon.dk>
Date: Tue, 20 Apr 2010 10:36:56 +0200

Hello

I have problem with getting the jcheckbox from LocationLayer.getGUI
synchronized with the useDeclutterMatrix property. If the property is
set through LocationLayer.setUseDeclutter it is not reflected in the
jcheckbox in the GUI.

The code from LocationLayer is:
             ...
             if (declutterMatrix != null) {
                 JPanel dbp = new JPanel(new GridLayout(0, 1));

                 JCheckBox declutterButton = new
JCheckBox(i18n.get(LocationLayer.class,
                         "declutterNames",
                         "Declutter Names"), useDeclutterMatrix);
                 declutterButton.addActionListener(new ActionListener() {
                     public void actionPerformed(ActionEvent ae) {
                         JCheckBox jcb = (JCheckBox) ae.getSource();
                         useDeclutterMatrix = jcb.isSelected();
                         if (isVisible()) {
                             doPrepare();
                         }
                     }
                 });

and

     public void setUseDeclutterMatrix(boolean set) {
         useDeclutterMatrix = set;
     }

Thus there is no binding in place. As far as I can tell the only option
is to dig out the jcheckbox from getGUI and the patch it to listen for
changes on useDeclutterMatrix?

BR
Carsten

--
[To unsubscribe to this list send an email to "majdart_at_bbn.com"
with the following text in the BODY of the message "unsubscribe openmap-users"]
Received on Tue Apr 20 2010 - 04:56:41 EDT

This archive was generated by hypermail 2.3.0 : Tue Mar 28 2017 - 23:25:09 EDT