From: David ‘Bombe’ Roden Date: Tue, 22 Dec 2009 20:07:05 +0000 (+0100) Subject: Set temp directory on project inserter when starting the insert. X-Git-Tag: 0.8~11 X-Git-Url: https://git.pterodactylus.net/?a=commitdiff_plain;h=c64e48e653f169c3683636bee575422c9f6704b1;p=jSite.git Set temp directory on project inserter when starting the insert. --- diff --git a/src/de/todesbaum/jsite/main/Main.java b/src/de/todesbaum/jsite/main/Main.java index ddeb414..310f5a6 100644 --- a/src/de/todesbaum/jsite/main/Main.java +++ b/src/de/todesbaum/jsite/main/Main.java @@ -556,7 +556,10 @@ public class Main implements ActionListener, ListSelectionListener, WizardListen } configuration.save(); showPage(PageType.PAGE_INSERT_PROJECT); - ((ProjectInsertPage) pages.get(PageType.PAGE_INSERT_PROJECT)).startInsert(); + ProjectInsertPage projectInsertPage = (ProjectInsertPage) pages.get(PageType.PAGE_INSERT_PROJECT); + String tempDirectory = ((PreferencesPage) pages.get(PageType.PAGE_PREFERENCES)).getTempDirectory(); + projectInsertPage.setTempDirectory(tempDirectory); + projectInsertPage.startInsert(); nodeMenu.setEnabled(false); } else if ("page.project.insert".equals(pageName)) { showPage(PageType.PAGE_PROJECTS); @@ -564,8 +567,6 @@ public class Main implements ActionListener, ListSelectionListener, WizardListen } else if ("page.preferences".equals(pageName)) { showPage(PageType.PAGE_PROJECTS); optionsPreferencesAction.setEnabled(true); - String tempDirectory = ((PreferencesPage) pages.get(PageType.PAGE_PREFERENCES)).getTempDirectory(); - ((ProjectInsertPage) pages.get(PageType.PAGE_INSERT_PROJECT)).setTempDirectory(tempDirectory); } }