newName = JOptionPane.showInputDialog(autWin, java.util.ResourceBundle.getBundle("global").getString("newName"),
newName = JOptionPane.showInputDialog(autWin, "New Name: ",
            public void actionPerformed(ActionEvent e) {                String newName;                                if (lastSel!=-1) {                    newName = JOptionPane.showInputDialog(autWin, java.util.ResourceBundle.getBundle("global").getString("newName"),                            listModel.elementAt(lastSel));                    if (newName==null) return; // cancel gedrckt                    newName = newName.trim();                    for (int i = 0 ; i <  newName.length()  ; i++ ) {                        if (!Character.isJavaIdentifierPart(newName.charAt(i))) {                            JOptionPane.showMessageDialog(autWin,                                    java.util.ResourceBundle.getBundle("global").getString("InvalidName"),                                    java.util.ResourceBundle.getBundle("global").getString("Error"), JOptionPane.ERROR_MESSAGE);                            return;                        }                    }                    listModel.setElementAt(newName, lastSel);                    autWin.setCurrentName(newName);                }            }