Changeset 34254 in osm for applications/editors/josm/plugins
- Timestamp:
- 2018-06-05T13:36:42+02:00 (7 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
applications/editors/josm/plugins/pt_assistant/src/org/openstreetmap/josm/plugins/pt_assistant/actions/DoubleSplitAction.java
r34245 r34254 559 559 if (!values.getSelectedItem().toString().equals("building_passage")) 560 560 newKeys1.put("layer", "-1"); 561 } else if (keys.getSelectedItem() == "traffic_calming") { 562 newKeys1.put(keys.getSelectedItem().toString(), values.getSelectedItem().toString()); 563 newKeys1.put("maxspeed", "30"); 561 564 } else { 562 565 if (newKeys1.containsKey("bus_bay")) { … … 578 581 if (!values.getSelectedItem().toString().equals("building_passage")) 579 582 newKeys2.put("layer", "-1"); 583 } else if (keys.getSelectedItem() == "traffic_calming") { 584 newKeys2.put(keys.getSelectedItem().toString(), values.getSelectedItem().toString()); 585 newKeys2.put("maxspeed", "30"); 580 586 } else { 581 587 if (newKeys2.containsKey("bus_bay")) { … … 830 836 831 837 private void setOptionsWithBusBay() { 832 keys.setModel(new DefaultComboBoxModel<>(new String[] { "bus_bay", "bridge", "tunnel" })); 838 keys.setModel( 839 new DefaultComboBoxModel<>(new String[] { "bus_bay", "bridge", "tunnel", "traffic_calming" })); 833 840 834 841 if (affected.hasTag("bus_bay", "right") || previousAffectedWay.hasTag("bus_bay", "right")) { … … 861 868 values.setModel( 862 869 new DefaultComboBoxModel<>(new String[] { "yes", "culvert", "building_passage" })); 870 } else if ("traffic_calming".equals(keys.getSelectedItem())) { 871 values.setModel(new DefaultComboBoxModel<>(new String[] { "table" })); 863 872 } 864 873 } … … 867 876 868 877 private void setOptionsWithTunnel() { 869 keys.setModel(new DefaultComboBoxModel<>(new String[] { "tunnel", "bridge", "bus_bay" })); 878 keys.setModel( 879 new DefaultComboBoxModel<>(new String[] { "tunnel", "bridge", "bus_bay", "traffic_calming" })); 870 880 871 881 if (previousAffectedWay.hasKey("waterway") || affected.hasKey("waterway")) … … 893 903 } else if ("bridge".equals(keys.getSelectedItem())) { 894 904 values.setModel(new DefaultComboBoxModel<>(new String[] { "yes" })); 905 } else if ("traffic_calming".equals(keys.getSelectedItem())) { 906 values.setModel(new DefaultComboBoxModel<>(new String[] { "table" })); 895 907 } 896 908 } … … 899 911 900 912 private void setOptionsWithBridge() { 901 keys.setModel(new DefaultComboBoxModel<>(new String[] { "bridge", "bus_bay", "tunnel" })); 913 keys.setModel( 914 new DefaultComboBoxModel<>(new String[] { "bridge", "bus_bay", "tunnel", "traffic_calming" })); 902 915 903 916 values.setModel(new DefaultComboBoxModel<>(new String[] { "yes" })); … … 922 935 } else if ("bridge".equals(keys.getSelectedItem())) { 923 936 values.setModel(new DefaultComboBoxModel<>(new String[] { "yes" })); 937 } else if ("traffic_calming".equals(keys.getSelectedItem())) { 938 values.setModel(new DefaultComboBoxModel<>(new String[] { "table" })); 924 939 } 925 940 }
Note:
See TracChangeset
for help on using the changeset viewer.