Index: /applications/editors/josm/plugins/turnrestrictions/src/org/openstreetmap/josm/plugins/turnrestrictions/TurnRestrictionBuilder.java
===================================================================
--- /applications/editors/josm/plugins/turnrestrictions/src/org/openstreetmap/josm/plugins/turnrestrictions/TurnRestrictionBuilder.java	(revision 30364)
+++ /applications/editors/josm/plugins/turnrestrictions/src/org/openstreetmap/josm/plugins/turnrestrictions/TurnRestrictionBuilder.java	(revision 30365)
@@ -24,45 +24,45 @@
  */
 public class TurnRestrictionBuilder {
-	
-	/**
-	 * Replies the angle phi in the polar coordinates (r,phi) representing the first
-	 * segment of the way {@code w}, where w is moved such that the start node of {@code w} is
-	 * in the origin (0,0).
-	 *  
-	 * @param w the way.  Must not be null. At least two nodes required. 
-	 * @return phi in the polar coordinates 
-	 * @throws IllegalArgumentException thrown if w is null
-	 * @throws IllegalArgumentException thrown if w is too short (at least two nodes required)
-	 */
+    
+    /**
+     * Replies the angle phi in the polar coordinates (r,phi) representing the first
+     * segment of the way {@code w}, where w is moved such that the start node of {@code w} is
+     * in the origin (0,0).
+     *  
+     * @param w the way.  Must not be null. At least two nodes required. 
+     * @return phi in the polar coordinates 
+     * @throws IllegalArgumentException thrown if w is null
+     * @throws IllegalArgumentException thrown if w is too short (at least two nodes required)
+     */
     static public double phi(Way w) throws IllegalArgumentException{
-    	return phi(w, false /* not inverse */);
+        return phi(w, false /* not inverse */);
     }
     
     /**
      * <p>Replies the angle phi in the polar coordinates (r,phi) representing the first
-	 * segment of the way {@code w}, where w is moved such that the start node of {@code w} is
-	 * in the origin (0,0).</p>
-	 * 
-	 * <p>If {@code doInvert} is true, computes phi for the way in reversed direction.</p>
-	 * 
-	 * @param w the way.  Must not be null. At least two nodes required.
-	 * @param doInvert if true, computes phi for the reversed way 
-	 * @return phi in the polar coordinates 
-	 * @throws IllegalArgumentException thrown if w is null
-	 * @throws IllegalArgumentException thrown if w is too short (at least two nodes required)
+     * segment of the way {@code w}, where w is moved such that the start node of {@code w} is
+     * in the origin (0,0).</p>
+     * 
+     * <p>If {@code doInvert} is true, computes phi for the way in reversed direction.</p>
+     * 
+     * @param w the way.  Must not be null. At least two nodes required.
+     * @param doInvert if true, computes phi for the reversed way 
+     * @return phi in the polar coordinates 
+     * @throws IllegalArgumentException thrown if w is null
+     * @throws IllegalArgumentException thrown if w is too short (at least two nodes required)
      */
     static public double phi(Way w, boolean doInvert) throws IllegalArgumentException {
-    	CheckParameterUtil.ensureParameterNotNull(w, "w");
-    	if (w.getNodesCount() < 2) {
-    		throw new IllegalArgumentException("can't compute phi for way with less than 2 nodes");
-    	}
-    	List<Node> nodes = w.getNodes();
-    	if (doInvert) Collections.reverse(nodes);
-    	Node n0 = nodes.get(0);
-    	Node n1 = nodes.get(1);
-    	
-    	double x = n1.getCoor().getX() - n0.getCoor().getX();
-    	double y = n1.getCoor().getY() - n0.getCoor().getY();
-    	return Math.atan2(y, x);  	
+        CheckParameterUtil.ensureParameterNotNull(w, "w");
+        if (w.getNodesCount() < 2) {
+            throw new IllegalArgumentException("can't compute phi for way with less than 2 nodes");
+        }
+        List<Node> nodes = w.getNodes();
+        if (doInvert) Collections.reverse(nodes);
+        Node n0 = nodes.get(0);
+        Node n1 = nodes.get(1);
+        
+        double x = n1.getCoor().getX() - n0.getCoor().getX();
+        double y = n1.getCoor().getY() - n0.getCoor().getY();
+        return Math.atan2(y, x);      
     }    
 
@@ -77,8 +77,8 @@
      */
     static public Node getUniqueCommonNode(Way w1, Way w2) throws IllegalArgumentException{
-    	Set<Node> w1Nodes = new HashSet<Node>(w1.getNodes());
-    	w1Nodes.retainAll(w2.getNodes());
-    	if (w1Nodes.size() != 1) return null;
-    	return w1Nodes.iterator().next();
+        Set<Node> w1Nodes = new HashSet<Node>(w1.getNodes());
+        w1Nodes.retainAll(w2.getNodes());
+        if (w1Nodes.size() != 1) return null;
+        return w1Nodes.iterator().next();
     }   
         
@@ -91,6 +91,6 @@
      */
     static public boolean isStartNode(Way w, Node n) {
-    	if (w.getNodesCount() == 0) return false;
-    	return w.getNode(0).equals(n);
+        if (w.getNodesCount() == 0) return false;
+        return w.getNode(0).equals(n);
     }
         
@@ -103,6 +103,6 @@
      */
     static public boolean isEndNode(Way w, Node n){
-    	if (w.getNodesCount() == 0) return false;
-    	return w.getNode(w.getNodesCount()-1).equals(n);
+        if (w.getNodesCount() == 0) return false;
+        return w.getNode(w.getNodesCount()-1).equals(n);
     }
     
@@ -116,8 +116,8 @@
      */
     static public boolean isInnerNode(Way w, Node n){
-    	if (!w.getNodes().contains(n)) return false;
-    	if (isStartNode(w, n)) return false;
-    	if (isEndNode(w, n)) return false;
-    	return true;     	
+        if (!w.getNodes().contains(n)) return false;
+        if (isStartNode(w, n)) return false;
+        if (isEndNode(w, n)) return false;
+        return true;         
     }
     
@@ -140,19 +140,19 @@
      */
     static public double intersectionAngle(Way from, Way to) throws IllegalArgumentException {
-	    Node via = getUniqueCommonNode(from, to);
-	    if (via == null) 
-	    	throw new IllegalArgumentException("the two ways must share exactly one common node"); // no I18n required
-	    if (!isStartNode(from, via) && ! isEndNode(from, via)) 
-	    	throw new IllegalArgumentException("via node must be start or end node of from-way"); // no I18n required
-	    if (!isStartNode(to, via) && ! isEndNode(to, via)) 
-	    	throw new IllegalArgumentException("via node must be start or end node of to-way"); // no I18n required
-	    double phi1 = phi(from, isStartNode(from, via));
-	    double phi2 = phi(to, isEndNode(to, via));		
-		return phi1 - phi2;
+        Node via = getUniqueCommonNode(from, to);
+        if (via == null)
+            throw new IllegalArgumentException("the two ways must share exactly one common node"); // no I18n required
+        if (!isStartNode(from, via) && ! isEndNode(from, via))
+            throw new IllegalArgumentException("via node must be start or end node of from-way"); // no I18n required
+        if (!isStartNode(to, via) && ! isEndNode(to, via))
+            throw new IllegalArgumentException("via node must be start or end node of to-way"); // no I18n required
+        double phi1 = phi(from, isStartNode(from, via));
+        double phi2 = phi(to, isEndNode(to, via));
+        return phi1 - phi2;
     }   
         
     static public enum RelativeWayJoinOrientation {
-    	LEFT,
-    	RIGHT
+        LEFT,
+        RIGHT
     }
     /**
@@ -188,18 +188,18 @@
      */
     public static RelativeWayJoinOrientation determineWayJoinOrientation(Way from, Way to){
-    	Node via = getUniqueCommonNode(from, to);
-    	if (via == null) return null;
-    	if (!isConnectingNode(from, to, via)) return null;
-    	// if either w1 or w2 are closed at the via node, we can't determine automatically
-    	// whether the connection at "via" is a "left turn" or a "right turn"
-    	if (isClosedAt(from, via)) return null;
-    	if (isClosedAt(to, via)) return null;
-    	
-    	double phi = intersectionAngle(from, to);    	
-    	if (phi >=0 && phi <= Math.PI) {
-    		return RelativeWayJoinOrientation.RIGHT;
-    	} else {
-    		return RelativeWayJoinOrientation.LEFT;
-    	} 
+        Node via = getUniqueCommonNode(from, to);
+        if (via == null) return null;
+        if (!isConnectingNode(from, to, via)) return null;
+        // if either w1 or w2 are closed at the via node, we can't determine automatically
+        // whether the connection at "via" is a "left turn" or a "right turn"
+        if (isClosedAt(from, via)) return null;
+        if (isClosedAt(to, via)) return null;
+        
+        double phi = intersectionAngle(from, to);
+        if (phi >=0 && phi <= Math.PI) {
+            return RelativeWayJoinOrientation.RIGHT;
+        } else {
+            return RelativeWayJoinOrientation.LEFT;
+        } 
     }
     
@@ -241,41 +241,41 @@
      */
     static public Way selectToWayAfterSplit(Way from, Way to1, Way to2, TurnRestrictionType restrictionType){
-    	if (restrictionType == null) return null;
-    	Node cn1 = TurnRestrictionBuilder.getUniqueCommonNode(from, to1);
-    	if (cn1 == null) return null;
-    	Node cn2 = TurnRestrictionBuilder.getUniqueCommonNode(from, to2);
-    	if (cn2 == null) return null;
-    	if (cn1 != cn2) return null;        	
-    	
-    	if (! isStartNode(from, cn1) && ! isEndNode(from, cn1)) {
-    		/*
-    		 * the now split to-way still *intersects* the from-way. We
-    		 * can't adjust the split decisions. 
-    		 */
-    		return null;
-    	}
-    	
-    	RelativeWayJoinOrientation o1 = determineWayJoinOrientation(from, to1);
-    	RelativeWayJoinOrientation o2 = determineWayJoinOrientation(from, to2);
-    	
+        if (restrictionType == null) return null;
+        Node cn1 = TurnRestrictionBuilder.getUniqueCommonNode(from, to1);
+        if (cn1 == null) return null;
+        Node cn2 = TurnRestrictionBuilder.getUniqueCommonNode(from, to2);
+        if (cn2 == null) return null;
+        if (cn1 != cn2) return null;
+        
+        if (! isStartNode(from, cn1) && ! isEndNode(from, cn1)) {
+            /*
+             * the now split to-way still *intersects* the from-way. We
+             * can't adjust the split decisions.
+             */
+            return null;
+        }
+        
+        RelativeWayJoinOrientation o1 = determineWayJoinOrientation(from, to1);
+        RelativeWayJoinOrientation o2 = determineWayJoinOrientation(from, to2);
+        
         switch(restrictionType){
         case NO_LEFT_TURN:
         case ONLY_LEFT_TURN:
-        	if (RelativeWayJoinOrientation.LEFT.equals(o1)) return to1;
-        	else if (RelativeWayJoinOrientation.LEFT.equals(o2)) return to2;
-        	else return null;
-        	
+            if (RelativeWayJoinOrientation.LEFT.equals(o1)) return to1;
+            else if (RelativeWayJoinOrientation.LEFT.equals(o2)) return to2;
+            else return null;
+            
         case NO_RIGHT_TURN:
         case ONLY_RIGHT_TURN:
-        	if (RelativeWayJoinOrientation.RIGHT.equals(o1)) return to1;
-        	else if (RelativeWayJoinOrientation.RIGHT.equals(o2)) return to2;
-        	else return null;
-        	
+            if (RelativeWayJoinOrientation.RIGHT.equals(o1)) return to1;
+            else if (RelativeWayJoinOrientation.RIGHT.equals(o2)) return to2;
+            else return null;
+            
         default:
-	       	 /*
-	       	  * For restriction types like NO_U_TURN, NO_STRAIGHT_ON, etc. we
-	       	  * can select a "left" or "right" way after splitting.
-	       	  */
-        	return null;
+                /*
+                 * For restriction types like NO_U_TURN, NO_STRAIGHT_ON, etc. we
+                 * can select a "left" or "right" way after splitting.
+                 */
+            return null;
         }
     }
@@ -308,25 +308,25 @@
      */
     protected Relation initNoUTurnRestriction(List<OsmPrimitive> primitives) {
-    	if (primitives.size() != 2) return null;
-    	    	
-    	// we need exactly one node and one way in the selection ...
-    	List<Node> nodes = OsmPrimitive.getFilteredList(primitives, Node.class);
-    	List<Way> ways = OsmPrimitive.getFilteredList(primitives, Way.class);
-    	if (nodes.size() != 1 || ways.size() != 1) return null;
-    	
-    	// .. and the node has to be the start or the node of the way
-    	Way way = ways.get(0);
-    	Node node = nodes.get(0);
-    	List<Node> wayNodes = way.getNodes();
-    	if (wayNodes.size() < 2) return null; // shouldn't happen - just in case
-    	if (! (wayNodes.get(0).equals(node) ||wayNodes.get(wayNodes.size()-1).equals(node))) return null;
-
-    	Relation tr = new Relation();
-    	tr.put("type", "restriction");
-    	tr.addMember(new RelationMember("from", way));
-    	tr.addMember(new RelationMember("to", way));
-    	tr.addMember(new RelationMember("via", node));
-    	tr.put("restriction", TurnRestrictionType.NO_U_TURN.getTagValue());
-    	return tr;    	
+        if (primitives.size() != 2) return null;
+                
+        // we need exactly one node and one way in the selection ...
+        List<Node> nodes = OsmPrimitive.getFilteredList(primitives, Node.class);
+        List<Way> ways = OsmPrimitive.getFilteredList(primitives, Way.class);
+        if (nodes.size() != 1 || ways.size() != 1) return null;
+        
+        // .. and the node has to be the start or the node of the way
+        Way way = ways.get(0);
+        Node node = nodes.get(0);
+        List<Node> wayNodes = way.getNodes();
+        if (wayNodes.size() < 2) return null; // shouldn't happen - just in case
+        if (! (wayNodes.get(0).equals(node) ||wayNodes.get(wayNodes.size()-1).equals(node))) return null;
+
+        Relation tr = new Relation();
+        tr.put("type", "restriction");
+        tr.addMember(new RelationMember("from", way));
+        tr.addMember(new RelationMember("to", way));
+        tr.addMember(new RelationMember("via", node));
+        tr.put("restriction", TurnRestrictionType.NO_U_TURN.getTagValue());
+        return tr;
     }
 
@@ -344,10 +344,10 @@
      */
     public static boolean isConnectingNode(Way w1, Way w2, Node n){
-    	if (isStartNode(w1, n)) {
-    		return isStartNode(w2, n)  | isEndNode(w2, n);
-    	} else if (isEndNode(w1, n)){
-    		return isStartNode(w2, n)  | isEndNode(w2, n);
-    	}
-    	return false;
+        if (isStartNode(w1, n)) {
+            return isStartNode(w2, n)  | isEndNode(w2, n);
+        } else if (isEndNode(w1, n)){
+            return isStartNode(w2, n)  | isEndNode(w2, n);
+        }
+        return false;
     }
     
@@ -360,71 +360,71 @@
      */
     public static boolean isClosedAt(Way w, Node n){
-    	List<Node> nodes = w.getNodes();
-    	nodes.retainAll(Collections.singletonList(n));
-    	return nodes.size() >= 2;
+        List<Node> nodes = w.getNodes();
+        nodes.retainAll(Collections.singletonList(n));
+        return nodes.size() >= 2;
     }
    
     protected Relation initTurnRestrictionFromTwoWays(List<OsmPrimitive> primitives) {
-    	Way w1 = null;
-    	Way w2 = null;
-    	Node via = null;
-    	if (primitives.size() == 2) {
-    		// if we have exactly two selected primitives, we expect two ways. 
-    		// See initNoUTurnRestriction() for the case where we have a selected way
-    		// and a selected node
-    		List<Way> selWays = OsmPrimitive.getFilteredList(primitives, Way.class);
-    		if (selWays.size() != 2) return null;
-    		w1 = selWays.get(0);
-    		w2 = selWays.get(1);
-    		via = getUniqueCommonNode(w1, w2);    		
-    	} else if (primitives.size() == 3){
-    		// if we have exactly three selected primitives, we need two ways and a 
-    		// node, which should be an acceptable via node 
-    		List<Way> selWays = OsmPrimitive.getFilteredList(primitives, Way.class);
-    		List<Node> selNodes = OsmPrimitive.getFilteredList(primitives, Node.class);
-    		if (selWays.size() != 2) return null;
-    		if (selNodes.size() != 1) return null;
-    		w1 = selWays.get(0);
-    		w2 = selWays.get(1);
-    		via = selNodes.get(0);
-    		if (! w1.getNodes().contains(via) || ! w2.getNodes().contains(via)){
-    			// the selected node is not an acceptable via node
-    			via = null;
-    		}
-    	} else {
-    		// the selection doesn't consists of primitives for which we can build
-    		// a turn restriction 
-    		return null;
-    	}
-    	
-    	// if we get here, we know the two "legs" of the turn restriction. We may
-    	// or may not know a via node, though
-    	assert w1 != null;
-    	assert w2 != null;
-    	
-    	Relation tr = new Relation();
-    	tr.put("type", "restriction");
-    	tr.addMember(new RelationMember("from", w1));
-    	tr.addMember(new RelationMember("to", w2));
-    	
-    	if (via != null){
-    		tr.addMember(new RelationMember("via", via));
-    		RelativeWayJoinOrientation orientation = determineWayJoinOrientation(w1, w2);
-    		if (orientation != null){
-    			switch(orientation){
-    			case LEFT:
-    				tr.put("restriction", TurnRestrictionType.NO_LEFT_TURN.getTagValue());
-    				break;
-    			case RIGHT:
-    				tr.put("restriction", TurnRestrictionType.NO_RIGHT_TURN.getTagValue());
-    				break;    				
-    			}
-    		}
-    	}
-    	return tr;
+        Way w1 = null;
+        Way w2 = null;
+        Node via = null;
+        if (primitives.size() == 2) {
+            // if we have exactly two selected primitives, we expect two ways. 
+            // See initNoUTurnRestriction() for the case where we have a selected way
+            // and a selected node
+            List<Way> selWays = OsmPrimitive.getFilteredList(primitives, Way.class);
+            if (selWays.size() != 2) return null;
+            w1 = selWays.get(0);
+            w2 = selWays.get(1);
+            via = getUniqueCommonNode(w1, w2);
+        } else if (primitives.size() == 3){
+            // if we have exactly three selected primitives, we need two ways and a 
+            // node, which should be an acceptable via node 
+            List<Way> selWays = OsmPrimitive.getFilteredList(primitives, Way.class);
+            List<Node> selNodes = OsmPrimitive.getFilteredList(primitives, Node.class);
+            if (selWays.size() != 2) return null;
+            if (selNodes.size() != 1) return null;
+            w1 = selWays.get(0);
+            w2 = selWays.get(1);
+            via = selNodes.get(0);
+            if (! w1.getNodes().contains(via) || ! w2.getNodes().contains(via)){
+                // the selected node is not an acceptable via node
+                via = null;
+            }
+        } else {
+            // the selection doesn't consists of primitives for which we can build
+            // a turn restriction 
+            return null;
+        }
+        
+        // if we get here, we know the two "legs" of the turn restriction. We may
+        // or may not know a via node, though
+        assert w1 != null;
+        assert w2 != null;
+        
+        Relation tr = new Relation();
+        tr.put("type", "restriction");
+        tr.addMember(new RelationMember("from", w1));
+        tr.addMember(new RelationMember("to", w2));
+        
+        if (via != null){
+            tr.addMember(new RelationMember("via", via));
+            RelativeWayJoinOrientation orientation = determineWayJoinOrientation(w1, w2);
+            if (orientation != null){
+                switch(orientation){
+                case LEFT:
+                    tr.put("restriction", TurnRestrictionType.NO_LEFT_TURN.getTagValue());
+                    break;
+                case RIGHT:
+                    tr.put("restriction", TurnRestrictionType.NO_RIGHT_TURN.getTagValue());
+                    break;                    
+                }
+            }
+        }
+        return tr;
     }
        
     protected Relation initEmptyTurnRestriction() {
-	   Relation tr = new Relation();
+       Relation tr = new Relation();
        tr.put("type", "restriction");
        return tr;
@@ -441,5 +441,5 @@
     public synchronized Relation build(List<OsmPrimitive> primitives){
         if (primitives == null || primitives.isEmpty()) {
-        	return initEmptyTurnRestriction();
+            return initEmptyTurnRestriction();
         }
         Relation tr;
@@ -447,23 +447,23 @@
         // case 0 already handled 
         case 1: 
-        	tr = initEmptyTurnRestriction();
-        	if (OsmPrimitive.getFilteredList(primitives, Way.class).size() == 1) {     
-        		// we have exactly one selected way? -> init the "from" leg
-        		// of the turn restriction with it
-        		tr.addMember(new RelationMember("from", primitives.get(0)));
-        	}
-        	return tr;
-        	
+            tr = initEmptyTurnRestriction();
+            if (OsmPrimitive.getFilteredList(primitives, Way.class).size() == 1) {     
+                // we have exactly one selected way? -> init the "from" leg
+                // of the turn restriction with it
+                tr.addMember(new RelationMember("from", primitives.get(0)));
+            }
+            return tr;
+            
         case 2:
-        	tr = initNoUTurnRestriction(primitives);
-        	if (tr != null) return tr;
-        	tr = initTurnRestrictionFromTwoWays(primitives);
-        	if (tr != null) return tr;
-        	return initEmptyTurnRestriction();       
-        	
-        default:        	
-        	tr = initTurnRestrictionFromTwoWays(primitives);
-        	if (tr != null) return tr;
-        	return initEmptyTurnRestriction();       
+            tr = initNoUTurnRestriction(primitives);
+            if (tr != null) return tr;
+            tr = initTurnRestrictionFromTwoWays(primitives);
+            if (tr != null) return tr;
+            return initEmptyTurnRestriction();
+            
+        default:
+            tr = initTurnRestrictionFromTwoWays(primitives);
+            if (tr != null) return tr;
+            return initEmptyTurnRestriction();       
         }
     }       
Index: /applications/editors/josm/plugins/turnrestrictions/src/org/openstreetmap/josm/plugins/turnrestrictions/editor/BasicEditorPanel.java
===================================================================
--- /applications/editors/josm/plugins/turnrestrictions/src/org/openstreetmap/josm/plugins/turnrestrictions/editor/BasicEditorPanel.java	(revision 30364)
+++ /applications/editors/josm/plugins/turnrestrictions/src/org/openstreetmap/josm/plugins/turnrestrictions/editor/BasicEditorPanel.java	(revision 30365)
@@ -92,7 +92,7 @@
         DefaultListSelectionModel selectionModel = new DefaultListSelectionModel();
         spVias = new JScrollPane(lstVias = new ViaList(new ViaListModel(model, selectionModel), selectionModel)) {
-        	// fixes #6016 : Scrollbar hides field entry
-        	public Dimension getPreferredSize() {
-        		return new Dimension(100, 80); // only height is relevant, 80 is just a heuristical value
+            // fixes #6016 : Scrollbar hides field entry
+            public Dimension getPreferredSize() {
+                return new Dimension(100, 80); // only height is relevant, 80 is just a heuristical value
              }
         };
Index: /applications/editors/josm/plugins/turnrestrictions/src/org/openstreetmap/josm/plugins/turnrestrictions/editor/JosmSelectionListModel.java
===================================================================
--- /applications/editors/josm/plugins/turnrestrictions/src/org/openstreetmap/josm/plugins/turnrestrictions/editor/JosmSelectionListModel.java	(revision 30364)
+++ /applications/editors/josm/plugins/turnrestrictions/src/org/openstreetmap/josm/plugins/turnrestrictions/editor/JosmSelectionListModel.java	(revision 30365)
@@ -119,5 +119,5 @@
         // select it in the list of selected JOSM objects too. 
         if (getSelected().isEmpty() && this.selection.size() == 1) {
-        	setSelected(this.selection);
+            setSelected(this.selection);
         }
     }
@@ -143,5 +143,5 @@
         
     public ListSelectionModel getListSelectionModel() {
-    	return selectionModel;
+        return selectionModel;
     }
 
Index: /applications/editors/josm/plugins/turnrestrictions/src/org/openstreetmap/josm/plugins/turnrestrictions/editor/RelationMemberEditorModel.java
===================================================================
--- /applications/editors/josm/plugins/turnrestrictions/src/org/openstreetmap/josm/plugins/turnrestrictions/editor/RelationMemberEditorModel.java	(revision 30364)
+++ /applications/editors/josm/plugins/turnrestrictions/src/org/openstreetmap/josm/plugins/turnrestrictions/editor/RelationMemberEditorModel.java	(revision 30365)
@@ -445,5 +445,5 @@
 
     public int getRowCount() {
-    	return members.size();
+        return members.size();
     }
 
Index: /applications/editors/josm/plugins/turnrestrictions/src/org/openstreetmap/josm/plugins/turnrestrictions/editor/TurnRestrictionEditorModel.java
===================================================================
--- /applications/editors/josm/plugins/turnrestrictions/src/org/openstreetmap/josm/plugins/turnrestrictions/editor/TurnRestrictionEditorModel.java	(revision 30364)
+++ /applications/editors/josm/plugins/turnrestrictions/src/org/openstreetmap/josm/plugins/turnrestrictions/editor/TurnRestrictionEditorModel.java	(revision 30365)
@@ -94,5 +94,5 @@
      */
     public JosmSelectionListModel getJosmSelectionListModel() {
-    	return selectionModel;
+        return selectionModel;
     }
     
Index: /applications/editors/josm/plugins/turnrestrictions/src/org/openstreetmap/josm/plugins/turnrestrictions/editor/TurnRestrictionLegEditor.java
===================================================================
--- /applications/editors/josm/plugins/turnrestrictions/src/org/openstreetmap/josm/plugins/turnrestrictions/editor/TurnRestrictionLegEditor.java	(revision 30364)
+++ /applications/editors/josm/plugins/turnrestrictions/src/org/openstreetmap/josm/plugins/turnrestrictions/editor/TurnRestrictionLegEditor.java	(revision 30365)
@@ -278,28 +278,28 @@
      */
     class AcceptAction extends AbstractAction implements ListSelectionListener {
-    	
-    	public AcceptAction() {
-			 putValue(SHORT_DESCRIPTION, tr("Accept the currently selected way"));
-	         putValue(NAME, tr("Accept"));
-	         putValue(SMALL_ICON, ImageProvider.get("accept"));
-	         model.getJosmSelectionListModel().getListSelectionModel().addListSelectionListener(this);
-	         updateEnabledState();	         
-    	}
-    	
-    	 public void actionPerformed(ActionEvent e) {
-    		 List<Way> selWays = OsmPrimitive.getFilteredList(model.getJosmSelectionListModel().getSelected(), Way.class);
-    		 if (selWays.size() != 1) return;
-    		 Way w = selWays.get(0);    		 
+        
+        public AcceptAction() {
+             putValue(SHORT_DESCRIPTION, tr("Accept the currently selected way"));
+             putValue(NAME, tr("Accept"));
+             putValue(SMALL_ICON, ImageProvider.get("accept"));
+             model.getJosmSelectionListModel().getListSelectionModel().addListSelectionListener(this);
+             updateEnabledState();
+        }
+        
+         public void actionPerformed(ActionEvent e) {
+             List<Way> selWays = OsmPrimitive.getFilteredList(model.getJosmSelectionListModel().getSelected(), Way.class);
+             if (selWays.size() != 1) return;
+             Way w = selWays.get(0);
              model.setTurnRestrictionLeg(role, w);            
          }       
          
          public void updateEnabledState() {
-        	setEnabled(OsmPrimitive.getFilteredList(model.getJosmSelectionListModel().getSelected(), Way.class).size() == 1);
+            setEnabled(OsmPrimitive.getFilteredList(model.getJosmSelectionListModel().getSelected(), Way.class).size() == 1);
          }
 
-		@Override
-		public void valueChanged(ListSelectionEvent e) {
-			updateEnabledState();
-		}
+        @Override
+        public void valueChanged(ListSelectionEvent e) {
+            updateEnabledState();
+        }
     }
     
Index: /applications/editors/josm/plugins/turnrestrictions/src/org/openstreetmap/josm/plugins/turnrestrictions/editor/VehicleExceptionEditor.java
===================================================================
--- /applications/editors/josm/plugins/turnrestrictions/src/org/openstreetmap/josm/plugins/turnrestrictions/editor/VehicleExceptionEditor.java	(revision 30364)
+++ /applications/editors/josm/plugins/turnrestrictions/src/org/openstreetmap/josm/plugins/turnrestrictions/editor/VehicleExceptionEditor.java	(revision 30365)
@@ -232,15 +232,15 @@
     
     protected void init() {
-    	try {
-    		// temporarily disable the checkbox listeners while initializing the
-    		// checkboxes with the input value
-    		this.svtChangeListener.setEnabled(false);
-	        cbPsv.setSelected(exceptValue.isVehicleException("psv"));
-	        cbBicyle.setSelected(exceptValue.isVehicleException("bicycle"));
-	        cbMotorcar.setSelected(exceptValue.isVehicleException("motorcar"));
-	        cbHgv.setSelected(exceptValue.isVehicleException("hgv"));
-    	} finally {
-    		this.svtChangeListener.setEnabled(true);
-    	}
+        try {
+            // temporarily disable the checkbox listeners while initializing the
+            // checkboxes with the input value
+            this.svtChangeListener.setEnabled(false);
+            cbPsv.setSelected(exceptValue.isVehicleException("psv"));
+            cbBicyle.setSelected(exceptValue.isVehicleException("bicycle"));
+            cbMotorcar.setSelected(exceptValue.isVehicleException("motorcar"));
+            cbHgv.setSelected(exceptValue.isVehicleException("hgv"));
+        } finally {
+            this.svtChangeListener.setEnabled(true);
+        }
         if (!exceptValue.isStandard()){
             rbNonStandardException.setSelected(true);
@@ -309,12 +309,12 @@
     
     class StandardVehicleTypeChangeListener implements ItemListener {
-    	private boolean enabled = true;
-    	
-    	public void setEnabled(boolean enabled){
-    		this.enabled = enabled;
-    	}
-    	
-        public void itemStateChanged(ItemEvent e) {        	
-        	if (!enabled) return;
+        private boolean enabled = true;
+        
+        public void setEnabled(boolean enabled){
+            this.enabled = enabled;
+        }
+        
+        public void itemStateChanged(ItemEvent e) {
+            if (!enabled) return;
             exceptValue.setVehicleException("bicycle", cbBicyle.isSelected());
             exceptValue.setVehicleException("hgv", cbHgv.isSelected());
Index: /applications/editors/josm/plugins/turnrestrictions/src/org/openstreetmap/josm/plugins/turnrestrictions/editor/ViaList.java
===================================================================
--- /applications/editors/josm/plugins/turnrestrictions/src/org/openstreetmap/josm/plugins/turnrestrictions/editor/ViaList.java	(revision 30364)
+++ /applications/editors/josm/plugins/turnrestrictions/src/org/openstreetmap/josm/plugins/turnrestrictions/editor/ViaList.java	(revision 30365)
@@ -93,5 +93,5 @@
     }
    
-	/**
+    /**
      * The transfer handler for Drag-and-Drop. 
      */
Index: /applications/editors/josm/plugins/turnrestrictions/src/org/openstreetmap/josm/plugins/turnrestrictions/qa/IssuesModel.java
===================================================================
--- /applications/editors/josm/plugins/turnrestrictions/src/org/openstreetmap/josm/plugins/turnrestrictions/qa/IssuesModel.java	(revision 30364)
+++ /applications/editors/josm/plugins/turnrestrictions/src/org/openstreetmap/josm/plugins/turnrestrictions/qa/IssuesModel.java	(revision 30365)
@@ -212,17 +212,17 @@
                 issues.add(new IntersectionMissingAsViaError(this, from, to, intersect));
             }
-        	if (isInnerNode(from, intersect) && isInnerNode(to, intersect)) {
-        		issues.add(new TurnRestrictionLegSplitRequiredError(this, from, to));
-        	} else if (isInnerNode(from, intersect) && ! isInnerNode(to, intersect)) {
-        		issues.add(new TurnRestrictionLegSplitRequiredError(this, TurnRestrictionLegRole.FROM, from, to, intersect));
-        	} else if (!isInnerNode(from, intersect) && isInnerNode(to, intersect)) {
-        		issues.add(new TurnRestrictionLegSplitRequiredError(this, TurnRestrictionLegRole.TO, from, to, intersect));
-        	}
+            if (isInnerNode(from, intersect) && isInnerNode(to, intersect)) {
+                issues.add(new TurnRestrictionLegSplitRequiredError(this, from, to));
+            } else if (isInnerNode(from, intersect) && ! isInnerNode(to, intersect)) {
+                issues.add(new TurnRestrictionLegSplitRequiredError(this, TurnRestrictionLegRole.FROM, from, to, intersect));
+            } else if (!isInnerNode(from, intersect) && isInnerNode(to, intersect)) {
+                issues.add(new TurnRestrictionLegSplitRequiredError(this, TurnRestrictionLegRole.TO, from, to, intersect));
+            }
         } else {
-        	if (editorModel.getVias().isEmpty() && ! from.equals(to)){
-        		// the two turn restriction legs aren't connected and we don't have configured
-        		// via objects 
-        		issues.add(new MissingViaError(this));
-        	}        	
+            if (editorModel.getVias().isEmpty() && ! from.equals(to)){
+                // the two turn restriction legs aren't connected and we don't have configured
+                // via objects 
+                issues.add(new MissingViaError(this));
+            }
         }               
     }
Index: /applications/editors/josm/plugins/turnrestrictions/src/org/openstreetmap/josm/plugins/turnrestrictions/qa/MissingViaError.java
===================================================================
--- /applications/editors/josm/plugins/turnrestrictions/src/org/openstreetmap/josm/plugins/turnrestrictions/qa/MissingViaError.java	(revision 30364)
+++ /applications/editors/josm/plugins/turnrestrictions/src/org/openstreetmap/josm/plugins/turnrestrictions/qa/MissingViaError.java	(revision 30365)
@@ -14,19 +14,19 @@
 public class MissingViaError extends Issue {
 
-	public MissingViaError(IssuesModel parent) throws IllegalArgumentException {
-		super(parent, Severity.WARNING);
-		actions.add(new FixAction());
-	}
+    public MissingViaError(IssuesModel parent) throws IllegalArgumentException {
+        super(parent, Severity.WARNING);
+        actions.add(new FixAction());
+    }
 
-	@Override
-	public String getText() {
-		 String msg = 
-			 tr("The two ways participating in the turn restriction <strong>aren''t connected.</strong>")
-			+ "<p>"
-			+ tr("Make sure you add one or more via objects (nodes or ways) to the turn restriction.");
-		 return msg;
-	}
+    @Override
+    public String getText() {
+         String msg = 
+             tr("The two ways participating in the turn restriction <strong>aren''t connected.</strong>")
+            + "<p>"
+            + tr("Make sure you add one or more via objects (nodes or ways) to the turn restriction.");
+         return msg;
+    }
 
-	class FixAction extends AbstractAction {
+    class FixAction extends AbstractAction {
         public FixAction() {
             putValue(NAME, tr("Fix in editor"));
Index: /applications/editors/josm/plugins/turnrestrictions/src/org/openstreetmap/josm/plugins/turnrestrictions/qa/TurnRestrictionLegSplitRequiredError.java
===================================================================
--- /applications/editors/josm/plugins/turnrestrictions/src/org/openstreetmap/josm/plugins/turnrestrictions/qa/TurnRestrictionLegSplitRequiredError.java	(revision 30364)
+++ /applications/editors/josm/plugins/turnrestrictions/src/org/openstreetmap/josm/plugins/turnrestrictions/qa/TurnRestrictionLegSplitRequiredError.java	(revision 30365)
@@ -28,6 +28,6 @@
  */
 public class TurnRestrictionLegSplitRequiredError extends Issue{
-	static private final Logger logger = Logger.getLogger(TurnRestrictionLegSplitRequiredError.class.getName());
-	
+    static private final Logger logger = Logger.getLogger(TurnRestrictionLegSplitRequiredError.class.getName());
+    
     private TurnRestrictionLegRole role;
     private Way from;
@@ -45,16 +45,16 @@
      */
     public TurnRestrictionLegSplitRequiredError(IssuesModel parent, Way from, Way to){
-    	super(parent, Severity.ERROR);
-    	CheckParameterUtil.ensureParameterNotNull(from, "from");
-    	CheckParameterUtil.ensureParameterNotNull(to, "to"); 
-    	
-    	intersect= TurnRestrictionBuilder.getUniqueCommonNode(from, to);
-    	if (intersect == null)
-    		throw new IllegalArgumentException("exactly one intersecting node required");
-    	
-    	this.from = from;
-    	this.to = to;
-    	this.role = null;
-    	actions.add(new SplitAction());
+        super(parent, Severity.ERROR);
+        CheckParameterUtil.ensureParameterNotNull(from, "from");
+        CheckParameterUtil.ensureParameterNotNull(to, "to");
+        
+        intersect= TurnRestrictionBuilder.getUniqueCommonNode(from, to);
+        if (intersect == null)
+            throw new IllegalArgumentException("exactly one intersecting node required");
+        
+        this.from = from;
+        this.to = to;
+        this.role = null;
+        actions.add(new SplitAction());
     }
 
@@ -81,12 +81,12 @@
         String msg = null;
         if (role == null){
-        	/*
-        	 * from and to intersect at a common node. Both have to be split.
-        	 */
-        	return tr("The way <span class=\"object-name\">{0}</span> with role <tt>from</tt> and the "
-        			+ "way <span class=\"object-name\">{1}</span> with role <tt>to</tt> intersect "        			
-        			+ "at node <span class=\"object-name\">{2}</span>. "
-        			+ "<p> "
-        			+ "Both ways should be split at the intersecting node.",
+            /*
+             * from and to intersect at a common node. Both have to be split.
+             */
+            return tr("The way <span class=\"object-name\">{0}</span> with role <tt>from</tt> and the "
+                    + "way <span class=\"object-name\">{1}</span> with role <tt>to</tt> intersect "                    
+                    + "at node <span class=\"object-name\">{2}</span>. "
+                    + "<p> "
+                    + "Both ways should be split at the intersecting node.",
                     from.getDisplayName(DefaultNameFormatter.getInstance()),
                     to.getDisplayName(DefaultNameFormatter.getInstance()),
@@ -96,7 +96,7 @@
         switch(role){
         case FROM:
-        	/*
-        	 * "to" joins "from" at a common node. Only from has to be split
-        	 */
+            /*
+             * "to" joins "from" at a common node. Only from has to be split
+             */
             msg = tr("The way <span class=\"object-name\">{0}</span> with role <tt>{1}</tt> should be split "
                 + "at node <span class=\"object-name\">{2}</span> where it connects to way <span class=\"object-name\">{3}</span>.",
@@ -108,7 +108,7 @@
             break;
         case TO:
-        	/*
-        	 * "from" joins "to" at a common node. Only to has to be split
-        	 */
+            /*
+             * "from" joins "to" at a common node. Only to has to be split
+             */
             msg = tr("The way <span class=\"object-name\">{0}</span> with role <tt>{1}</tt> should be split "
                     + "at node <span class=\"object-name\">{2}</span> where it connects to way <span class=\"object-name\">{3}</span>.",
@@ -131,7 +131,7 @@
         public void actionPerformed(ActionEvent e) {
 
-        	SplitWayResult result = null;
+            SplitWayResult result = null;
             if (role == null || role.equals(TurnRestrictionLegRole.FROM)){
-            	  result = SplitWayAction.split(
+                  result = SplitWayAction.split(
                           parent.getEditorModel().getLayer(),
                           from,
@@ -139,5 +139,5 @@
                           Collections.<OsmPrimitive>emptyList()
                   );
-            	  if (result != null){
+                  if (result != null){
                       Main.main.undoRedo.add(result.getCommand());
                   }
@@ -145,5 +145,5 @@
             
             if (role == null || role.equals(TurnRestrictionLegRole.TO)) {
-            	result = SplitWayAction.split(
+                result = SplitWayAction.split(
                         parent.getEditorModel().getLayer(),
                         to,
@@ -151,29 +151,29 @@
                         Collections.<OsmPrimitive>emptyList()
                 );
-            	if (result != null){
+                if (result != null){
                     Main.main.undoRedo.add(result.getCommand());
                 }
-            	if (result == null) return;
-	        	TurnRestrictionType restrictionType = TurnRestrictionType.fromTagValue(getIssuesModel().getEditorModel().getRestrictionTagValue());
-	            if (restrictionType == null) return;
-	            Way adjustedTo = TurnRestrictionBuilder.selectToWayAfterSplit(
-	            		 from,
-	            		 result.getOriginalWay(),
-	            		 result.getNewWays().get(0),
-	            		 restrictionType
-	            );
-	
-	            if (adjustedTo == null) return;
-	            getIssuesModel().getEditorModel().setTurnRestrictionLeg(
-	            		 TurnRestrictionLegRole.TO,
-	            		 adjustedTo
-	            );	     
-	            getIssuesModel().getEditorModel().getLayer().data.setSelected(
-	              		 Arrays.asList(from, adjustedTo)
-	             );	
+                if (result == null) return;
+                TurnRestrictionType restrictionType = TurnRestrictionType.fromTagValue(getIssuesModel().getEditorModel().getRestrictionTagValue());
+                if (restrictionType == null) return;
+                Way adjustedTo = TurnRestrictionBuilder.selectToWayAfterSplit(
+                         from,
+                         result.getOriginalWay(),
+                         result.getNewWays().get(0),
+                         restrictionType
+                );
+    
+                if (adjustedTo == null) return;
+                getIssuesModel().getEditorModel().setTurnRestrictionLeg(
+                         TurnRestrictionLegRole.TO,
+                         adjustedTo
+                );         
+                getIssuesModel().getEditorModel().getLayer().data.setSelected(
+                           Arrays.asList(from, adjustedTo)
+                 );    
             } else {
-	            getIssuesModel().getEditorModel().getLayer().data.setSelected(
-	              		 Arrays.asList(from, to)
-	             );	            	
+                getIssuesModel().getEditorModel().getLayer().data.setSelected(
+                           Arrays.asList(from, to)
+                 );
             }           
         }
Index: /applications/editors/josm/plugins/turnrestrictions/test/src/org/openstreetmap/josm/plugins/turnrestrictions/AllUnitTests.java
===================================================================
--- /applications/editors/josm/plugins/turnrestrictions/test/src/org/openstreetmap/josm/plugins/turnrestrictions/AllUnitTests.java	(revision 30364)
+++ /applications/editors/josm/plugins/turnrestrictions/test/src/org/openstreetmap/josm/plugins/turnrestrictions/AllUnitTests.java	(revision 30365)
@@ -7,6 +7,6 @@
 @RunWith(Suite.class)
 @Suite.SuiteClasses({
-	AllEditorTests.class,
-	TurnRestrictionBuilderTest.class
+    AllEditorTests.class,
+    TurnRestrictionBuilderTest.class
 })
 public class AllUnitTests {}
Index: /applications/editors/josm/plugins/turnrestrictions/test/src/org/openstreetmap/josm/plugins/turnrestrictions/editor/AllEditorTests.java
===================================================================
--- /applications/editors/josm/plugins/turnrestrictions/test/src/org/openstreetmap/josm/plugins/turnrestrictions/editor/AllEditorTests.java	(revision 30364)
+++ /applications/editors/josm/plugins/turnrestrictions/test/src/org/openstreetmap/josm/plugins/turnrestrictions/editor/AllEditorTests.java	(revision 30365)
@@ -8,10 +8,10 @@
 @RunWith(Suite.class)
 @Suite.SuiteClasses({
-	JosmSelectionListModelTest.class,
-	TurnRestrictionEditorModelUnitTest.class,
-	TurnRestrictionLegEditorUnitTest.class,
-	TurnRestrictionTypeRendererTest.class,
-	TurnRestrictionTypeTest.class,
-	ExceptValueModelTest.class
+    JosmSelectionListModelTest.class,
+    TurnRestrictionEditorModelUnitTest.class,
+    TurnRestrictionLegEditorUnitTest.class,
+    TurnRestrictionTypeRendererTest.class,
+    TurnRestrictionTypeTest.class,
+    ExceptValueModelTest.class
 })
 public class AllEditorTests extends TestCase{}
Index: /applications/editors/josm/plugins/turnrestrictions/test/src/org/openstreetmap/josm/plugins/turnrestrictions/fixtures/JOSMFixture.java
===================================================================
--- /applications/editors/josm/plugins/turnrestrictions/test/src/org/openstreetmap/josm/plugins/turnrestrictions/fixtures/JOSMFixture.java	(revision 30364)
+++ /applications/editors/josm/plugins/turnrestrictions/test/src/org/openstreetmap/josm/plugins/turnrestrictions/fixtures/JOSMFixture.java	(revision 30365)
@@ -69,6 +69,6 @@
         //
         String url = OsmApi.getOsmApi().getBaseUrl().toLowerCase().trim();
-        if (url.startsWith("http://www.openstreetmap.org")
-                || url.startsWith("http://api.openstreetmap.org")) {
+        if (url.startsWith("http://www.openstreetmap.org") || url.startsWith("http://api.openstreetmap.org")
+         || url.startsWith("https://www.openstreetmap.org") || url.startsWith("https://api.openstreetmap.org")) {
             fail(MessageFormat.format("configured server url ''{0}'' seems to be a productive url, aborting.", url));
         }
