Changeset 34656 in osm for applications/editors/josm
- Timestamp:
- 2018-09-15T14:21:41+02:00 (6 years ago)
- Location:
- applications/editors/josm/plugins/CommandLine/src/org/openstreetmap/josm/plugins/commandline
- Files:
-
- 5 edited
Legend:
- Unmodified
- Added
- Removed
-
applications/editors/josm/plugins/CommandLine/src/org/openstreetmap/josm/plugins/commandline/Command.java
r34574 r34656 140 140 if (obj instanceof String) { 141 141 if (parameter.getRawValue() instanceof Relay) { 142 if (((Relay) (parameter.getRawValue())).isCorrectValue((String) obj))142 if (((Relay) parameter.getRawValue()).isCorrectValue((String) obj)) 143 143 return true; 144 144 } -
applications/editors/josm/plugins/CommandLine/src/org/openstreetmap/josm/plugins/commandline/CommandLine.java
r34574 r34656 148 148 149 149 private void loadCommands() { 150 commands = (new Loader(getPluginDirs().getUserDataDirectory(false))).load();150 commands = new Loader(getPluginDirs().getUserDataDirectory(false)).load(); 151 151 if (commands.isEmpty()) { 152 152 if (!GraphicsEnvironment.isHeadless() && JOptionPane.YES_OPTION == JOptionPane.showConfirmDialog(MainApplication.getMainFrame(), … … 155 155 try { 156 156 downloadAndInstallDefaultCommands(); 157 commands = (new Loader(getPluginDirs().getUserDataDirectory(false))).load();157 commands = new Loader(getPluginDirs().getUserDataDirectory(false)).load(); 158 158 JOptionPane.showMessageDialog(MainApplication.getMainFrame(), tr("Default commands have been successfully installed"), 159 159 tr("Success"), JOptionPane.INFORMATION_MESSAGE); … … 232 232 prefix = tr(currentParameter.description == null ? currentParameter.name : currentParameter.description); 233 233 if (currentParameter.getRawValue() instanceof Relay) 234 prefix = prefix + " (" + ((Relay) (currentParameter.getRawValue())).getOptionsString() + ")";234 prefix = prefix + " (" + ((Relay) currentParameter.getRawValue()).getOptionsString() + ")"; 235 235 prefix += commandSymbol; 236 236 String value = currentParameter.getValue(); -
applications/editors/josm/plugins/CommandLine/src/org/openstreetmap/josm/plugins/commandline/Loader.java
r34574 r34656 117 117 @Override 118 118 public void characters(char[] ch, int start, int length) { 119 String text = (new String(ch, start, length)).trim();119 String text = new String(ch, start, length).trim(); 120 120 if (currentParameter != null) { 121 121 if (currentTag.equals("name")) { -
applications/editors/josm/plugins/CommandLine/src/org/openstreetmap/josm/plugins/commandline/OsmToCmd.java
r34574 r34656 111 111 return; 112 112 } 113 if (! (v.equals("0.6"))) {113 if (!v.equals("0.6")) { 114 114 throwException(tr("Unsupported version: {0}", v)); 115 115 return; -
applications/editors/josm/plugins/CommandLine/src/org/openstreetmap/josm/plugins/commandline/Relay.java
r34574 r34656 25 25 public void addValue(String value) { 26 26 String letter = null; 27 if (! (options.containsValue(value))) {27 if (!options.containsValue(value)) { 28 28 int i = 0; 29 29 for (; i < value.length(); i++) {
Note:
See TracChangeset
for help on using the changeset viewer.