Revision 9c50b7b6
Added by Andreas Müller over 1 year ago
eu.etaxonomy.taxeditor.printpublisher/src/main/java/eu/etaxonomy/taxeditor/printpublisher/handler/GeneratePdfHandler.java | ||
---|---|---|
6 | 6 |
* The contents of this file are subject to the Mozilla Public License Version 1.1 |
7 | 7 |
* See LICENSE.TXT at the top of this package for the full license terms. |
8 | 8 |
*/ |
9 |
|
|
10 | 9 |
package eu.etaxonomy.taxeditor.printpublisher.handler; |
11 | 10 |
|
12 | 11 |
import java.util.UUID; |
... | ... | |
27 | 26 |
import eu.etaxonomy.taxeditor.editor.e4.TaxonEditorInput; |
28 | 27 |
import eu.etaxonomy.taxeditor.model.MessagingUtils; |
29 | 28 |
import eu.etaxonomy.taxeditor.printpublisher.wizard.DirectPublishingWizard; |
30 |
import eu.etaxonomy.taxeditor.store.CdmStore; |
|
31 | 29 |
|
32 | 30 |
/** |
33 |
* <p>GeneratePdfHandler class.</p> |
|
34 |
* |
|
35 | 31 |
* @author n.hoffmann |
36 | 32 |
* @created Jul 20, 2010 |
37 | 33 |
*/ |
... | ... | |
52 | 48 |
return null; |
53 | 49 |
} |
54 | 50 |
|
55 |
configurator = PublishConfigurator.NewLocalInstance(CdmStore.getCurrentApplicationConfiguration()); |
|
51 |
//Note: was NewLocalInstance before |
|
52 |
configurator = PublishConfigurator.NewRemoteInstance(); |
|
56 | 53 |
|
57 | 54 |
Element taxonNodeElement = getTaxonNodeElement((TaxonEditorInput) input); |
58 | 55 |
configurator.addSelectedTaxonNodeElements(taxonNodeElement); |
eu.etaxonomy.taxeditor.printpublisher/src/main/java/eu/etaxonomy/taxeditor/printpublisher/wizard/SelectServiceWizardPage.java | ||
---|---|---|
37 | 37 |
import org.eclipse.swt.widgets.Text; |
38 | 38 |
import org.jdom.Element; |
39 | 39 |
|
40 |
import eu.etaxonomy.cdm.api.application.ICdmRepository; |
|
41 | 40 |
import eu.etaxonomy.cdm.print.IXMLEntityFactory; |
42 | 41 |
import eu.etaxonomy.cdm.print.PublishConfigurator; |
43 | 42 |
import eu.etaxonomy.cdm.print.XMLHelper; |
44 | 43 |
import eu.etaxonomy.cdm.print.XMLHelper.EntityType; |
45 | 44 |
import eu.etaxonomy.taxeditor.model.CdmProgressMonitorAdapter; |
46 | 45 |
import eu.etaxonomy.taxeditor.model.MessagingUtils; |
47 |
import eu.etaxonomy.taxeditor.printpublisher.PrintUtil; |
|
48 |
import eu.etaxonomy.taxeditor.store.CdmStore; |
|
49 | 46 |
|
50 | 47 |
/** |
51 | 48 |
* <p>SelectServiceWizardPage class.</p> |
... | ... | |
127 | 124 |
|
128 | 125 |
treeViewer.getControl().setLayoutData(new GridData(SWT.FILL, SWT.FILL, true, true)); |
129 | 126 |
|
130 |
if(CdmStore.isActive()){ |
|
131 |
enableLocal(); |
|
132 |
}else{ |
|
127 |
// if(CdmStore.isActive()){
|
|
128 |
// enableLocal();
|
|
129 |
// }else{
|
|
133 | 130 |
enableRemote(); |
134 | 131 |
button_local.setEnabled(false); |
135 |
} |
|
132 |
// }
|
|
136 | 133 |
|
137 | 134 |
setControl(composite); |
138 | 135 |
} |
... | ... | |
157 | 154 |
setConfigurator(PublishConfigurator.NewRemoteInstance()); |
158 | 155 |
getConfigurator().addOutputModule(getOutputModule()); |
159 | 156 |
} |
160 |
|
|
157 |
|
|
158 |
/** |
|
159 |
* @deprecated real local is not supported anymore, also the currently active |
|
160 |
* database is a "remoting" database |
|
161 |
*/ |
|
162 |
@Deprecated |
|
161 | 163 |
private void enableLocal() { |
162 | 164 |
button_remote.setSelection(false); |
163 | 165 |
button_local.setSelection(true); |
164 | 166 |
|
165 | 167 |
text_serviceUrl.setEnabled(false); |
166 | 168 |
|
167 |
setConfigurator(PublishConfigurator.NewLocalInstance((ICdmRepository) CdmStore.getCurrentApplicationConfiguration()));
|
|
169 |
setConfigurator(PublishConfigurator.NewRemoteInstance());
|
|
168 | 170 |
getConfigurator().addOutputModule(getOutputModule()); |
169 | 171 |
refresh(); |
170 | 172 |
} |
Also available in: Unified diff
ref #10189 split CdmApplicationController into repository and application part in taxeditor print publisher (only make compilable)