Changeset 13973 in josm
- Timestamp:
- 2018-06-24T19:50:06+02:00 (7 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/org/openstreetmap/josm/io/remotecontrol/handler/LoadAndZoomHandler.java
r13929 r13973 13 13 import java.util.Set; 14 14 import java.util.concurrent.Future; 15 16 import javax.swing.JOptionPane; 15 17 16 18 import org.openstreetmap.josm.actions.AutoScaleAction; … … 31 33 import org.openstreetmap.josm.gui.MainApplication; 32 34 import org.openstreetmap.josm.gui.MapFrame; 35 import org.openstreetmap.josm.gui.Notification; 33 36 import org.openstreetmap.josm.gui.util.GuiHelper; 34 37 import org.openstreetmap.josm.io.remotecontrol.AddTagsDialog; … … 192 195 } 193 196 toSelect.clear(); 194 isKeepingCurrentSelection = false;195 197 ds.setSelected(newSel); 196 198 zoom(newSel, bbox); … … 235 237 } 236 238 237 AddTagsDialog.addTags(args, sender, forTagAdd); 239 // add tags to objects 240 if (args.containsKey("addtags")) { 241 // needs to run in EDT since forTagAdd is updated in EDT as well 242 GuiHelper.executeByMainWorkerInEDT(() -> { 243 if (!forTagAdd.isEmpty()) { 244 AddTagsDialog.addTags(args, sender, forTagAdd); 245 } else { 246 new Notification(isKeepingCurrentSelection 247 ? tr("You clicked on a JOSM remotecontrol link that would apply tags onto selected objects.\n" 248 + "Since no objects have been selected before this click, no tags were added.\n" 249 + "Select one or more objects and click the link again.") 250 : tr("You clicked on a JOSM remotecontrol link that would apply tags onto objects.\n" 251 + "Unfortunately that link seems to be broken.\n" 252 + "Technical explanation: the URL query parameter ''select='' or ''search='' has an invalid value.\n" 253 + "Ask someone at the origin of the clicked link to fix this.") 254 ).setIcon(JOptionPane.WARNING_MESSAGE).setDuration(Notification.TIME_LONG).show(); 255 } 256 }); 257 } 238 258 } 239 259
Note:
See TracChangeset
for help on using the changeset viewer.