Changeset 7293 in josm for trunk/src


Ignore:
Timestamp:
2014-07-07T18:40:16+02:00 (10 years ago)
Author:
akks
Message:

Fix resource leaks when closing map in Lasso mode, see #10104

Location:
trunk/src/org/openstreetmap/josm
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/org/openstreetmap/josm/actions/LassoModeAction.java

    r7224 r7293  
    66import org.openstreetmap.josm.Main;
    77import org.openstreetmap.josm.actions.mapmode.MapMode;
     8import org.openstreetmap.josm.gui.layer.Layer;
    89import org.openstreetmap.josm.tools.ImageProvider;
    910
     
    3536        super.exitMode();
    3637    }
     38
     39    @Override
     40    public boolean layerIsSupported(Layer l) {
     41        return Main.map.mapModeSelect.layerIsSupported(l);
     42    }
    3743}
  • trunk/src/org/openstreetmap/josm/gui/util/AdvancedKeyPressDetector.java

    r7219 r7293  
    9898        }
    9999        if (!modifierListeners.isEmpty()) {
    100             Main.warn(tr("Some of the key listeners forgot to remove themselves: {0}"), modifierListeners.toString());
     100            Main.warn(tr("Some of the key modifier listeners forgot to remove themselves: {0}"), modifierListeners.toString());
    101101        }
    102102        try {
     
    160160     */
    161161    public boolean isKeyPressed(int keyCode) {
    162         return set.contains(Integer.valueOf(keyCode));
     162        return set.contains(keyCode);
    163163    }
    164164}
Note: See TracChangeset for help on using the changeset viewer.