Index: /applications/editors/josm/plugins/reverter/src/reverter/ChangesetIdQuery.java
===================================================================
--- /applications/editors/josm/plugins/reverter/src/reverter/ChangesetIdQuery.java	(revision 29347)
+++ /applications/editors/josm/plugins/reverter/src/reverter/ChangesetIdQuery.java	(revision 29348)
@@ -9,4 +9,5 @@
 import java.awt.event.KeyListener;
 import java.text.NumberFormat;
+import java.text.ParseException;
 
 import javax.swing.ButtonGroup;
@@ -28,5 +29,6 @@
 @SuppressWarnings("serial")
 public class ChangesetIdQuery extends ExtendedDialog {
-    private final JFormattedTextField tcid = new JFormattedTextField(NumberFormat.getIntegerInstance());
+    private final NumberFormat format = NumberFormat.getIntegerInstance();
+    private final JFormattedTextField tcid = new JFormattedTextField(format);
     private final ButtonGroup bgRevertType = new ButtonGroup();
     private final JRadioButton rbFull = new JRadioButton(tr("Revert changeset fully"));
@@ -39,6 +41,6 @@
     public int getChangesetId() {
         try {
-            return Integer.parseInt(tcid.getText());
-        } catch (NumberFormatException e) {
+            return format.parse(tcid.getText()).intValue();
+        } catch (ParseException e) {
             return 0;
         }
@@ -101,7 +103,9 @@
             @Override public void changedUpdate(DocumentEvent e) { idChanged(); }
             private void idChanged() {
-                boolean idOK = getChangesetId() > 0;
-                tcid.setForeground(idOK ? defaultForegroundColor : Color.RED);
-                buttons.get(0).setEnabled(idOK);
+                if (tcid.hasFocus()) {
+                    boolean idOK = getChangesetId() > 0;
+                    tcid.setForeground(idOK ? defaultForegroundColor : Color.RED);
+                    buttons.get(0).setEnabled(idOK);
+                }
             }
         });
@@ -112,5 +116,5 @@
         // Initially disables the Revert button
         buttons.get(0).setEnabled(false);
-        
+                
         // When pressing Enter in the changeset id field, validate the dialog if the id is correct (i.e. Revert button enabled)
         tcid.addKeyListener(new KeyListener() {
