Changeset 3385 in josm
- Timestamp:
- 2010-07-25T16:00:01+02:00 (14 years ago)
- Location:
- trunk/src/org/openstreetmap/josm
- Files:
-
- 15 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/org/openstreetmap/josm/actions/JosmAction.java
r3384 r3385 99 99 } 100 100 101 /**102 * needs to be overridden to be useful103 */104 public void addListener(JosmAction a) {105 return;106 }107 108 101 private void setHelpId() { 109 102 String helpId = "Action/"+getClass().getName().substring(getClass().getName().lastIndexOf('.')+1); -
trunk/src/org/openstreetmap/josm/actions/PasteTagsAction.java
r3384 r3385 30 30 public final class PasteTagsAction extends JosmAction implements PasteBufferChangedListener { 31 31 32 public PasteTagsAction( JosmAction copyAction) {32 public PasteTagsAction() { 33 33 super(tr("Paste Tags"), "pastetags", 34 34 tr("Apply tags of contents of paste buffer to all selected items."), -
trunk/src/org/openstreetmap/josm/actions/search/PushbackTokenizer.java
r3050 r3385 14 14 public class PushbackTokenizer { 15 15 16 public class Range {16 public static class Range { 17 17 private final long start; 18 18 private final long end; -
trunk/src/org/openstreetmap/josm/corrector/TagCorrector.java
r3210 r3385 41 41 * confirm these changes. 42 42 */ 43 43 44 44 public abstract class TagCorrector<P extends OsmPrimitive> { 45 45 … … 76 76 p.add(label2, GBC.eop().anchor(GBC.CENTER)); 77 77 78 for ( OsmPrimitive primitive : tagCorrectionsMap.keySet()) {79 final List<TagCorrection> tagCorrections = tagCorrectionsMap80 .get(primitive);78 for (Entry<OsmPrimitive, List<TagCorrection>> entry : tagCorrectionsMap.entrySet()) { 79 final OsmPrimitive primitive = entry.getKey(); 80 final List<TagCorrection> tagCorrections = entry.getValue(); 81 81 82 82 if (tagCorrections.isEmpty()) { … … 102 102 } 103 103 104 for (OsmPrimitive primitive : roleCorrectionMap.keySet()) { 105 final List<RoleCorrection> roleCorrections = roleCorrectionMap 106 .get(primitive); 104 for (Entry<OsmPrimitive, List<RoleCorrection>> entry : roleCorrectionMap.entrySet()) { 105 final OsmPrimitive primitive = entry.getKey(); 106 final List<RoleCorrection> roleCorrections = entry.getValue(); 107 107 108 if (roleCorrections.isEmpty()) { 108 109 continue; -
trunk/src/org/openstreetmap/josm/data/projection/Lambert.java
r3343 r3385 85 85 public static final int DEFAULT_ZONE = 0; 86 86 87 private staticint layoutZone = DEFAULT_ZONE;87 private int layoutZone = DEFAULT_ZONE; 88 88 89 89 private static NTV2GridShiftFile ntf_rgf93Grid = null; -
trunk/src/org/openstreetmap/josm/gui/ExtendedDialog.java
r3355 r3385 292 292 */ 293 293 protected void buttonAction(int buttonIndex, ActionEvent evt) { 294 String a = evt.getActionCommand();295 294 result = buttonIndex+1; 296 295 setVisible(false); -
trunk/src/org/openstreetmap/josm/gui/FileDrop.java
r3083 r3385 323 323 324 324 // Convert list to array 325 final File[] files = (File[]) fileList.toArray();325 final File[] files = fileList.toArray(new File[fileList.size()]); 326 326 327 327 // Alert listener to drop. -
trunk/src/org/openstreetmap/josm/gui/MainMenu.java
r3327 r3385 119 119 public final JosmAction copy = new CopyAction(); 120 120 public final JosmAction paste = new PasteAction(); 121 public final JosmAction pasteTags = new PasteTagsAction( copy);121 public final JosmAction pasteTags = new PasteTagsAction(); 122 122 public final JosmAction duplicate = new DuplicateAction(); 123 123 public final JosmAction delete = new DeleteAction(); -
trunk/src/org/openstreetmap/josm/gui/conflict/tags/PasteTagsConflictResolverDialog.java
r3083 r3385 175 175 StatisticsInfo info = new StatisticsInfo(); 176 176 info.numTags = tagsForAllPrimitives.getKeys().size(); 177 for (OsmPrimitiveType type: sourceStatistics.keySet()) { 178 info.sourceInfo.put(type, sourceStatistics.get(type)); 179 } 180 for (OsmPrimitiveType type: targetStatistics.keySet()) { 181 info.targetInfo.put(type, targetStatistics.get(type)); 182 } 177 info.sourceInfo.putAll(sourceStatistics); 178 info.targetInfo.putAll(targetStatistics); 183 179 statisticsModel.append(info); 184 180 validate(); -
trunk/src/org/openstreetmap/josm/gui/layer/geoimage/ThumbsLoader.java
r2986 r3385 50 50 } 51 51 } 52 try { 53 layer.updateOffscreenBuffer = true; 54 } catch (Exception e) {} 52 layer.updateOffscreenBuffer = true; 55 53 Main.map.mapView.repaint(); 56 54 (new Thread() { // clean up the garbage - shouldn't hurt -
trunk/src/org/openstreetmap/josm/gui/oauth/OAuthAuthorizationWizard.java
r3121 r3385 52 52 * This wizard walks the user to the necessary steps to retrieve an OAuth Access Token which 53 53 * allows JOSM to access the OSM API on the users behalf. 54 * 54 * 55 55 */ 56 56 public class OAuthAuthorizationWizard extends JDialog { … … 70 70 /** 71 71 * Builds the row with the action buttons 72 * 72 * 73 73 * @return 74 74 */ … … 90 90 /** 91 91 * Builds the panel with general information in the header 92 * 92 * 93 93 * @return 94 94 */ … … 207 207 /** 208 208 * Creates the wizard. 209 * 209 * 210 210 * @param apiUrl the API URL. Must not be null. 211 211 * @throws IllegalArgumentException thrown if apiUrl is null … … 220 220 /** 221 221 * Creates the wizard. 222 * 222 * 223 223 * @param parent the component relative to which the dialog is displayed 224 224 * @param apiUrl the API URL. Must not be null. … … 235 235 * Sets the API URL for the API for which this wizard is generating 236 236 * an Access Token. 237 * 237 * 238 238 * @param apiUrl the API URL. Must not be null. 239 239 * @throws IllegalArgumentException thrown if apiUrl is null … … 256 256 /** 257 257 * Replies true if the dialog was cancelled 258 * 258 * 259 259 * @return true if the dialog was cancelled 260 260 */ … … 274 274 /** 275 275 * Replies the Access Token entered using the wizard 276 * 276 * 277 277 * @return the access token. May be null if the wizard was canceled. 278 278 */ … … 283 283 /** 284 284 * Replies the current OAuth parameters. 285 * 285 * 286 286 * @return the current OAuth parameters. 287 287 */ … … 293 293 * Replies true if the currently selected Access Token shall be saved to 294 294 * the preferences. 295 * 295 * 296 296 * @return true if the currently selected Access Token shall be saved to 297 297 * the preferences … … 303 303 /** 304 304 * Initializes the dialog with values from the preferences 305 * 305 * 306 306 */ 307 307 public void initFromPreferences() { … … 389 389 } 390 390 391 class ExternalBrowserLauncher implements HyperlinkListener {391 static class ExternalBrowserLauncher implements HyperlinkListener { 392 392 public void hyperlinkUpdate(HyperlinkEvent e) { 393 393 if (e.getEventType().equals(HyperlinkEvent.EventType.ACTIVATED)) { -
trunk/src/org/openstreetmap/josm/gui/tagging/ac/AutoCompletingComboBox.java
r3312 r3385 69 69 int end = start; 70 70 String curText = getText(0, size); 71 71 72 72 // if the text starts with a number we don't autocomplete 73 73 if (Main.pref.getBoolean("autocomplete.dont_complete_numbers", true)) { 74 74 try { 75 75 Long.parseLong(str); 76 if (curText.length() == 0) {76 if (curText.length() == 0) 77 77 // we don't autocomplete on numbers 78 78 return; 79 }80 79 Long.parseLong(curText); 81 80 return; … … 85 84 } 86 85 } 87 86 88 87 // lookup and select a matching item 89 88 Object item = lookupItem(curText); … … 226 225 * renders an AutoCompletionListItem by showing only the string value part 227 226 */ 228 public class AutoCompleteListCellRenderer extends JLabel implements ListCellRenderer {227 public static class AutoCompleteListCellRenderer extends JLabel implements ListCellRenderer { 229 228 230 229 public AutoCompleteListCellRenderer() { -
trunk/src/org/openstreetmap/josm/gui/tagging/ac/AutoCompletionItemPritority.java
r3214 r3385 28 28 */ 29 29 public static AutoCompletionItemPritority IS_IN_STANDARD = new AutoCompletionItemPritority(false, true, false); 30 30 31 31 /** 32 32 * Indicates that this is a value from a selected object. … … 64 64 */ 65 65 public int compareTo(AutoCompletionItemPritority other) { 66 int sel = new Boolean(selected).compareTo(other.selected);66 int sel = Boolean.valueOf(selected).compareTo(other.selected); 67 67 if (sel != 0) return sel; 68 68 69 int ds = new Boolean(inDataSet).compareTo(other.inDataSet);69 int ds = Boolean.valueOf(inDataSet).compareTo(other.inDataSet); 70 70 if (ds != 0) return ds; 71 71 72 int std = new Boolean(inStandard).compareTo(other.inStandard);72 int std = Boolean.valueOf(inStandard).compareTo(other.inStandard); 73 73 if (std != 0) return std; 74 74 … … 82 82 public AutoCompletionItemPritority mergeWith(AutoCompletionItemPritority other) { 83 83 return new AutoCompletionItemPritority( 84 85 86 84 inDataSet || other.inDataSet, 85 inStandard || other.inStandard, 86 selected || other.selected); 87 87 } 88 88 -
trunk/src/org/openstreetmap/josm/tools/PresetTextComparator.java
r3083 r3385 1 1 package org.openstreetmap.josm.tools; 2 2 3 import java.io.Serializable; 3 4 import java.util.Comparator; 4 5 5 6 import javax.swing.JMenuItem; 6 7 7 public class PresetTextComparator implements Comparator<JMenuItem> {8 public class PresetTextComparator implements Comparator<JMenuItem>, Serializable { 8 9 //TODO add error checking and stuff 9 10 public int compare(JMenuItem arg0, JMenuItem arg1) { -
trunk/src/org/openstreetmap/josm/tools/XmlObjectParser.java
r3321 r3385 109 109 } 110 110 111 private class AddNamespaceFilter extends XMLFilterImpl {111 private static class AddNamespaceFilter extends XMLFilterImpl { 112 112 113 113 private final String namespace;
Note:
See TracChangeset
for help on using the changeset viewer.