Changeset 1919 in josm


Ignore:
Timestamp:
2009-08-07T19:27:53+02:00 (15 years ago)
Author:
Gubaer
Message:

fixed #3203: pressing DEL deletes Layer instead of objects

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/org/openstreetmap/josm/gui/dialogs/LayerListDialog.java

    r1917 r1919  
    131131        //-- delete layer action
    132132        DeleteLayerAction deleteLayerAction = new DeleteLayerAction();
    133         layerList.getInputMap(JComponent.WHEN_IN_FOCUSED_WINDOW).put(
    134                 KeyStroke.getKeyStroke(KeyEvent.VK_DELETE, 0),"deleteLayer"
    135         );
    136         layerList.getActionMap().put("deleteLayer", deleteLayerAction);
     133        // #3203: grabs DELETE even for primitives on the map
     134        // FIXME: disabling for now, don't understand yet what's going on
     135        //        layerList.getInputMap(JComponent.WHEN_ANCESTOR_OF_FOCUSED_COMPONENT).put(
     136        //                KeyStroke.getKeyStroke(KeyEvent.VK_DELETE, 0),"deleteLayer"
     137        //        );
     138        //        layerList.getActionMap().put("deleteLayer", deleteLayerAction);
    137139        adaptTo(deleteLayerAction, selectionModel);
    138140        buttonPanel.add(new SideButton(deleteLayerAction, "delete"));
Note: See TracChangeset for help on using the changeset viewer.