/** The same machine checkbox. */
private JCheckBox sameMachineCheckBox;
+
+ /** The same machine action. */
+ private I18nAction sameMachineAction;
/** Whether the dialog was cancelled. */
private boolean cancelled;
cancel();
}
};
+ sameMachineAction = new I18nAction("editNodeDialog.checkbox.sameMachine") {
+
+ public void actionPerformed(ActionEvent e) {
+ /* don't do anything. */
+ }
+ };
}
/**
contentPanel.add(portLabel = new I18nLabel("editNodeDialog.label.port", portTextField), new GridBagConstraints(0, 2, 1, 1, 0, 0, GridBagConstraints.LINE_END, GridBagConstraints.NONE, new Insets(12, 0, 0, 0), 0, 0));
contentPanel.add(portTextField, new GridBagConstraints(1, 2, 1, 1, 1, 0, GridBagConstraints.LINE_START, GridBagConstraints.HORIZONTAL, new Insets(12, 12, 0, 0), 0, 0));
- sameMachineCheckBox = new JCheckBox(new I18nAction("editNodeDialog.checkbox.sameMachine") {
-
- public void actionPerformed(ActionEvent e) {
- /* don't do anything. */
- }
- });
+ sameMachineCheckBox = new JCheckBox(sameMachineAction);
contentPanel.add(sameMachineCheckBox, new GridBagConstraints(0, 3, 2, 1, 1, 1, GridBagConstraints.LINE_START, GridBagConstraints.NONE, new Insets(12, 0, 0, 0), 0, 0));
}
nameLabel.updateI18n();
hostnameLabel.updateI18n();
portLabel.updateI18n();
+ sameMachineAction.updateI18n();
setTitle(I18n.get("editNodeDialog.title") + " – jSite " + Version.getVersion());
SwingUtils.repackCentered(this);
}