Changeset 19050 in josm for trunk/src/org/openstreetmap/josm/gui/SelectionManager.java
- Timestamp:
- 2024-04-22T20:59:26+02:00 (7 months ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/org/openstreetmap/josm/gui/SelectionManager.java
r18456 r19050 79 79 * @author Michael Zangl 80 80 */ 81 private class SelectionHintLayer extends AbstractMapViewPaintable {81 private final class SelectionHintLayer extends AbstractMapViewPaintable { 82 82 @Override 83 83 public void paint(Graphics2D g, MapView mv, Bounds bbox) { … … 186 186 if (e.getButton() == MouseEvent.BUTTON1 && e.getClickCount() > 1 && MainApplication.getLayerManager().getActiveDataSet() != null) { 187 187 SelectByInternalPointAction.performSelection(MainApplication.getMap().mapView.getEastNorth(e.getX(), e.getY()), 188 (e.getModifiersEx() & MouseEvent.SHIFT_DOWN_MASK) != 0,188 (e.getModifiersEx() & InputEvent.SHIFT_DOWN_MASK) != 0, 189 189 (e.getModifiersEx() & PlatformManager.getPlatform().getMenuShortcutKeyMaskEx()) != 0); 190 190 } else if (e.getButton() == MouseEvent.BUTTON1) { … … 201 201 @Override 202 202 public void mouseDragged(MouseEvent e) { 203 int buttonPressed = e.getModifiersEx() & ( MouseEvent.BUTTON1_DOWN_MASK | MouseEvent.BUTTON3_DOWN_MASK);203 int buttonPressed = e.getModifiersEx() & (InputEvent.BUTTON1_DOWN_MASK | InputEvent.BUTTON3_DOWN_MASK); 204 204 205 205 if (buttonPressed != 0) { … … 210 210 } 211 211 212 if (buttonPressed == MouseEvent.BUTTON1_DOWN_MASK) {212 if (buttonPressed == InputEvent.BUTTON1_DOWN_MASK) { 213 213 mousePos = e.getPoint(); 214 214 addLassoPoint(e.getPoint()); 215 215 selectionAreaChanged(); 216 } else if (buttonPressed == ( MouseEvent.BUTTON1_DOWN_MASK | MouseEvent.BUTTON3_DOWN_MASK)) {216 } else if (buttonPressed == (InputEvent.BUTTON1_DOWN_MASK | InputEvent.BUTTON3_DOWN_MASK)) { 217 217 moveSelection(e.getX()-mousePos.x, e.getY()-mousePos.y); 218 218 mousePos = e.getPoint(); … … 253 253 254 254 // Left mouse was released while right is still pressed. 255 boolean rightMouseStillPressed = (e.getModifiersEx() & MouseEvent.BUTTON3_DOWN_MASK) != 0;255 boolean rightMouseStillPressed = (e.getModifiersEx() & InputEvent.BUTTON3_DOWN_MASK) != 0; 256 256 257 257 if (!rightMouseStillPressed) { … … 317 317 @Override 318 318 public void propertyChange(PropertyChangeEvent evt) { 319 if ("active".equals(evt.getPropertyName()) && !(Boolean) evt.getNewValue()) {319 if ("active".equals(evt.getPropertyName()) && Boolean.FALSE.equals(evt.getNewValue())) { 320 320 abortSelecting(); 321 321 }
Note:
See TracChangeset
for help on using the changeset viewer.