Project

General

Profile

Download (2.3 KB) Statistics
| Branch: | Tag: | Revision:
1
/**
2
* Copyright (C) 2017 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
package eu.etaxonomy.taxeditor.ui.dialog.configurator;
10

    
11
import org.eclipse.jface.wizard.Wizard;
12
import org.eclipse.swt.SWT;
13
import org.eclipse.swt.widgets.Shell;
14

    
15
import eu.etaxonomy.cdm.io.common.SetSecundumForSubtreeConfigurator;
16
import eu.etaxonomy.cdm.model.reference.Reference;
17

    
18
/**
19
 * @author k.luther
20
 * @date 10.02.2017
21
 *
22
 */
23
public class SetSecundumForSubtreeConfigurationWizard extends Wizard {
24

    
25
    Reference newSecRef;
26
    private final SetSecundumForSubtreeConfigurator configurator;
27

    
28

    
29
    private SetSecundumConfiguratorWizardPage page;
30

    
31

    
32

    
33
    /**
34
     * @param parentShell
35
     * @param dialogTitle
36
     * @param dialogTitleImage
37
     * @param dialogMessage
38
     * @param dialogImageType
39
     * @param dialogButtonLabels
40
     * @param defaultIndex
41
     * @param config
42
     */
43
    public SetSecundumForSubtreeConfigurationWizard(SetSecundumForSubtreeConfigurator config) {
44
        super();
45
       // super(parentShell, dialogTitle, dialogTitleImage, dialogMessage, dialogImageType, dialogButtonLabels, defaultIndex);
46
        this.configurator = config;
47
        setNeedsProgressMonitor(true);
48

    
49

    
50

    
51
    }
52

    
53

    
54

    
55
    /**
56
     * @param configurator
57
     * @param activeShell
58
     * @param setSecundumHandler_confirm
59
     * @param setSecundumHandler_configureSettings
60
     * @return
61
     */
62
    public static void openConfirmWithConfigurator(SetSecundumForSubtreeConfigurator configurator, Shell parent, String title, String message) {
63

    
64
        SetSecundumForSubtreeConfigurationWizard wizard = new SetSecundumForSubtreeConfigurationWizard(configurator);
65

    
66

    
67
    }
68

    
69

    
70

    
71

    
72

    
73
    /**
74
     * {@inheritDoc}
75
     */
76
    @Override
77
    public boolean performFinish() {
78
       if (!(configurator.isIncludeAcceptedTaxa() || configurator.isIncludeSynonyms())){
79
           return false;
80
       }else{
81
           return true;
82
       }
83
    }
84

    
85
    /* (non-Javadoc)
86
     * @see org.eclipse.jface.wizard.Wizard#addPages()
87
     */
88
    /** {@inheritDoc} */
89
    @Override
90
    public void addPages() {
91
        page = new SetSecundumConfiguratorWizardPage(configurator, this, SWT.NONE);
92
        addPage(page);
93
    }
94

    
95

    
96
}
(3-3/3)