- Timestamp:
- 2012-08-11T23:37:27+02:00 (12 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/org/openstreetmap/josm/gui/layer/geoimage/GeoImageLayer.java
r5242 r5430 42 42 import org.openstreetmap.josm.actions.RenameLayerAction; 43 43 import org.openstreetmap.josm.actions.mapmode.MapMode; 44 import org.openstreetmap.josm.actions.mapmode.SelectAction; 44 45 import org.openstreetmap.josm.data.Bounds; 45 46 import org.openstreetmap.josm.data.coor.LatLon; … … 724 725 private void hook_up_mouse_events() { 725 726 mouseAdapter = new MouseAdapter() { 727 private final boolean isMapModeOk() { 728 return Main.map.mapMode == null || Main.map.mapMode instanceof SelectAction; 729 } 726 730 @Override public void mousePressed(MouseEvent e) { 727 731 728 732 if (e.getButton() != MouseEvent.BUTTON1) 729 733 return; 730 if (isVisible() ) {734 if (isVisible() && isMapModeOk()) { 731 735 Main.map.mapView.repaint(); 732 736 } … … 736 740 if (ev.getButton() != MouseEvent.BUTTON1) 737 741 return; 738 if (data == null || !isVisible() )742 if (data == null || !isVisible() || !isMapModeOk()) 739 743 return; 740 744
Note:
See TracChangeset
for help on using the changeset viewer.