|
@@ -23,6 +23,7 @@
|
23
|
23
|
package com.dmdirc.addons.ui_swing.dialogs.aliases;
|
24
|
24
|
|
25
|
25
|
import com.dmdirc.ClientModule.GlobalConfig;
|
|
26
|
+import com.dmdirc.addons.ui_swing.UIUtilities;
|
26
|
27
|
import com.dmdirc.addons.ui_swing.components.text.TextLabel;
|
27
|
28
|
import com.dmdirc.addons.ui_swing.components.validating.ValidationFactory;
|
28
|
29
|
import com.dmdirc.addons.ui_swing.dialogs.StandardDialog;
|
|
@@ -68,6 +69,7 @@ public class AliasManagerDialog extends StandardDialog {
|
68
|
69
|
final JTextArea response = new JTextArea();
|
69
|
70
|
final JButton addAlias = new JButton("Add Alias");
|
70
|
71
|
final JButton deleteAlias = new JButton("Delete Alias");
|
|
72
|
+ final JScrollPane responseScroll = new JScrollPane(response);
|
71
|
73
|
getOkButton();
|
72
|
74
|
getCancelButton();
|
73
|
75
|
setMinimumSize(new Dimension(800, 400));
|
|
@@ -88,16 +90,18 @@ public class AliasManagerDialog extends StandardDialog {
|
88
|
90
|
add(ValidationFactory.getValidatorPanel(command, model.getCommandValidator(), iconManager),
|
89
|
91
|
"growx, pushx");
|
90
|
92
|
add(argumentsNumber, "growx, pushx");
|
91
|
|
- add(ValidationFactory.getValidatorPanel(new JScrollPane(response), response,
|
|
93
|
+ add(ValidationFactory.getValidatorPanel(responseScroll, response,
|
92
|
94
|
new NotEmptyValidator(), iconManager), "spanx 2, grow, push");
|
93
|
95
|
|
94
|
96
|
add(getLeftButton(), "flowx, split 3, right, sg button");
|
95
|
97
|
add(getRightButton(), "sg button");
|
96
|
98
|
|
|
99
|
+ UIUtilities.addUndoManager(response);
|
|
100
|
+
|
97
|
101
|
linker.bindCommandList(aliasList);
|
98
|
102
|
linker.bindCommand(command);
|
99
|
103
|
linker.bindArgumentsNumber(argumentsNumber);
|
100
|
|
- linker.bindResponse(response);
|
|
104
|
+ linker.bindResponse(response, responseScroll);
|
101
|
105
|
linker.bindAddAlias(addAlias);
|
102
|
106
|
linker.bindDeleteAlias(deleteAlias);
|
103
|
107
|
linker.bindOKButton(getOkButton());
|