From c00ddf5d52a5ce4631d8fe7a5d229003e75808b2 Mon Sep 17 00:00:00 2001 From: =?utf8?q?David=20=E2=80=98Bombe=E2=80=99=20Roden?= Date: Tue, 22 Dec 2009 07:06:21 +0100 Subject: [PATCH] Initialize text field and buttons correctly. --- src/de/todesbaum/jsite/gui/PreferencesPage.java | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/de/todesbaum/jsite/gui/PreferencesPage.java b/src/de/todesbaum/jsite/gui/PreferencesPage.java index 03910eb..22b478a 100644 --- a/src/de/todesbaum/jsite/gui/PreferencesPage.java +++ b/src/de/todesbaum/jsite/gui/PreferencesPage.java @@ -195,6 +195,13 @@ public class PreferencesPage extends TWizardPage { customTempDirectory.getModel().setGroup(tempDirectoryButtonGroup); tempDirectoryTextField = new JTextField(); + tempDirectoryTextField.setEditable(false); + if (tempDirectory != null) { + tempDirectoryTextField.setText(tempDirectory); + customTempDirectory.setSelected(true); + } else { + defaultTempDirectory.setSelected(true); + } tempDirectoryPanel.add(tempDirectoryTextField, new GridBagConstraints(1, 2, 1, 1, 1.0, 0.0, GridBagConstraints.LINE_START, GridBagConstraints.BOTH, new Insets(0, 6, 0, 0), 0, 0)); JButton chooseButton = new JButton(chooseTempDirectoryAction); -- 2.7.4