Project

General

Profile

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

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

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

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

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

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