Index: src/org/openstreetmap/josm/actions/mapmode/AddNoteAction.java
===================================================================
--- src/org/openstreetmap/josm/actions/mapmode/AddNoteAction.java	(revision 7719)
+++ src/org/openstreetmap/josm/actions/mapmode/AddNoteAction.java	(working copy)
@@ -5,15 +5,13 @@
 
 import java.awt.event.MouseEvent;
 
-import javax.swing.JLabel;
 import javax.swing.JOptionPane;
-import javax.swing.JScrollPane;
-import javax.swing.JTextArea;
 
 import org.openstreetmap.josm.Main;
 import org.openstreetmap.josm.data.coor.LatLon;
 import org.openstreetmap.josm.data.osm.NoteData;
 import org.openstreetmap.josm.gui.MapFrame;
+import org.openstreetmap.josm.gui.NoteInputDialog;
 import org.openstreetmap.josm.gui.Notification;
 import org.openstreetmap.josm.gui.dialogs.NoteDialog;
 import org.openstreetmap.josm.tools.ImageProvider;
@@ -62,29 +60,21 @@
     public void mouseClicked(MouseEvent e) {
         Main.map.selectMapMode(Main.map.mapModeSelect);
         LatLon latlon = Main.map.mapView.getLatLon(e.getPoint().x, e.getPoint().y);
-        JLabel label = new JLabel(tr("Enter a comment for a new note"));
-        JTextArea textArea = new JTextArea();
-        textArea.setRows(6);
-        textArea.setColumns(30);
-        textArea.setLineWrap(true);
-        JScrollPane scrollPane = new JScrollPane(textArea);
 
-        Object[] components = new Object[]{label, scrollPane};
-        int option = JOptionPane.showConfirmDialog(Main.map,
-                components,
-                tr("Create new note"),
-                JOptionPane.OK_CANCEL_OPTION,
-                JOptionPane.PLAIN_MESSAGE,
-                NoteDialog.ICON_NEW);
-        if (option == JOptionPane.OK_OPTION) {
-            String input = textArea.getText();
-            if (input != null && !input.isEmpty()) {
-                noteData.createNote(latlon, input);
-            } else {
-                Notification notification = new Notification("You must enter a comment to create a new note");
-                notification.setIcon(JOptionPane.WARNING_MESSAGE);
-                notification.show();
-            }
+        NoteInputDialog dialog = new NoteInputDialog(Main.parent, tr("Create new note"), tr("Create note"));
+        dialog.showNoteDialog(tr("Enter a detailed comment to create a note"), NoteDialog.ICON_NEW);
+
+        if (dialog.getValue() != 1) {
+            Main.debug("User aborted note creation");
+            return;
         }
+        String input = dialog.getInputText();
+        if (input != null && !input.isEmpty()) {
+            noteData.createNote(latlon, input);
+        } else {
+            Notification notification = new Notification(tr("You must enter a comment to create a new note"));
+            notification.setIcon(JOptionPane.WARNING_MESSAGE);
+            notification.show();
+        }
     }
 }
Index: src/org/openstreetmap/josm/gui/NoteInputDialog.java
===================================================================
--- src/org/openstreetmap/josm/gui/NoteInputDialog.java	(revision 0)
+++ src/org/openstreetmap/josm/gui/NoteInputDialog.java	(working copy)
@@ -0,0 +1,66 @@
+// License: GPL. For details, see LICENSE file.
+package org.openstreetmap.josm.gui;
+
+import static org.openstreetmap.josm.tools.I18n.tr;
+
+import java.awt.Component;
+
+import javax.swing.BoxLayout;
+import javax.swing.Icon;
+import javax.swing.JLabel;
+import javax.swing.JPanel;
+import javax.swing.JScrollPane;
+import javax.swing.JTextArea;
+
+import org.openstreetmap.josm.tools.ImageProvider;
+
+/**
+ * Class to show user input dialog for notes. It sets up a
+ * simple label and text area to prompt for user input
+ */
+public class NoteInputDialog extends ExtendedDialog {
+
+    private JTextArea textArea = new JTextArea();
+
+    /**
+     * Construct the dialog with a title and button text. A cancel button is
+     * automatically added
+     * @param parent The parent GUI element
+     * @param title Translated string to display in the dialog's title bar
+     * @param buttonText Translated string to display on the action button
+     */
+    public NoteInputDialog(Component parent, String title, String buttonText) {
+        super(parent, title, new String[] {buttonText, tr("Cancel")});
+    }
+
+    /**
+     * Displays the dialog to the user
+     * @param message Translated message to display to the user as input prompt
+     * @param icon Icon to display in the action button
+     */
+    public void showNoteDialog(String message, Icon icon) {
+        JLabel label = new JLabel(message);
+        textArea.setRows(6);
+        textArea.setColumns(30);
+        textArea.setLineWrap(true);
+        JScrollPane scrollPane = new JScrollPane(textArea);
+        scrollPane.setAlignmentX(Component.LEFT_ALIGNMENT); //without this the label gets pushed to the right
+
+        JPanel contentPanel = new JPanel();
+        contentPanel.setLayout(new BoxLayout(contentPanel, BoxLayout.Y_AXIS));
+        contentPanel.add(label);
+        contentPanel.add(scrollPane);
+        setContent(contentPanel, false);
+        setButtonIcons(new Icon[] {icon, ImageProvider.get("cancel.png")});
+
+        showDialog();
+    }
+
+    /** Get the content of the text area
+     * @return Text input by user
+     */
+    public String getInputText() {
+        return textArea.getText();
+    }
+
+}
Index: src/org/openstreetmap/josm/gui/dialogs/NoteDialog.java
===================================================================
--- src/org/openstreetmap/josm/gui/dialogs/NoteDialog.java	(revision 7719)
+++ src/org/openstreetmap/josm/gui/dialogs/NoteDialog.java	(working copy)
@@ -34,6 +34,7 @@
 import org.openstreetmap.josm.data.osm.NoteData;
 import org.openstreetmap.josm.gui.MapView;
 import org.openstreetmap.josm.gui.MapView.LayerChangeListener;
