1 11 package org.eclipse.ant.internal.ui.datatransfer; 12 13 import org.eclipse.ant.internal.ui.AntUIImages; 14 import org.eclipse.ant.internal.ui.IAntUIConstants; 15 import org.eclipse.jface.viewers.IStructuredSelection; 16 import org.eclipse.jface.wizard.Wizard; 17 import org.eclipse.ui.INewWizard; 18 import org.eclipse.ui.IWorkbench; 19 20 public class AntNewJavaProjectWizard extends Wizard implements INewWizard { 21 22 private AntNewJavaProjectPage fMainPage; 23 24 public AntNewJavaProjectWizard() { 25 super(); 26 } 27 28 31 public void addPages() { 32 super.addPages(); 33 fMainPage = new AntNewJavaProjectPage(); 34 addPage(fMainPage); 35 } 36 37 40 public void init(IWorkbench workbench, IStructuredSelection currentSelection) { 41 setWindowTitle(DataTransferMessages.AntNewJavaProjectWizard_0); 42 setDefaultPageImageDescriptor(AntUIImages.getImageDescriptor(IAntUIConstants.IMG_WIZARD_BANNER)); 43 44 } 45 48 public boolean performCancel() { 49 return true; 50 } 51 52 55 public boolean performFinish() { 56 return (fMainPage.createProject() != null); 57 } 58 } 59 | Popular Tags |