Index: applications/editors/josm/plugins/alignways/src/org/openstreetmap/josm/plugins/alignways/AlignWaysAction.java
===================================================================
--- applications/editors/josm/plugins/alignways/src/org/openstreetmap/josm/plugins/alignways/AlignWaysAction.java	(revision 22837)
+++ applications/editors/josm/plugins/alignways/src/org/openstreetmap/josm/plugins/alignways/AlignWaysAction.java	(revision 22842)
@@ -78,7 +78,7 @@
 		if (!c.areSegsAlignable()) {
 			JOptionPane.showMessageDialog(Main.parent,
-					tr("Please select two segments that don''t share any nodes or put the pivot on their common node.\n" +
-					"Your action is being igonred."),
-					tr("AlignWayS: Alignment not possible"), JOptionPane.WARNING_MESSAGE);
+					tr("Please select two segments that don''t share any nodes\n"
+							+ " or put the pivot on their common node.\n"),
+							tr("AlignWayS: Alignment not possible"), JOptionPane.WARNING_MESSAGE);
 			return false;
 		}
@@ -90,7 +90,6 @@
 				(c).undoCommand();
 				JOptionPane.showMessageDialog(Main.parent,
-						tr("Aligning would result nodes outside the world.\n" +
-						"Your action is being ignored."),
-						tr("AlignWayS: Alignment denied"), JOptionPane.WARNING_MESSAGE);
+						tr("Aligning would result nodes outside the world.\n"),
+						tr("AlignWayS: Alignment not possible"), JOptionPane.WARNING_MESSAGE);
 				return false;
 			}
Index: applications/editors/josm/plugins/alignways/src/org/openstreetmap/josm/plugins/alignways/AlignWaysMode.java
===================================================================
--- applications/editors/josm/plugins/alignways/src/org/openstreetmap/josm/plugins/alignways/AlignWaysMode.java	(revision 22837)
+++ applications/editors/josm/plugins/alignways/src/org/openstreetmap/josm/plugins/alignways/AlignWaysMode.java	(revision 22842)
@@ -62,6 +62,6 @@
 	public void exitMode() {
 		super.exitMode();
+		setCurrentState(noneSelected);
 		Main.map.mapView.removeMouseListener(this);
-		setCurrentState(noneSelected);
 		AlignWaysPlugin.getAwAction().setEnabled(false);
 	}
@@ -119,5 +119,10 @@
 		if (currentState == noneSelected) {
 			awSegs.cleanupWays();
-			getCurrentDataSet().clearSelection();
+			// FIX: getCurrentDataSet may return null when the editable layer had
+			// already been removed by JOSM. This happens e.g. when the user closes
+			// JOSM while AlignWays mode is still active.
+			if (getCurrentDataSet() != null) {
+				getCurrentDataSet().clearSelection();
+			}
 		}
 	}
Index: applications/editors/josm/plugins/alignways/src/org/openstreetmap/josm/plugins/alignways/AlignWaysTipsPanel.java
===================================================================
--- applications/editors/josm/plugins/alignways/src/org/openstreetmap/josm/plugins/alignways/AlignWaysTipsPanel.java	(revision 22837)
+++ applications/editors/josm/plugins/alignways/src/org/openstreetmap/josm/plugins/alignways/AlignWaysTipsPanel.java	(revision 22842)
@@ -96,5 +96,7 @@
 
 		step04.setIcon(new ImageIcon(getClass().getResource("/images/tipsdialog/hlpAlgCmd.png"))); // NOI18N
-		step04.setText(tr("<html>\n<div style=\"font-family:sans-serif\">\n<ul>\n  <li><b>Align the segments.</b> Press <b><i><span style=\"color:green\">Shift-A</span></i></b>. Alternatively you''ll find the command in the <b>Tools</b>\n menu or may want to place the action on the <b>toolbar</b>.\n  </li>\n</ul>\n</div>\n</html>\n\n"));
+		step04.setText(tr("<html>\n<div style=\"font-family:sans-serif\">\n<ul>\n  <li><b>Align the segments.</b> Press <b><i><span style=\"color:green\">"
+				+ AlignWaysPlugin.awAction.getShortcut().getKeyText()
+				+ "</span></i></b>. Alternatively you''ll find the command in the <b>Tools</b>\n menu or may want to place the action on the <b>toolbar</b>.\n  </li>\n</ul>\n</div>\n</html>\n\n"));
 		step04.setVerticalAlignment(SwingConstants.TOP);
 
