Project

General

Profile

Download (1.73 KB) Statistics
| Branch: | Tag: | Revision:
1
/**
2
* Copyright (C) 2007 EDIT
3
* European Distributed Institute of Taxonomy 
4
* http://www.e-taxonomy.eu
5
* 
6
* The contents of this file are subject to the Mozilla Public License Version 1.1
7
* See LICENSE.TXT at the top of this package for the full license terms.
8
*/
9

    
10
package eu.etaxonomy.taxeditor.printpublisher.wizard;
11

    
12
import org.eclipse.jface.viewers.IStructuredSelection;
13
import org.eclipse.ui.IWorkbench;
14

    
15
import eu.etaxonomy.cdm.print.PublishConfigurator;
16
import eu.etaxonomy.cdm.print.out.IPublishOutputModule;
17

    
18
/**
19
 * <p>DirectPublishingWizard class.</p>
20
 *
21
 * @author n.hoffmann
22
 * @created Aug 6, 2010
23
 * @version 1.0
24
 */
25
public class DirectPublishingWizard extends AbstractPublishWizard {
26
	
27
	/**
28
	 * <p>Constructor for DirectPublishingWizard.</p>
29
	 *
30
	 * @param configurator a {@link eu.etaxonomy.cdm.print.PublishConfigurator} object.
31
	 */
32
	public DirectPublishingWizard(PublishConfigurator configurator) {
33
		setConfigurator(configurator);
34
		IPublishOutputModule module = configurator.getOutputModules().iterator().next();
35
		setOutputModule(module);
36
	}
37

    
38
	/** {@inheritDoc} */
39
	@Override
40
	public void addPages() {
41
		pageOptions = new SelectOptionsWizardPage(PAGE_OPTIONS);
42
		addPage(pageOptions);
43
		
44
		pageFeatureTree = new SelectFeatureTreeWizardPage(PAGE_FEATURETREE);
45
		addPage(pageFeatureTree);
46
		
47
		pageStylesheet = new SelectStylesheetWizardPage(PAGE_STYLESHEET);
48
		addPage(pageStylesheet);
49
		
50
		pageFolder = new SelectDirectoryWizardPage(PAGE_FOLDER);
51
		addPage(pageFolder);
52
		
53
	}
54
		
55
	/** {@inheritDoc} */
56
	@Override
57
	public boolean performFinish() {
58
		return super.performFinish();
59
	}
60
	
61
	/**
62
	 * <p>canFinish</p>
63
	 *
64
	 * @return a boolean.
65
	 */
66
	public boolean canFinish() {
67
		return pageFeatureTree.isPageComplete()
68
			&& pageFolder.isPageComplete();
69
	}
70
}
(3-3/14)