Skip to content

Commit

Permalink
Fix JOSM #21455: Merge Address Nodes and Buildings not saving
Browse files Browse the repository at this point in the history
Signed-off-by: Taylor Smock <tsmock@fb.com>
  • Loading branch information
tsmock committed Oct 20, 2021
1 parent 20d58f0 commit bc5fb4c
Showing 1 changed file with 11 additions and 10 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,16 @@

import static org.openstreetmap.josm.tools.I18n.tr;

import javax.swing.Box;
import javax.swing.JButton;
import javax.swing.JCheckBox;
import javax.swing.JLabel;
import javax.swing.JPanel;
import javax.swing.JScrollPane;
import javax.swing.JSpinner;
import javax.swing.JTabbedPane;
import javax.swing.SpinnerNumberModel;

import java.awt.Component;
import java.awt.Cursor;
import java.awt.Dimension;
Expand All @@ -17,16 +27,6 @@
import java.util.Map;
import java.util.TreeMap;

import javax.swing.Box;
import javax.swing.JButton;
import javax.swing.JCheckBox;
import javax.swing.JLabel;
import javax.swing.JPanel;
import javax.swing.JScrollPane;
import javax.swing.JSpinner;
import javax.swing.JTabbedPane;
import javax.swing.SpinnerNumberModel;

import org.openstreetmap.josm.actions.ExpertToggleAction;
import org.openstreetmap.josm.data.preferences.BooleanProperty;
import org.openstreetmap.josm.gui.preferences.DefaultTabPreferenceSetting;
Expand Down Expand Up @@ -212,6 +212,7 @@ public void mouseClicked(MouseEvent e) {
public boolean ok() {
MapWithAIPreferenceHelper.setSwitchLayers(switchLayerCheckBox.isSelected(), true);
final Object value = maximumAdditionSpinner.getValue();
MapWithAIPreferenceHelper.setMergeBuildingAddress(this.mergeBuildingAddressCheckBox.isSelected(), true);
if (value instanceof Number) {
MapWithAIPreferenceHelper.setMaximumAddition(((Number) value).intValue(), true);
}
Expand Down

0 comments on commit bc5fb4c

Please sign in to comment.