+import org.openstreetmap.josm.gui.NoteInputDialog;
 import org.openstreetmap.josm.gui.SideButton;
 import org.openstreetmap.josm.gui.layer.Layer;
 import org.openstreetmap.josm.gui.layer.NoteLayer;
@@ -293,16 +294,13 @@
                         JOptionPane.ERROR_MESSAGE);
                 return;
             }
-            Object userInput = JOptionPane.showInputDialog(Main.map,
-                    tr("Add comment to note:"),
-                    tr("Add comment"),
-                    JOptionPane.QUESTION_MESSAGE,
-                    ICON_COMMENT,
-                    null,null);
-            if (userInput == null) { //user pressed cancel
+            NoteInputDialog dialog = new NoteInputDialog(Main.parent, tr("Comment on note"), tr("Add comment"));
+            dialog.showNoteDialog(tr("Add comment to note:"), NoteDialog.ICON_COMMENT);
+            if (dialog.getValue() != 1) {
+                Main.debug("User aborted note reopening");
                 return;
             }
-            noteData.addCommentToNote(note, userInput.toString());
+            noteData.addCommentToNote(note, dialog.getInputText());
         }
     }
 
@@ -316,17 +314,14 @@
 
         @Override
         public void actionPerformed(ActionEvent e) {
-            Object userInput = JOptionPane.showInputDialog(Main.map,
-                    tr("Close note with message:"),
-                    tr("Close Note"),
-                    JOptionPane.QUESTION_MESSAGE,
-                    ICON_CLOSED,
-                    null,null);
-            if (userInput == null) { //user pressed cancel
+            NoteInputDialog dialog = new NoteInputDialog(Main.parent, tr("Close note"), tr("Close note"));
+            dialog.showNoteDialog(tr("Close note with message:"), NoteDialog.ICON_CLOSED);
+            if (dialog.getValue() != 1) {
+                Main.debug("User aborted note closing");
                 return;
             }
             Note note = displayList.getSelectedValue();
-            noteData.closeNote(note, userInput.toString());
+            noteData.closeNote(note, dialog.getInputText());
         }
     }
 
@@ -357,17 +352,15 @@
 
         @Override
         public void actionPerformed(ActionEvent e) {
-            Object userInput = JOptionPane.showInputDialog(Main.map,
-                    tr("Reopen note with message:"),
-                    tr("Reopen note"),
-                    JOptionPane.QUESTION_MESSAGE,
-                    ICON_OPEN,
-                    null,null);
-            if (userInput == null) { //user pressed cancel
+            NoteInputDialog dialog = new NoteInputDialog(Main.parent, tr("Reopen note"), tr("Reopen note"));
+            dialog.showNoteDialog(tr("Reopen note with message:"), NoteDialog.ICON_OPEN);
+            if (dialog.getValue() != 1) {
+                Main.debug("User aborted note reopening");
                 return;
             }
+
             Note note = displayList.getSelectedValue();
-            noteData.reOpenNote(note, userInput.toString());
+            noteData.reOpenNote(note, dialog.getInputText());
         }
     }
 }
