Index: trunk/src/org/openstreetmap/josm/actions/mapmode/SelectAction.java
===================================================================
--- trunk/src/org/openstreetmap/josm/actions/mapmode/SelectAction.java	(revision 7539)
+++ trunk/src/org/openstreetmap/josm/actions/mapmode/SelectAction.java	(revision 7543)
@@ -67,7 +67,19 @@
  */
 public class SelectAction extends MapMode implements ModifierListener, KeyPressReleaseListener, SelectionEnded {
-    // "select" means the selection rectangle and "move" means either dragging
-    // or select if no mouse movement occurs (i.e. just clicking)
-    enum Mode { move, rotate, scale, select }
+
+    /**
+     * Select action mode.
+     * @since 7543
+     */
+    public enum Mode {
+        /** "MOVE" means either dragging or select if no mouse movement occurs (i.e. just clicking) */
+        MOVE,
+        /** "ROTATE" allows to apply a rotation transformation on the selected object (see {@link RotateCommand}) */
+        ROTATE,
+        /** "SCALE" allows to apply a scaling transformation on the selected object (see {@link ScaleCommand}) */
+        SCALE,
+        /** "SELECT" means the selection rectangle */
+        SELECT
+    }
 
     // contains all possible cases the cursor can be in the SelectAction
@@ -241,5 +253,5 @@
 
         virtualManager.clear();
-        if(mode == Mode.move) {
+        if(mode == Mode.MOVE) {
             if (!dragInProgress() && virtualManager.activateVirtualNodeNearPoint(e.getPoint())) {
                 DataSet ds = getCurrentDataSet();
@@ -256,5 +268,5 @@
 
         // return early if there can't be any highlights
-        if(!drawTargetHighlight || mode != Mode.move || c.isEmpty())
+        if(!drawTargetHighlight || mode != Mode.MOVE || c.isEmpty())
             return repaintIfRequired(newHighlights);
 
@@ -282,5 +294,5 @@
         String c = "rect";
         switch(mode) {
-        case move:
+        case MOVE:
             if(virtualManager.hasVirtualNode()) {
                 c = "virtual_node";
@@ -312,11 +324,11 @@
             }
             break;
-        case rotate:
+        case ROTATE:
             c = "rotate";
             break;
-        case scale:
+        case SCALE:
             c = "scale";
             break;
-        case select:
+        case SELECT:
             if (lassoMode) {
                 c = "lasso";
@@ -411,6 +423,6 @@
 
         switch(mode) {
-        case rotate:
-        case scale:
+        case ROTATE:
+        case SCALE:
             //  if nothing was selected, select primitive under cursor for scaling or rotating
             if (getCurrentDataSet().getSelected().isEmpty()) {
@@ -423,5 +435,5 @@
             // Mode.scale redraws here
             break;
-        case move:
+        case MOVE:
             // also include case when some primitive is under cursor and no shift+ctrl / alt+ctrl is pressed
             // so this is not movement, but selection on primitive under cursor
@@ -440,5 +452,5 @@
             }, false);
             break;
-        case select:
+        case SELECT:
         default:
             if (!(ctrl && Main.isPlatformOsx())) {
@@ -457,6 +469,6 @@
     @Override
     public void mouseMoved(MouseEvent e) {
-        // Mac OSX simulates with  ctrl + mouse 1  the second mouse button hence no dragging events get fired.
-        if (Main.isPlatformOsx() && (mode == Mode.rotate || mode == Mode.scale)) {
+        // Mac OSX simulates with ctrl + mouse 1 the second mouse button hence no dragging events get fired.
+        if (Main.isPlatformOsx() && (mode == Mode.ROTATE || mode == Mode.SCALE)) {
             mouseDragged(e);
             return;
@@ -484,5 +496,5 @@
 
         cancelDrawMode = true;
-        if (mode == Mode.select) {
+        if (mode == Mode.SELECT) {
             // Unregisters selectionManager if ctrl has been pressed after mouse click on Mac OS X in order to move the map
             if (ctrl && Main.isPlatformOsx()) {
@@ -496,8 +508,8 @@
 
         // do not count anything as a move if it lasts less than 100 milliseconds.
-        if ((mode == Mode.move) && (System.currentTimeMillis() - mouseDownTime < initialMoveDelay))
+        if ((mode == Mode.MOVE) && (System.currentTimeMillis() - mouseDownTime < initialMoveDelay))
             return;
 
-        if (mode != Mode.rotate && mode != Mode.scale) // button is pressed in rotate mode
+        if (mode != Mode.ROTATE && mode != Mode.SCALE) // button is pressed in rotate mode
         {
             if ((e.getModifiersEx() & MouseEvent.BUTTON1_DOWN_MASK) == 0)
@@ -505,5 +517,5 @@
         }
 
-        if (mode == Mode.move) {
+        if (mode == Mode.MOVE) {
             // If ctrl is pressed we are in merge mode. Look for a nearby node,
             // highlight it and adjust the cursor accordingly.
@@ -552,5 +564,5 @@
 
         mv.repaint();
-        if (mode != Mode.scale) {
+        if (mode != Mode.SCALE) {
             lastMousePos = e.getPoint();
         }
@@ -574,5 +586,5 @@
         mouseReleaseTime = System.currentTimeMillis();
 
-        if (mode == Mode.select) {
+        if (mode == Mode.SELECT) {
             selectionManager.unregister(mv);
 
@@ -585,5 +597,5 @@
         }
 
-        if (mode == Mode.move && e.getButton() == MouseEvent.BUTTON1) {
+        if (mode == Mode.MOVE && e.getButton() == MouseEvent.BUTTON1) {
             if (!didMouseDrag) {
                 // only built in move mode
@@ -658,11 +670,11 @@
     private void determineMapMode(boolean hasSelectionNearby) {
         if (shift && ctrl) {
-            mode = Mode.rotate;
+            mode = Mode.ROTATE;
         } else if (alt && ctrl) {
-            mode = Mode.scale;
+            mode = Mode.SCALE;
         } else if (hasSelectionNearby || dragInProgress()) {
-            mode = Mode.move;
+            mode = Mode.MOVE;
         } else {
-            mode = Mode.select;
+            mode = Mode.SELECT;
         }
     }
@@ -693,9 +705,9 @@
         Collection<Node> affectedNodes = AllNodesVisitor.getAllNodes(selection);
         // for these transformations, having only one node makes no sense - quit silently
-        if (affectedNodes.size() < 2 && (mode == Mode.rotate || mode == Mode.scale)) {
+        if (affectedNodes.size() < 2 && (mode == Mode.ROTATE || mode == Mode.SCALE)) {
             return false;
         }
         Command c = getLastCommand();
-        if (mode == Mode.move) {
+        if (mode == Mode.MOVE) {
             if (startEN == null) return false; // fix #8128
             getCurrentDataSet().beginUpdate();
@@ -725,5 +737,5 @@
             startEN = currentEN; // drag can continue after scaling/rotation
 
-            if (mode != Mode.rotate && mode != Mode.scale) {
+            if (mode != Mode.ROTATE && mode != Mode.SCALE) {
                 return false;
             }
@@ -731,5 +743,5 @@
             getCurrentDataSet().beginUpdate();
 
-            if (mode == Mode.rotate) {
+            if (mode == Mode.ROTATE) {
                 if (c instanceof RotateCommand && affectedNodes.equals(((RotateCommand) c).getTransformedNodes())) {
                     ((RotateCommand) c).handleEvent(currentEN);
@@ -737,5 +749,5 @@
                     Main.main.undoRedo.add(new RotateCommand(selection, currentEN));
                 }
-            } else if (mode == Mode.scale) {
+            } else if (mode == Mode.SCALE) {
                 if (c instanceof ScaleCommand && affectedNodes.equals(((ScaleCommand) c).getTransformedNodes())) {
                     ((ScaleCommand) c).handleEvent(currentEN);
@@ -897,16 +909,25 @@
     }
 
+    /**
+     * Returns the current select mode.
+     * @return the select mode
+     * @since 7543
+     */
+    public final Mode getMode() {
+        return mode;
+    }
+
     @Override
     public String getModeHelpText() {
         if (mouseDownButton == MouseEvent.BUTTON1 && mouseReleaseTime < mouseDownTime) {
-            if (mode == Mode.select)
+            if (mode == Mode.SELECT)
                 return tr("Release the mouse button to select the objects in the rectangle.");
-            else if (mode == Mode.move && (System.currentTimeMillis() - mouseDownTime >= initialMoveDelay)) {
+            else if (mode == Mode.MOVE && (System.currentTimeMillis() - mouseDownTime >= initialMoveDelay)) {
                 final boolean canMerge = getCurrentDataSet()!=null && !getCurrentDataSet().getSelectedNodes().isEmpty();
                 final String mergeHelp = canMerge ? (" " + tr("Ctrl to merge with nearest node.")) : "";
                 return tr("Release the mouse button to stop moving.") + mergeHelp;
-            } else if (mode == Mode.rotate)
+            } else if (mode == Mode.ROTATE)
                 return tr("Release the mouse button to stop rotating.");
-            else if (mode == Mode.scale)
+            else if (mode == Mode.SCALE)
                 return tr("Release the mouse button to stop scaling.");
         }
Index: trunk/src/org/openstreetmap/josm/gui/MapMover.java
===================================================================
--- trunk/src/org/openstreetmap/josm/gui/MapMover.java	(revision 7539)
+++ trunk/src/org/openstreetmap/josm/gui/MapMover.java	(revision 7543)
@@ -22,4 +22,5 @@
 
 import org.openstreetmap.josm.Main;
+import org.openstreetmap.josm.actions.mapmode.SelectAction;
 import org.openstreetmap.josm.data.coor.EastNorth;
 import org.openstreetmap.josm.tools.Destroyable;
@@ -83,5 +84,7 @@
 
     /**
-     * COnstructs a new {@code MapMover}.
+     * Constructs a new {@code MapMover}.
+     * @param navComp the navigatable component
+     * @param contentPane the content pane
      */
     public MapMover(NavigatableComponent navComp, JPanel contentPane) {
@@ -126,5 +129,5 @@
 
     /**
-     * If the right (and only the right) mouse button is pressed, move the map
+     * If the right (and only the right) mouse button is pressed, move the map.
      */
     @Override
@@ -132,6 +135,9 @@
         int offMask = MouseEvent.BUTTON1_DOWN_MASK | MouseEvent.BUTTON2_DOWN_MASK;
         int macMouseMask = MouseEvent.CTRL_DOWN_MASK | MouseEvent.BUTTON1_DOWN_MASK;
-        if ((e.getModifiersEx() & (MouseEvent.BUTTON3_DOWN_MASK | offMask)) == MouseEvent.BUTTON3_DOWN_MASK ||
-                Main.isPlatformOsx() && e.getModifiersEx() == macMouseMask) {
+        boolean stdMovement = (e.getModifiersEx() & (MouseEvent.BUTTON3_DOWN_MASK | offMask)) == MouseEvent.BUTTON3_DOWN_MASK;
+        boolean macMovement = Main.isPlatformOsx() && e.getModifiersEx() == macMouseMask;
+        boolean allowedMode = !Main.map.mapModeSelect.equals(Main.map.mapMode)
+                          || Main.map.mapModeSelect.getMode().equals(SelectAction.Mode.SELECT);
+        if (stdMovement || (macMovement && allowedMode)) {
             if (mousePosMove == null)
                 startMovement(e);
