Revision 939829bc
Added by Patrick Plitzner about 7 years ago
eu.etaxonomy.taxeditor.navigation/src/main/java/eu/etaxonomy/taxeditor/navigation/NavigationUtil.java | ||
---|---|---|
52 | 52 |
import eu.etaxonomy.taxeditor.model.AbstractUtility; |
53 | 53 |
import eu.etaxonomy.taxeditor.model.MessagingUtils; |
54 | 54 |
import eu.etaxonomy.taxeditor.navigation.internal.TaxeditorNavigationPlugin; |
55 |
import eu.etaxonomy.taxeditor.navigation.l10n.Messages; |
|
55 | 56 |
import eu.etaxonomy.taxeditor.navigation.navigator.TaxonNavigator; |
56 | 57 |
import eu.etaxonomy.taxeditor.newWizard.NewClassificationWizard; |
57 | 58 |
import eu.etaxonomy.taxeditor.store.CdmStore; |
... | ... | |
65 | 66 |
* @version 1.0 |
66 | 67 |
*/ |
67 | 68 |
public class NavigationUtil extends AbstractUtility{ |
68 |
private static IUndoContext defaultUndoContext; |
|
69 |
|
|
70 |
private static final String NOT_IMPLEMENTED_YET = Messages.NavigationUtil_NOT_IMPLEMENTED; |
|
71 |
private static final String ERROR_OPENING_THE_EDITOR = Messages.NavigationUtil_OPEN_ERROR; |
|
72 |
private static IUndoContext defaultUndoContext; |
|
69 | 73 |
|
70 | 74 |
/** |
71 | 75 |
* <p>openEditor</p> |
... | ... | |
88 | 92 |
cdmBase = CdmStore.getService(INameService.class).load(uuidAndTitleCache.getUuid()); |
89 | 93 |
} |
90 | 94 |
else{ |
91 |
MessagingUtils.warningDialog("Unknown type", NavigationUtil.class, "There is no editor available to open this object.");
|
|
95 |
MessagingUtils.warningDialog(Messages.NavigationUtil_UNKNOWN_TYPE, NavigationUtil.class, Messages.NavigationUtil_UNKNOWN_TYPE_MESSAGE);
|
|
92 | 96 |
} |
93 | 97 |
if(cdmBase!=null){ |
94 | 98 |
openEditor(cdmBase); |
95 | 99 |
} |
96 | 100 |
else{ |
97 |
MessagingUtils.warningDialog("Cdm entity not found", NavigationUtil.class, "CDM entity could not be found in the database.");
|
|
101 |
MessagingUtils.warningDialog(Messages.NavigationUtil_NOT_FOUND, NavigationUtil.class, Messages.NavigationUtil_NOT_FOUND_MESSAGE);
|
|
98 | 102 |
} |
99 | 103 |
} |
100 | 104 |
|
... | ... | |
123 | 127 |
}else if(selectedObject instanceof PolytomousKey){ |
124 | 128 |
EditorUtil.openPolytomousKey(entityUuid); |
125 | 129 |
}else{ |
126 |
MessagingUtils.warningDialog("Unsupported Type", NavigationUtil.class, "No editor exists for the current selection: " + selectedObject);
|
|
130 |
MessagingUtils.warningDialog(Messages.NavigationUtil_UNSUPPORTED_TYPE, NavigationUtil.class, Messages.NavigationUtil_UNSUPPORTED_TYPE_MESSAGE + selectedObject);
|
|
127 | 131 |
} |
128 | 132 |
} catch (PartInitException e) { |
129 |
MessagingUtils.error(NavigationUtil.class, "Error opening the editor", e);
|
|
133 |
MessagingUtils.error(NavigationUtil.class, ERROR_OPENING_THE_EDITOR, e);
|
|
130 | 134 |
} catch (Exception e) { |
131 |
MessagingUtils.errorDialog("Could not create Taxon",
|
|
135 |
MessagingUtils.errorDialog(Messages.NavigationUtil_CREATE_FAILED,
|
|
132 | 136 |
NavigationUtil.class, |
133 | 137 |
e.getMessage(), TaxeditorStorePlugin.PLUGIN_ID, |
134 | 138 |
e, |
... | ... | |
140 | 144 |
private static void openInBulkEditor(ICdmBase selectedObject) { |
141 | 145 |
ICommandService commandService = (ICommandService)PlatformUI.getWorkbench().getService(ICommandService.class); |
142 | 146 |
IHandlerService handlerService = (IHandlerService)PlatformUI.getWorkbench().getService(IHandlerService.class); |
143 |
String openInBulkEditorCommand = "eu.etaxonomy.taxeditor.bulkeditor.openBulkEditorForIdentifiableEntity"; |
|
147 |
String openInBulkEditorCommand = "eu.etaxonomy.taxeditor.bulkeditor.openBulkEditorForIdentifiableEntity"; //$NON-NLS-1$
|
|
144 | 148 |
Command command = commandService.getCommand(openInBulkEditorCommand); |
145 | 149 |
if(command.isDefined()){ |
146 | 150 |
Map<String, UUID> params = new HashMap<String, UUID>(); |
147 |
params.put(openInBulkEditorCommand+".uuid", ((ICdmBase) selectedObject).getUuid()); //$NON-NLS-1$
|
|
151 |
params.put(openInBulkEditorCommand+".uuid", selectedObject.getUuid()); //$NON-NLS-1$
|
|
148 | 152 |
ParameterizedCommand parameterizedCommand = ParameterizedCommand.generateCommand(command, params); |
149 | 153 |
try { |
150 | 154 |
if(parameterizedCommand!=null){ |
... | ... | |
172 | 176 |
try { |
173 | 177 |
EditorUtil.openEmpty(parentNodeUuid); |
174 | 178 |
} catch (PartInitException e) { |
175 |
MessagingUtils.error(NavigationUtil.class, "Error opening the editor", e);
|
|
179 |
MessagingUtils.error(NavigationUtil.class, ERROR_OPENING_THE_EDITOR, e);
|
|
176 | 180 |
} |
177 | 181 |
} |
178 | 182 |
|
... | ... | |
297 | 301 |
handleOpeningOfMultipleTaxa(accTaxa); |
298 | 302 |
|
299 | 303 |
}else{ |
300 |
MessagingUtils.warningDialog("Not implemented yet", NavigationUtil.class, "You chose to open a name that has no connection to a taxon. The Editor does not support editing of such a content type at the moment.");
|
|
304 |
MessagingUtils.warningDialog(NOT_IMPLEMENTED_YET, NavigationUtil.class, Messages.NavigationUtil_ORPHAN_NAME_MESSAGE);
|
|
301 | 305 |
} |
302 | 306 |
|
303 | 307 |
} |
... | ... | |
307 | 311 |
openEditor(acceptedTaxa.iterator().next()); |
308 | 312 |
}else if(acceptedTaxa.size() > 1){ |
309 | 313 |
// FIXME implement a dialog that shows all possible taxa and let the user choose which he wants to open. |
310 |
MessagingUtils.warningDialog("Not implemented yet", NavigationUtil.class, "The accepted taxon is in multiple taxonomic trees. We currently do not know which one you want to open." + |
|
311 |
" This case is not handled yet by the software."); |
|
314 |
MessagingUtils.warningDialog(NOT_IMPLEMENTED_YET, NavigationUtil.class, Messages.NavigationUtil_MULTI_TREE); |
|
312 | 315 |
}else if(acceptedTaxa.size() == 0){ |
313 | 316 |
// this is an undesired state |
314 |
MessagingUtils.warningDialog("Not implemented yet", NavigationUtil.class, "This taxon is not connected to a classification. Currently editing of such taxa is not supported yet.");
|
|
317 |
MessagingUtils.warningDialog(NOT_IMPLEMENTED_YET, NavigationUtil.class, Messages.NavigationUtil_ORPHAN_TAXON);
|
|
315 | 318 |
} |
316 | 319 |
} |
317 | 320 |
|
... | ... | |
325 | 328 |
openEditor(taxonNodes.iterator().next()); |
326 | 329 |
}else if(taxonNodes.size() > 1){ |
327 | 330 |
// FIXME implement a dialog that shows all possible taxa and let the user choose which he wants to open. |
328 |
MessagingUtils.warningDialog("Not implemented yet", NavigationUtil.class, "The accepted taxon is in multiple taxonomic trees. We currently do not know which one you want to open." + |
|
329 |
" This case is not handled yet by the software."); |
|
331 |
MessagingUtils.warningDialog(NOT_IMPLEMENTED_YET, NavigationUtil.class, "The accepted taxon is in multiple taxonomic trees. We currently do not know which one you want to open. This case is not handled yet by the software."); |
|
330 | 332 |
}else if(taxonNodes.size() == 0){ |
331 | 333 |
// this is an undesired state |
332 |
MessagingUtils.warningDialog("Incorrect state", NavigationUtil.class, "The accepted taxon is not in a taxonomic view. This should not have happened.");
|
|
334 |
MessagingUtils.warningDialog(Messages.NavigationUtil_INCORRECT_STATE, NavigationUtil.class, Messages.NavigationUtil_INCORRECT_STATE_MESSAGE);
|
|
333 | 335 |
} |
334 | 336 |
} |
335 | 337 |
|
eu.etaxonomy.taxeditor.navigation/src/main/java/eu/etaxonomy/taxeditor/navigation/internal/TaxeditorNavigationPlugin.java | ||
---|---|---|
17 | 17 |
|
18 | 18 |
// The plug-in ID |
19 | 19 |
/** Constant <code>PLUGIN_ID="eu.etaxonomy.taxeditor.navigator"</code> */ |
20 |
public static final String PLUGIN_ID = "eu.etaxonomy.taxeditor.navigator"; |
|
20 |
public static final String PLUGIN_ID = "eu.etaxonomy.taxeditor.navigator"; //$NON-NLS-1$
|
|
21 | 21 |
|
22 | 22 |
// The shared instance |
23 | 23 |
private static TaxeditorNavigationPlugin plugin; |
eu.etaxonomy.taxeditor.navigation/src/main/java/eu/etaxonomy/taxeditor/navigation/key/polytomous/PolytomousKeyViewLabels.java | ||
---|---|---|
8 | 8 |
*/ |
9 | 9 |
package eu.etaxonomy.taxeditor.navigation.key.polytomous; |
10 | 10 |
|
11 |
import eu.etaxonomy.taxeditor.navigation.l10n.Messages; |
|
12 |
|
|
11 | 13 |
/** |
12 | 14 |
* @author cmathew |
13 | 15 |
* @date 25 Jun 2015 |
... | ... | |
15 | 17 |
*/ |
16 | 18 |
public interface PolytomousKeyViewLabels { |
17 | 19 |
|
18 |
public static final String DELETE_POLYTOMOUS_KEY_LABEL = "Delete Polytomous Key";
|
|
19 |
public static final String UPDATE_ALL_POLYTOMOUS_KEY_NODES_LABEL = "Update All Polytomous Key Nodes";
|
|
20 |
public static final String DELETE_POLYTOMOUS_KEY_LABEL = Messages.PolytomousKeyViewLabels_DELETE;
|
|
21 |
public static final String UPDATE_ALL_POLYTOMOUS_KEY_NODES_LABEL = Messages.PolytomousKeyViewLabels_UPDATE;
|
|
20 | 22 |
|
21 |
public static final String ERROR_OPENING_KEY_EDITOR_MESSAGE = "Error opening Polytomous Key Editor";
|
|
23 |
public static final String ERROR_OPENING_KEY_EDITOR_MESSAGE = Messages.PolytomousKeyViewLabels_OPEN_ERROR;
|
|
22 | 24 |
|
23 | 25 |
|
24 | 26 |
} |
eu.etaxonomy.taxeditor.navigation/src/main/java/eu/etaxonomy/taxeditor/navigation/key/polytomous/PolytomousKeyViewPart.java | ||
---|---|---|
50 | 50 |
import eu.etaxonomy.taxeditor.model.DataChangeBridge; |
51 | 51 |
import eu.etaxonomy.taxeditor.model.IContextListener; |
52 | 52 |
import eu.etaxonomy.taxeditor.model.MessagingUtils; |
53 |
import eu.etaxonomy.taxeditor.navigation.l10n.Messages; |
|
53 | 54 |
import eu.etaxonomy.taxeditor.operation.IPostOperationEnabled; |
54 | 55 |
import eu.etaxonomy.taxeditor.session.ICdmEntitySession; |
55 | 56 |
import eu.etaxonomy.taxeditor.session.ICdmEntitySessionEnabled; |
... | ... | |
90 | 91 |
} |
91 | 92 |
|
92 | 93 |
|
93 |
public static final String ID = "eu.etaxonomy.taxeditor.navigation.key.polytomous.polytomousKeyViewPart"; |
|
94 |
public static final String ID = "eu.etaxonomy.taxeditor.navigation.key.polytomous.polytomousKeyViewPart"; //$NON-NLS-1$
|
|
94 | 95 |
|
95 |
public static final String OPEN_COMMAND_ID = "eu.etaxonomy.taxeditor.navigation.key.polytomous.editNodes"; |
|
96 |
public static final String OPEN_COMMAND_ID = "eu.etaxonomy.taxeditor.navigation.key.polytomous.editNodes"; //$NON-NLS-1$
|
|
96 | 97 |
|
97 | 98 |
private class ContextListener extends ContextListenerAdapter{ |
98 | 99 |
/* (non-Javadoc) |
... | ... | |
100 | 101 |
*/ |
101 | 102 |
@Override |
102 | 103 |
public void contextStop(IMemento memento, IProgressMonitor monitor) { |
103 |
monitor.subTask("Shutting down Polytomous Key Viewer");
|
|
104 |
monitor.subTask(Messages.PolytomousKeyViewPart_SHUTDOWN);
|
|
104 | 105 |
if(!viewer.getControl().isDisposed()){ |
105 | 106 |
viewer.setInput(null); |
106 | 107 |
} |
... | ... | |
111 | 112 |
*/ |
112 | 113 |
@Override |
113 | 114 |
public void contextStart(IMemento memento, IProgressMonitor monitor) { |
114 |
monitor.subTask("Initiating Polytomous Key Viewer");
|
|
115 |
monitor.subTask(Messages.PolytomousKeyViewPart_INIT);
|
|
115 | 116 |
setInput(); |
116 | 117 |
} |
117 | 118 |
} |
... | ... | |
141 | 142 |
contextListener = new ContextListener(); |
142 | 143 |
CdmStore.getContextManager().addContextListener(contextListener); |
143 | 144 |
|
144 |
text_filter = formFactory.createText(container, ""); |
|
145 |
text_filter = formFactory.createText(container, ""); //$NON-NLS-1$
|
|
145 | 146 |
text_filter.setLayoutData(new GridData(SWT.FILL, SWT.TOP, true, false)); |
146 | 147 |
text_filter.addModifyListener(new FilterModifyListener()); |
147 | 148 |
|
... | ... | |
178 | 179 |
try { |
179 | 180 |
handlerService.executeCommand(OPEN_COMMAND_ID, null); |
180 | 181 |
} catch (NotDefinedException e) { |
181 |
throw new RuntimeException("Could not find open command: " + OPEN_COMMAND_ID); |
|
182 |
throw new RuntimeException("Could not find open command: " + OPEN_COMMAND_ID); //$NON-NLS-1$
|
|
182 | 183 |
} catch (Exception e) { |
183 |
MessagingUtils.error(getClass(), "An exception occured while trying to open a selection", e);
|
|
184 |
MessagingUtils.error(getClass(), Messages.PolytomousKeyViewPart_EXCEPTION, e);
|
|
184 | 185 |
} |
185 | 186 |
} |
186 | 187 |
} |
eu.etaxonomy.taxeditor.navigation/src/main/java/eu/etaxonomy/taxeditor/navigation/key/polytomous/PolytomousKeyViewPartDataChangeBehavior.java | ||
---|---|---|
1 | 1 |
/** |
2 | 2 |
* Copyright (C) 2007 EDIT |
3 |
* European Distributed Institute of Taxonomy
|
|
3 |
* European Distributed Institute of Taxonomy |
|
4 | 4 |
* http://www.e-taxonomy.eu |
5 |
*
|
|
5 |
* |
|
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 |
*/ |
... | ... | |
21 | 21 |
import eu.etaxonomy.cdm.persistence.hibernate.CdmDataChangeEvent.EventType; |
22 | 22 |
import eu.etaxonomy.cdm.persistence.hibernate.CdmDataChangeMap; |
23 | 23 |
import eu.etaxonomy.taxeditor.model.AbstractDataChangeBehaviour; |
24 |
import eu.etaxonomy.taxeditor.navigation.l10n.Messages; |
|
24 | 25 |
|
25 | 26 |
/** |
26 | 27 |
* @author n.hoffmann |
... | ... | |
30 | 31 |
public class PolytomousKeyViewPartDataChangeBehavior extends |
31 | 32 |
AbstractDataChangeBehaviour { |
32 | 33 |
|
33 |
private final PolytomousKeyViewPart source; |
|
34 |
private static final String UPDATING_POLYTOMOUS_KEY_VIEWER = Messages.PolytomousKeyViewPartDataChangeBehavior_UPDATE; |
|
35 |
private final PolytomousKeyViewPart source; |
|
34 | 36 |
|
35 | 37 |
/** |
36 | 38 |
* @param polytomousKeyViewPart |
... | ... | |
47 | 49 |
public void reactOnDataChange(CdmDataChangeMap changeEvents) { |
48 | 50 |
if(isRelevant(changeEvents)){ |
49 | 51 |
final Display display = Display.getCurrent(); |
50 |
Job job = new Job("Updating Polytomous Key Viewer") {
|
|
51 |
|
|
52 |
Job job = new Job(UPDATING_POLYTOMOUS_KEY_VIEWER) {
|
|
53 |
|
|
52 | 54 |
@Override |
53 | 55 |
protected IStatus run(IProgressMonitor monitor) { |
54 |
monitor.beginTask("Updating Polytomous Key Viewer", 3);
|
|
56 |
monitor.beginTask(UPDATING_POLYTOMOUS_KEY_VIEWER, 3);
|
|
55 | 57 |
monitor.worked(1); |
56 |
|
|
58 |
|
|
57 | 59 |
// clear the session completely |
58 |
monitor.subTask("Clearing Polytomous Key Viewer session");
|
|
60 |
monitor.subTask(Messages.PolytomousKeyViewPartDataChangeBehavior_CLEAR);
|
|
59 | 61 |
display.asyncExec(new Runnable() { |
60 |
public void run() { |
|
62 |
@Override |
|
63 |
public void run() { |
|
61 | 64 |
source.getConversationHolder().clear(); |
62 | 65 |
} |
63 |
});
|
|
64 |
// FIXME completely clearing the session is a brute force approach.
|
|
66 |
}); |
|
67 |
// FIXME completely clearing the session is a brute force approach. |
|
65 | 68 |
// It would be much more elegant to clear only those elements that have been changed. |
66 | 69 |
// I could not get that to work but we should consider workin on this because we might |
67 | 70 |
// run into serious performance issues, especially when it comes to large trees |
... | ... | |
69 | 72 |
// at least, we moved this to a job so it can run in a background thred |
70 | 73 |
// seems to improve the situation but not sure if final solution |
71 | 74 |
monitor.worked(1); |
72 |
|
|
73 |
monitor.subTask("Refreshing viewer");
|
|
74 |
|
|
75 |
|
|
76 |
monitor.subTask(Messages.PolytomousKeyViewPartDataChangeBehavior_REFRESH);
|
|
77 |
|
|
75 | 78 |
display.asyncExec(new Runnable() { |
76 |
public void run() { |
|
79 |
@Override |
|
80 |
public void run() { |
|
77 | 81 |
source.refresh(); |
78 | 82 |
} |
79 | 83 |
}); |
80 |
|
|
81 |
|
|
82 |
|
|
84 |
|
|
85 |
|
|
86 |
|
|
83 | 87 |
monitor.worked(1); |
84 | 88 |
monitor.done(); |
85 | 89 |
return Status.OK_STATUS; |
86 | 90 |
} |
87 | 91 |
}; |
88 |
|
|
92 |
|
|
89 | 93 |
job.setPriority(Job.SHORT); |
90 | 94 |
job.schedule(); |
91 |
|
|
95 |
|
|
92 | 96 |
} |
93 | 97 |
} |
94 |
|
|
98 |
|
|
95 | 99 |
/** |
96 | 100 |
* @return |
97 | 101 |
*/ |
... | ... | |
99 | 103 |
for(CdmDataChangeEvent event : changeEvents.getAllEvents()){ |
100 | 104 |
EventType eventType = event.getEventType(); |
101 | 105 |
CdmBase eventEntity = event.getEntity(); |
102 |
|
|
106 |
|
|
103 | 107 |
// all poyltomous key changes are relevant |
104 |
if((eventType == EventType.INSERT || eventType == EventType.DELETE || eventType == EventType.UPDATE)
|
|
108 |
if((eventType == EventType.INSERT || eventType == EventType.DELETE || eventType == EventType.UPDATE) |
|
105 | 109 |
&& eventEntity instanceof PolytomousKey){ |
106 | 110 |
return true; |
107 | 111 |
} |
eu.etaxonomy.taxeditor.navigation/src/main/java/eu/etaxonomy/taxeditor/navigation/key/polytomous/handler/DeleteHandler.java | ||
---|---|---|
23 | 23 |
import eu.etaxonomy.taxeditor.navigation.NavigationUtil; |
24 | 24 |
import eu.etaxonomy.taxeditor.navigation.key.polytomous.PolytomousKeyViewPart; |
25 | 25 |
import eu.etaxonomy.taxeditor.navigation.key.polytomous.operation.DeleteOperation; |
26 |
import eu.etaxonomy.taxeditor.navigation.l10n.Messages; |
|
26 | 27 |
import eu.etaxonomy.taxeditor.operation.AbstractPostOperation; |
27 | 28 |
|
28 | 29 |
/** |
... | ... | |
32 | 33 |
*/ |
33 | 34 |
public class DeleteHandler extends AbstractHandler { |
34 | 35 |
|
35 |
/* (non-Javadoc) |
|
36 |
protected static final String CONFIRM_MESSAGE = Messages.DeleteHandler_CONFIRM_MESSAGE; |
|
37 |
protected static final String CONFIRM = Messages.DeleteHandler_CONFIRM; |
|
38 |
|
|
39 |
/* (non-Javadoc) |
|
36 | 40 |
* @see org.eclipse.core.commands.IHandler#execute(org.eclipse.core.commands.ExecutionEvent) |
37 | 41 |
*/ |
38 | 42 |
@Override |
... | ... | |
45 | 49 |
return null; |
46 | 50 |
} |
47 | 51 |
|
48 |
boolean confirmation = MessagingUtils.confirmDialog("Confirm deletion", "Do you want to delete the selected key" + (keys.size() == 1 ? "" : "s") + "?");
|
|
52 |
boolean confirmation = MessagingUtils.confirmDialog(CONFIRM, CONFIRM_MESSAGE);
|
|
49 | 53 |
|
50 | 54 |
if(confirmation){ |
51 | 55 |
|
eu.etaxonomy.taxeditor.navigation/src/main/java/eu/etaxonomy/taxeditor/navigation/key/polytomous/handler/EditPolytomousKeyNodesHandler.java | ||
---|---|---|
1 | 1 |
/** |
2 | 2 |
* Copyright (C) 2007 EDIT |
3 |
* European Distributed Institute of Taxonomy
|
|
3 |
* European Distributed Institute of Taxonomy |
|
4 | 4 |
* http://www.e-taxonomy.eu |
5 |
*
|
|
5 |
* |
|
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 |
*/ |
... | ... | |
23 | 23 |
import eu.etaxonomy.cdm.model.description.PolytomousKey; |
24 | 24 |
import eu.etaxonomy.taxeditor.navigation.NavigationUtil; |
25 | 25 |
import eu.etaxonomy.taxeditor.navigation.key.polytomous.PolytomousKeyViewPart; |
26 |
import eu.etaxonomy.taxeditor.navigation.l10n.Messages; |
|
26 | 27 |
|
27 | 28 |
/** |
28 | 29 |
* @author n.hoffmann |
... | ... | |
31 | 32 |
*/ |
32 | 33 |
public class EditPolytomousKeyNodesHandler extends AbstractHandler { |
33 | 34 |
|
34 |
/* (non-Javadoc) |
|
35 |
protected static final String OPENING_POLYTOMOUS_KEYS = Messages.EditPolytomousKeyNodesHandler_OPEN_KEYS; |
|
36 |
|
|
37 |
/* (non-Javadoc) |
|
35 | 38 |
* @see org.eclipse.core.commands.IHandler#execute(org.eclipse.core.commands.ExecutionEvent) |
36 | 39 |
*/ |
37 | 40 |
@Override |
38 | 41 |
public Object execute(ExecutionEvent event) throws ExecutionException { |
39 | 42 |
PolytomousKeyViewPart view = (PolytomousKeyViewPart) NavigationUtil.getView(PolytomousKeyViewPart.ID, false); |
40 |
|
|
41 |
ISelection selection = view.getSite().getSelectionProvider().getSelection();
|
|
43 |
|
|
44 |
ISelection selection = view.getSite().getSelectionProvider().getSelection(); |
|
42 | 45 |
if(selection instanceof StructuredSelection){ |
43 |
|
|
46 |
|
|
44 | 47 |
final StructuredSelection structuredSelection = (StructuredSelection) selection; |
45 |
|
|
46 |
Job job = new Job("Opening Polytomous Keys"){
|
|
48 |
|
|
49 |
Job job = new Job(OPENING_POLYTOMOUS_KEYS){
|
|
47 | 50 |
|
48 | 51 |
@Override |
49 | 52 |
protected IStatus run(IProgressMonitor monitor) { |
50 |
monitor.beginTask("Opening Polytomous Keys", structuredSelection.size());
|
|
51 |
|
|
53 |
monitor.beginTask(OPENING_POLYTOMOUS_KEYS, structuredSelection.size());
|
|
54 |
|
|
52 | 55 |
for(final Object selectedObject : structuredSelection.toArray()){ |
53 | 56 |
if(selectedObject instanceof PolytomousKey){ |
54 |
|
|
57 |
|
|
55 | 58 |
Display.getDefault().asyncExec(new Runnable(){ |
56 | 59 |
|
57 | 60 |
@Override |
58 |
public void run() {
|
|
61 |
public void run() { |
|
59 | 62 |
NavigationUtil.openEditor((PolytomousKey) selectedObject); |
60 | 63 |
} |
61 |
|
|
64 |
|
|
62 | 65 |
}); |
63 | 66 |
monitor.worked(1); |
64 | 67 |
} |
... | ... | |
66 | 69 |
monitor.done(); |
67 | 70 |
return Status.OK_STATUS; |
68 | 71 |
} |
69 |
|
|
72 |
|
|
70 | 73 |
}; |
71 |
|
|
74 |
|
|
72 | 75 |
job.setPriority(Job.SHORT); |
73 |
job.schedule();
|
|
74 |
|
|
76 |
job.schedule(); |
|
77 |
|
|
75 | 78 |
} |
76 | 79 |
return null; |
77 | 80 |
} |
eu.etaxonomy.taxeditor.navigation/src/main/java/eu/etaxonomy/taxeditor/navigation/key/polytomous/handler/RefreshPolytomousKeyNodesHandler.java | ||
---|---|---|
1 | 1 |
/** |
2 | 2 |
* Copyright (C) 2007 EDIT |
3 |
* European Distributed Institute of Taxonomy
|
|
3 |
* European Distributed Institute of Taxonomy |
|
4 | 4 |
* http://www.e-taxonomy.eu |
5 |
*
|
|
5 |
* |
|
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 |
*/ |
... | ... | |
20 | 20 |
import org.eclipse.core.runtime.IStatus; |
21 | 21 |
import org.eclipse.core.runtime.Status; |
22 | 22 |
import org.eclipse.core.runtime.jobs.Job; |
23 |
|
|
24 | 23 |
import org.eclipse.swt.widgets.Display; |
25 | 24 |
|
26 |
|
|
27 | 25 |
import eu.etaxonomy.cdm.model.description.PolytomousKey; |
28 | 26 |
import eu.etaxonomy.taxeditor.navigation.NavigationUtil; |
29 | 27 |
import eu.etaxonomy.taxeditor.navigation.key.polytomous.PolytomousKeyViewPart; |
30 | 28 |
import eu.etaxonomy.taxeditor.navigation.key.polytomous.operation.RefreshNodesOperation; |
29 |
import eu.etaxonomy.taxeditor.navigation.l10n.Messages; |
|
31 | 30 |
import eu.etaxonomy.taxeditor.operation.AbstractPostOperation; |
32 | 31 |
|
33 | 32 |
|
... | ... | |
40 | 39 |
*/ |
41 | 40 |
public class RefreshPolytomousKeyNodesHandler extends AbstractHandler implements IHandler { |
42 | 41 |
|
43 |
@Override |
|
42 |
private static final String REFRESHING_POLYTOMOUS_KEY_NODES = Messages.RefreshPolytomousKeyNodesHandler_REFRESHING; |
|
43 |
|
|
44 |
@Override |
|
44 | 45 |
public Object execute(ExecutionEvent event) throws ExecutionException { |
45 | 46 |
final PolytomousKeyViewPart view = (PolytomousKeyViewPart) NavigationUtil.getView(PolytomousKeyViewPart.ID, false); |
46 | 47 |
final List<PolytomousKey> keys = view.getKeys(); |
47 |
|
|
48 |
final String label = "Refresh Polytomous Key Nodes";
|
|
49 |
|
|
48 |
|
|
49 |
final String label = Messages.RefreshPolytomousKeyNodesHandler_REFRESH;
|
|
50 |
|
|
50 | 51 |
final IUndoContext undoContext = NavigationUtil.getUndoContext(); |
51 | 52 |
if (keys.size() > 0) { |
52 |
Job job = new Job("Refreshing Polytomous Key Nodes"){
|
|
53 |
|
|
53 |
Job job = new Job(REFRESHING_POLYTOMOUS_KEY_NODES){
|
|
54 |
|
|
54 | 55 |
@Override |
55 | 56 |
protected IStatus run(IProgressMonitor monitor) { |
56 |
monitor.beginTask("Refreshing Polytomous Key Nodes", keys.size());
|
|
57 |
|
|
58 |
|
|
59 |
for (final PolytomousKey key : keys) {
|
|
57 |
monitor.beginTask(REFRESHING_POLYTOMOUS_KEY_NODES, keys.size());
|
|
58 |
|
|
59 |
|
|
60 |
for (final PolytomousKey key : keys) { |
|
60 | 61 |
if(key.getRoot() != null) { |
61 | 62 |
|
62 | 63 |
Display.getDefault().asyncExec(new Runnable(){ |
63 | 64 |
|
64 | 65 |
@Override |
65 |
public void run() {
|
|
66 |
public void run() { |
|
66 | 67 |
AbstractPostOperation operation = new RefreshNodesOperation(label, undoContext, key, view); |
67 | 68 |
NavigationUtil.executeOperation(operation); |
68 | 69 |
} |
eu.etaxonomy.taxeditor.navigation/src/main/java/eu/etaxonomy/taxeditor/navigation/key/polytomous/handler/RemotingDeletePolytomousKeyHandler.java | ||
---|---|---|
57 | 57 |
return Status.CANCEL_STATUS; |
58 | 58 |
} |
59 | 59 |
|
60 |
boolean confirmation = MessagingUtils.confirmDialog("Confirm deletaion", "Do you want to delete the selected key" + (keysToDelete.size() == 1 ? "" : "s") + "?");
|
|
60 |
boolean confirmation = MessagingUtils.confirmDialog(DeleteHandler.CONFIRM, DeleteHandler.CONFIRM_MESSAGE);
|
|
61 | 61 |
|
62 | 62 |
if(!confirmation) { |
63 | 63 |
return Status.CANCEL_STATUS; |
eu.etaxonomy.taxeditor.navigation/src/main/java/eu/etaxonomy/taxeditor/navigation/key/polytomous/handler/RemotingEditPolytomousKeyNodesHandler.java | ||
---|---|---|
45 | 45 |
|
46 | 46 |
final StructuredSelection structuredSelection = (StructuredSelection) selection; |
47 | 47 |
|
48 |
Job job = new Job("Opening Polytomous Keys"){
|
|
48 |
Job job = new Job(EditPolytomousKeyNodesHandler.OPENING_POLYTOMOUS_KEYS){
|
|
49 | 49 |
|
50 | 50 |
@Override |
51 | 51 |
protected IStatus run(IProgressMonitor monitor) { |
52 |
monitor.beginTask("Opening Polytomous Keys", structuredSelection.size());
|
|
52 |
monitor.beginTask(EditPolytomousKeyNodesHandler.OPENING_POLYTOMOUS_KEYS, structuredSelection.size());
|
|
53 | 53 |
|
54 | 54 |
for(final Object selectedObject : structuredSelection.toArray()){ |
55 | 55 |
if(selectedObject instanceof PolytomousKey){ |
eu.etaxonomy.taxeditor.navigation/src/main/java/eu/etaxonomy/taxeditor/navigation/key/polytomous/operation/DeleteOperation.java | ||
---|---|---|
20 | 20 |
import eu.etaxonomy.cdm.api.service.DeleteResult; |
21 | 21 |
import eu.etaxonomy.cdm.api.service.IPolytomousKeyService; |
22 | 22 |
import eu.etaxonomy.cdm.model.description.PolytomousKey; |
23 |
import eu.etaxonomy.taxeditor.navigation.l10n.Messages; |
|
23 | 24 |
import eu.etaxonomy.taxeditor.operation.AbstractPersistentPostOperation; |
24 | 25 |
import eu.etaxonomy.taxeditor.operation.IPostOperationEnabled; |
25 | 26 |
import eu.etaxonomy.taxeditor.session.ICdmEntitySessionEnabled; |
... | ... | |
59 | 60 |
DeleteResult result = CdmStore.getService(IPolytomousKeyService.class).delete(key); |
60 | 61 |
|
61 | 62 |
if (result.isError() && !result.getExceptions().isEmpty()){ |
62 |
MessageDialog.openError(null, "Delete failed", result.getExceptions().iterator().next().getMessage());
|
|
63 |
MessageDialog.openError(null, Messages.DeleteOperation_FAILED, result.getExceptions().iterator().next().getMessage());
|
|
63 | 64 |
|
64 | 65 |
}else if(result.isAbort()){ |
65 |
MessageDialog.openWarning(null, "Delete abort", "The object could not be deleted, maybe there was no object selected.");
|
|
66 |
MessageDialog.openWarning(null, Messages.DeleteOperation_ABORT, Messages.DeleteOperation_ABORT_MESSAGE);
|
|
66 | 67 |
} |
67 | 68 |
|
68 | 69 |
return postExecute(null); |
eu.etaxonomy.taxeditor.navigation/src/main/java/eu/etaxonomy/taxeditor/navigation/key/polytomous/operation/RemotingDeletePolytomousKeyOperation.java | ||
---|---|---|
18 | 18 |
import eu.etaxonomy.cdm.api.service.IPolytomousKeyService; |
19 | 19 |
import eu.etaxonomy.cdm.api.service.UpdateResult; |
20 | 20 |
import eu.etaxonomy.cdm.model.description.PolytomousKey; |
21 |
import eu.etaxonomy.taxeditor.navigation.l10n.Messages; |
|
21 | 22 |
import eu.etaxonomy.taxeditor.operation.RemotingCdmUpdateOperation; |
22 | 23 |
import eu.etaxonomy.taxeditor.store.CdmStore; |
23 | 24 |
|
... | ... | |
28 | 29 |
*/ |
29 | 30 |
public class RemotingDeletePolytomousKeyOperation extends RemotingCdmUpdateOperation { |
30 | 31 |
|
31 |
private final static String LABEL = "Delete Polytomous Key operation";
|
|
32 |
private final static String LABEL = Messages.RemotingDeletePolytomousKeyOperation_DELETE_OP;
|
|
32 | 33 |
|
33 | 34 |
private final List<UUID> keysToDelete; |
34 | 35 |
/** |
eu.etaxonomy.taxeditor.navigation/src/main/java/eu/etaxonomy/taxeditor/navigation/key/polytomous/operation/RemotingUpdatePolytomousKeyAllNodesOperation.java | ||
---|---|---|
16 | 16 |
import eu.etaxonomy.cdm.api.application.CdmChangeEvent.Action; |
17 | 17 |
import eu.etaxonomy.cdm.api.service.IPolytomousKeyService; |
18 | 18 |
import eu.etaxonomy.cdm.api.service.UpdateResult; |
19 |
import eu.etaxonomy.taxeditor.navigation.l10n.Messages; |
|
19 | 20 |
import eu.etaxonomy.taxeditor.operation.RemotingCdmUpdateOperation; |
20 | 21 |
import eu.etaxonomy.taxeditor.store.CdmStore; |
21 | 22 |
|
... | ... | |
48 | 49 |
this.polytomousKeyUuid = null; |
49 | 50 |
} |
50 | 51 |
|
51 |
private final static String LABEL = "Update All Polytomous Key Nodes operation";
|
|
52 |
private final static String LABEL = Messages.RemotingUpdatePolytomousKeyAllNodesOperation_UPDATE_OP;
|
|
52 | 53 |
|
53 | 54 |
/* (non-Javadoc) |
54 | 55 |
* @see eu.etaxonomy.taxeditor.operation.RemotingCdmUpdateOperation#doUpdateExecute(org.eclipse.core.runtime.IProgressMonitor, org.eclipse.core.runtime.IAdaptable) |
eu.etaxonomy.taxeditor.navigation/src/main/java/eu/etaxonomy/taxeditor/navigation/l10n/Messages.java | ||
---|---|---|
17 | 17 |
*/ |
18 | 18 |
public class Messages extends NLS { |
19 | 19 |
private static final String BUNDLE_NAME = "src/main/java/eu.etaxonomy.taxeditor.navigation.l10n.messages"; //$NON-NLS-1$ |
20 |
public static String ChangeAcceptedTaxonToSynonymHandler_CHOOSE_TAXON; |
|
21 |
public static String ChangeAcceptedTaxonToSynonymHandler_CREATE_FAILED; |
|
22 |
public static String ChangeAcceptedTaxonToSynonymHandler_MOVE_SYNONYMY; |
|
23 |
public static String ChangeAcceptedTaxonToSynonymHandler_MOVE_SYNONYMY_MESSAGE; |
|
24 |
public static String ChangeAcceptedTaxonToSynonymHandler_PREREQUISITE; |
|
25 |
public static String ChangeAcceptedTaxonToSynonymHandler_PREREQUISITE_MESSAGE; |
|
26 |
public static String ChangeAcceptedTaxonToSynonymOperation_CREATE_FAIL; |
|
27 |
public static String ChangeAcceptedTaxonToSynonymOperation_CREATE_SUCCESS; |
|
28 |
public static String ChangeAcceptedTaxonToSynonymOperation_OP_FAIL; |
|
29 |
public static String ClassificationLabelProvider_UNNAMED_TREE; |
|
30 |
public static String CloneClassificationHandler_CLONE_CLASSIFICATION; |
|
31 |
public static String CreateClassificationHierarchyHandler_CREATE_HIERARCHY; |
|
32 |
public static String CreateClassificationHierarchyHandler_FAILED; |
|
33 |
public static String CreateClassificationHierarchyHandler_FAILED_MESSAGE; |
|
34 |
public static String CreateNewTaxonHierarchyOperation_ADD_HIERARCHY; |
|
35 |
public static String CreateNewTaxonHierarchyOperation_ADD_HIERARCHY_MESSAGE; |
|
36 |
public static String CreateTaxonNode_CREATE_FAILED; |
|
37 |
public static String DeleteHandler_9; |
|
38 |
public static String DeleteHandler_CONFIRM; |
|
39 |
public static String DeleteHandler_CONFIRM_DELETE; |
|
40 |
public static String DeleteHandler_CONFIRM_MESSAGE; |
|
41 |
public static String DeleteHandler_DELETE_ALL; |
|
42 |
public static String DeleteHandler_DELETE_CLASSIFICATION; |
|
43 |
public static String DeleteHandler_DELETE_NODE; |
|
44 |
public static String DeleteHandler_MOVE_TO_PARENT; |
|
45 |
public static String DeleteHandler_SKIP; |
|
46 |
public static String DeleteHandler_THERE_ARE_CHILDNODES; |
|
47 |
public static String DeleteHandler_THERE_ARE_CHILDREN; |
|
48 |
public static String DeleteOperation_ABORT; |
|
49 |
public static String DeleteOperation_ABORT_MESSAGE; |
|
50 |
public static String DeleteOperation_DELETE_FAIL; |
|
51 |
public static String DeleteOperation_DELETE_SUCCESS; |
|
52 |
public static String DeleteOperation_FAILED; |
|
53 |
public static String EditPolytomousKeyNodesHandler_OPEN_KEYS; |
|
54 |
public static String MoveFactualDataHandler_CHOOSE_TAXON; |
|
55 |
public static String MoveFactualDataHandler_CREATE_FAILED; |
|
56 |
public static String MoveFactualDataHandler_UNSAVED_SOURCE; |
|
57 |
public static String MoveFactualDataHandler_UNSAVED_SOURCE_MESSAGE; |
|
58 |
public static String MoveFactualDataHandler_UNSAVED_TARGET; |
|
59 |
public static String MoveFactualDataHandler_UNSAVED_TARGET_MESSAGE; |
|
60 |
public static String MoveTaxonHandler_CHOOSE_ABOVE; |
|
61 |
public static String MoveTaxonHandler_CHOOSE_PARENT; |
|
62 |
public static String MoveTaxonHandler_MOVE_TO_PARENT; |
|
63 |
public static String MoveTaxonHandler_TARGET_NODE; |
|
64 |
public static String MoveTaxonHandler_TARGET_NODE_MESSAGE; |
|
65 |
public static String MoveTaxonHandler_UNSAVED_PARENT; |
|
66 |
public static String MoveTaxonHandler_UNSAVED_PARENT_MESSAGE; |
|
67 |
public static String MoveTaxonOperation_NOT_IMPLEMENTED; |
|
68 |
public static String NavigationUtil_CREATE_FAILED; |
|
69 |
public static String NavigationUtil_INCORRECT_STATE; |
|
70 |
public static String NavigationUtil_INCORRECT_STATE_MESSAGE; |
|
71 |
public static String NavigationUtil_MULTI_TREE; |
|
72 |
public static String NavigationUtil_NOT_FOUND; |
|
73 |
public static String NavigationUtil_NOT_FOUND_MESSAGE; |
|
74 |
public static String NavigationUtil_NOT_IMPLEMENTED; |
|
75 |
public static String NavigationUtil_OPEN_ERROR; |
|
76 |
public static String NavigationUtil_ORPHAN_NAME_MESSAGE; |
|
77 |
public static String NavigationUtil_ORPHAN_TAXON; |
|
78 |
public static String NavigationUtil_UNKNOWN_TYPE; |
|
79 |
public static String NavigationUtil_UNKNOWN_TYPE_MESSAGE; |
|
80 |
public static String NavigationUtil_UNSUPPORTED_TYPE; |
|
81 |
public static String NavigationUtil_UNSUPPORTED_TYPE_MESSAGE; |
|
82 |
public static String PolytomousKeyViewLabels_DELETE; |
|
83 |
public static String PolytomousKeyViewLabels_OPEN_ERROR; |
|
84 |
public static String PolytomousKeyViewLabels_UPDATE; |
|
85 |
public static String PolytomousKeyViewPart_EXCEPTION; |
|
86 |
public static String PolytomousKeyViewPart_INIT; |
|
87 |
public static String PolytomousKeyViewPart_SHUTDOWN; |
|
88 |
public static String PolytomousKeyViewPartDataChangeBehavior_CLEAR; |
|
89 |
public static String PolytomousKeyViewPartDataChangeBehavior_REFRESH; |
|
90 |
public static String PolytomousKeyViewPartDataChangeBehavior_UPDATE; |
|
91 |
public static String RefreshPolytomousKeyNodesHandler_REFRESH; |
|
92 |
public static String RefreshPolytomousKeyNodesHandler_REFRESHING; |
|
93 |
public static String RemotingChangeAcceptedTaxonToSynonymHandler_CHOOSE_TAXON; |
|
94 |
public static String RemotingChangeAcceptedTaxonToSynonymOperation_CHANGE_OP; |
|
95 |
public static String RemotingDeletePolytomousKeyOperation_DELETE_OP; |
|
96 |
public static String RemotingDeleteTaxonNodeHandler_NODE_DELETED; |
|
97 |
public static String RemotingDeleteTaxonNodeHandler_NODE_DELETED_MESSAGE; |
|
98 |
public static String RemotingDeleteTaxonNodeOperation_DELETE_OP; |
|
99 |
public static String RemotingMoveFactualDataHandler_CHOOSE_TAXA; |
|
100 |
public static String RemotingMoveFactualDataHandler_CREATE_FAILED; |
|
101 |
public static String RemotingMoveFactualDataOperation_MOVE_OP; |
|
102 |
public static String RemotingMoveTaxonNodeHandler_BEHIND; |
|
103 |
public static String RemotingMoveTaxonNodeHandler_CANCEL; |
|
104 |
public static String RemotingMoveTaxonNodeHandler_CHILD; |
|
105 |
public static String RemotingMoveTaxonNodeHandler_CHOOSE_PARENT; |
|
106 |
public static String RemotingMoveTaxonNodeHandler_CHOOSE_TAXON; |
|
107 |
public static String RemotingMoveTaxonNodeHandler_TARGET_NODE; |
|
108 |
public static String RemotingMoveTaxonNodeHandler_TARGET_NODE_MESSAGE; |
|
109 |
public static String RemotingMoveTaxonNodeHandler_UNSAVED_PARENT; |
|
110 |
public static String RemotingMoveTaxonNodeHandler_UNSAVED_PARENT_MESSAGE; |
|
111 |
public static String RemotingMoveTaxonOperation_MOVE_OP; |
|
112 |
public static String RemotingUpdatePolytomousKeyAllNodesOperation_UPDATE_OP; |
|
113 |
public static String Root_CREATE_CLASSIFICATION; |
|
114 |
public static String Root_MY_CLASSIFICATION; |
|
20 | 115 |
public static String SearchBar_0; |
21 | 116 |
public static String SearchBar_1; |
22 | 117 |
public static String SearchBar_2; |
... | ... | |
26 | 121 |
public static String SearchBar_7; |
27 | 122 |
public static String SearchBar_8; |
28 | 123 |
public static String SearchBar_9; |
124 |
public static String SearchResultLabelProvider_NAME; |
|
125 |
public static String SearchResultLabelProvider_SYNONYM; |
|
126 |
public static String SearchResultLabelProvider_TAXON; |
|
127 |
public static String SearchResultView_CANCELLED; |
|
128 |
public static String SearchResultView_CNT_ENTITIES_FOUND; |
|
129 |
public static String SearchResultView_NO_RESULTS; |
|
130 |
public static String SearchResultView_PERFORMING_SEARCH; |
|
131 |
public static String SearchResultView_REMOVE_SEARCH_RESULTS; |
|
132 |
public static String SearchResultView_SEARCH; |
|
133 |
public static String SearchResultView_SEARCH_FOR; |
|
134 |
public static String SearchResultView_SEARCH_STRING; |
|
135 |
public static String SearchResultView_SEARCHING; |
|
136 |
public static String SearchResultView_STATUS; |
|
137 |
public static String SetSecundumForSubtreeOperation_CHANGE_SEC_OP; |
|
138 |
public static String SetSecundumForSubtreeOperation_SET_SEC_TASK; |
|
139 |
public static String TaxonLinkHelper_CREATE_FAIL; |
|
140 |
|
|
141 |
public static String TaxonNavigator_LOAD_DATASOURCE; |
|
142 |
public static String TaxonNavigator_RESTORE; |
|
143 |
public static String TaxonNavigator_SAVE_TASK; |
|
144 |
public static String TaxonNavigator_TAXON_TREE; |
|
145 |
|
|
146 |
public static String TaxonNavigatorDataChangeBehavior_CLEAR_SESSION; |
|
147 |
public static String TaxonNavigatorDataChangeBehavior_REFRESH_VIEWER; |
|
148 |
public static String TaxonNavigatorDataChangeBehavior_UPDATE_NAVIGATOR; |
|
149 |
public static String TaxonNavigatorLabels_CHANGE_ACC_TAXON; |
|
150 |
public static String TaxonNavigatorLabels_CLOSE_IMPOSSIBLE; |
|
151 |
public static String TaxonNavigatorLabels_DELETE_TAXON; |
|
152 |
|
|
153 |
public static String TaxonNavigatorLabels_MOVE_FACTUAL_DATA; |
|
154 |
public static String TaxonNavigatorLabels_MOVE_TAXON; |
|
155 |
public static String TaxonNavigatorLabels_NO_CHILDREN_ALLOWED; |
|
156 |
public static String TaxonNavigatorLabels_NOT_A_NODE; |
|
157 |
public static String TaxonNavigatorLabels_NOT_TAXON_SELECTED; |
|
158 |
public static String TaxonNavigatorLabels_ONLY_SINGLE_TAXON; |
|
159 |
public static String TaxonNavigatorLabels_SET_SEC_FOR_CHILDREN; |
|
160 |
public static String TaxonNavigatorLabels_UNSAVED_CHANGES; |
|
161 |
|
|
162 |
public static String TaxonNodeLabelProvider_NO_TAXON; |
|
163 |
public static String TaxonNodeLabelProvider_NODE_WITH_NO_TAXON; |
|
164 |
public static String TaxonNodeLabelProvider_TAXON; |
|
165 |
|
|
166 |
public static String TreeNodeDropAdapter_10; |
|
167 |
public static String TreeNodeDropAdapter_BEHIND; |
|
168 |
public static String TreeNodeDropAdapter_CANCEL; |
|
169 |
public static String TreeNodeDropAdapter_CHILD; |
|
170 |
public static String TreeNodeDropAdapter_MOVE_BEHIND; |
|
171 |
public static String TreeNodeDropAdapter_MOVE_TAXON; |
|
172 |
public static String TreeNodeDropAdapter_MOVING; |
|
173 |
public static String TreeNodeDropAdapter_MOVING_MESSAGE; |
|
174 |
public static String TreeNodeDropAdapter_TARGET_NODE; |
|
175 |
public static String TreeNodeDropAdapter_UNSAVED_PARENT; |
|
176 |
public static String TreeNodeDropAdapter_UNSAVED_PARENT_MESSAGE; |
|
29 | 177 |
|
30 | 178 |
static { |
31 | 179 |
// initialize resource bundle |
eu.etaxonomy.taxeditor.navigation/src/main/java/eu/etaxonomy/taxeditor/navigation/l10n/messages.properties | ||
---|---|---|
1 |
ChangeAcceptedTaxonToSynonymHandler_CHOOSE_TAXON=Choose the accepted taxon |
|
2 |
ChangeAcceptedTaxonToSynonymHandler_CREATE_FAILED=Could not create Taxon |
|
3 |
ChangeAcceptedTaxonToSynonymHandler_MOVE_SYNONYMY=Moving to synonymy |
|
4 |
ChangeAcceptedTaxonToSynonymHandler_MOVE_SYNONYMY_MESSAGE=The operation move accepted taxon to synonymy is available only for a single taxon. |
|
5 |
ChangeAcceptedTaxonToSynonymHandler_PREREQUISITE=Prerequisite not met |
|
6 |
ChangeAcceptedTaxonToSynonymHandler_PREREQUISITE_MESSAGE=The accepted taxon must not have any childen. You need to move all childen to another taxon node in the TaxonNavigator before attempting to turn the accepted taxon into a synonym. |
|
7 |
ChangeAcceptedTaxonToSynonymOperation_CREATE_FAIL=Synonym creation not possible |
|
8 |
ChangeAcceptedTaxonToSynonymOperation_CREATE_SUCCESS=Synonym created but taxon deletion not possible. |
|
9 |
ChangeAcceptedTaxonToSynonymOperation_OP_FAIL=Operation failed |
|
10 |
ClassificationLabelProvider_UNNAMED_TREE=Unnamed Taxonomic Tree |
|
11 |
CloneClassificationHandler_CLONE_CLASSIFICATION=Clone classification |
|
12 |
CreateClassificationHierarchyHandler_CREATE_HIERARCHY=Create Taxon Hierarchy |
|
13 |
CreateClassificationHierarchyHandler_FAILED=Failed to open Editor |
|
14 |
CreateClassificationHierarchyHandler_FAILED_MESSAGE=Could not open distribution view. The hierarchy is corrupted\! |
|
15 |
CreateNewTaxonHierarchyOperation_ADD_HIERARCHY=Add Hierarchy successful |
|
16 |
CreateNewTaxonHierarchyOperation_ADD_HIERARCHY_MESSAGE=New classification is %s\nCreated Genus: %d\nCreated Subspecies: %d |
|
17 |
CreateTaxonNode_CREATE_FAILED=Could not create taxon node |
|
18 |
DeleteHandler_9=Command name not set |
|
19 |
DeleteHandler_CONFIRM=Confirm deletion |
|
20 |
DeleteHandler_CONFIRM_DELETE=Confirm Deletion |
|
21 |
DeleteHandler_CONFIRM_MESSAGE=Do you want to delete the selected key(s)? |
|
22 |
DeleteHandler_DELETE_ALL=Delete all children |
|
23 |
DeleteHandler_DELETE_CLASSIFICATION=Do you really want to delete the classification? |
|
24 |
DeleteHandler_DELETE_NODE=Do you really want to delete the selected node(s)? |
|
25 |
DeleteHandler_MOVE_TO_PARENT=Move children to parent node |
|
26 |
DeleteHandler_SKIP=Skip |
|
27 |
DeleteHandler_THERE_ARE_CHILDNODES=\ There are childnodes, which will be deleted, too. |
|
28 |
DeleteHandler_THERE_ARE_CHILDREN=\ The tree has children, they will be deleted, too. |
|
29 |
DeleteOperation_ABORT=Delete abort |
|
30 |
DeleteOperation_ABORT_MESSAGE=The object could not be deleted, maybe there was no object selected. |
|
31 |
DeleteOperation_DELETE_FAIL=TaxonNode could not be deleted. |
|
32 |
DeleteOperation_DELETE_SUCCESS=TaxonNode was successfully deleted, but related object(s) could not be deleted |
|
33 |
DeleteOperation_FAILED=Delete failed |
|
34 |
EditPolytomousKeyNodesHandler_OPEN_KEYS=Opening Polytomous Keys |
|
35 |
MoveFactualDataHandler_CHOOSE_TAXON=Choose the accepted taxon |
|
36 |
MoveFactualDataHandler_CREATE_FAILED=Could not create Taxon |
|
37 |
MoveFactualDataHandler_UNSAVED_SOURCE=Unsaved Source Taxon |
|
38 |
MoveFactualDataHandler_UNSAVED_SOURCE_MESSAGE=There are unsaved changes in the source taxon. Please save first. |
|
39 |
MoveFactualDataHandler_UNSAVED_TARGET=Unsaved Target Taxon |
|
40 |
MoveFactualDataHandler_UNSAVED_TARGET_MESSAGE=There are unsaved changes in the target taxon. Please save first. |
|
41 |
MoveTaxonHandler_CHOOSE_ABOVE=Choose the taxon above the moved taxon. |
|
42 |
MoveTaxonHandler_CHOOSE_PARENT=Choose new parent |
|
43 |
MoveTaxonHandler_MOVE_TO_PARENT=Move taxon to new parent |
|
44 |
MoveTaxonHandler_TARGET_NODE=Target node |
|
45 |
MoveTaxonHandler_TARGET_NODE_MESSAGE=The choosen target node should be the parent? |
|
46 |
MoveTaxonHandler_UNSAVED_PARENT=Unsaved Parent Taxon |
|
47 |
MoveTaxonHandler_UNSAVED_PARENT_MESSAGE=There are unsaved changes in the parent taxon. Please save first. |
|
48 |
MoveTaxonOperation_NOT_IMPLEMENTED=Not implemented yet. |
|
49 |
NavigationUtil_CREATE_FAILED=Could not create Taxon |
|
50 |
NavigationUtil_INCORRECT_STATE=Incorrect state |
|
51 |
NavigationUtil_INCORRECT_STATE_MESSAGE=The accepted taxon is not in a taxonomic view. This should not have happened. |
|
52 |
NavigationUtil_MULTI_TREE=The accepted taxon is in multiple taxonomic trees. We currently do not know which one you want to open. This case is not handled yet by the software. |
|
53 |
NavigationUtil_NOT_FOUND=Cdm entity not found |
|
54 |
NavigationUtil_NOT_FOUND_MESSAGE=CDM entity could not be found in the database. |
|
55 |
NavigationUtil_NOT_IMPLEMENTED=Not implemented yet |
|
56 |
NavigationUtil_OPEN_ERROR=Error opening the editor |
|
57 |
NavigationUtil_ORPHAN_NAME_MESSAGE=You chose to open a name that has no connection to a taxon. The Editor does not support editing of such a content type at the moment. |
|
58 |
NavigationUtil_ORPHAN_TAXON=This taxon is not connected to a classification. Currently editing of such taxa is not supported yet. |
|
59 |
NavigationUtil_UNKNOWN_TYPE=Unknown type |
|
60 |
NavigationUtil_UNKNOWN_TYPE_MESSAGE=There is no editor available to open this object. |
|
61 |
NavigationUtil_UNSUPPORTED_TYPE=Unsupported Type |
|
62 |
NavigationUtil_UNSUPPORTED_TYPE_MESSAGE=No editor exists for the current selection: |
|
63 |
PolytomousKeyViewLabels_DELETE=Delete Polytomous Key |
|
64 |
PolytomousKeyViewLabels_OPEN_ERROR=Error opening Polytomous Key Editor |
|
65 |
PolytomousKeyViewLabels_UPDATE=Update All Polytomous Key Nodes |
|
66 |
PolytomousKeyViewPart_EXCEPTION=An exception occured while trying to open a selection |
|
67 |
PolytomousKeyViewPart_INIT=Initiating Polytomous Key Viewer |
|
68 |
PolytomousKeyViewPart_SHUTDOWN=Shutting down Polytomous Key Viewer |
|
69 |
PolytomousKeyViewPartDataChangeBehavior_CLEAR=Clearing Polytomous Key Viewer session |
|
70 |
PolytomousKeyViewPartDataChangeBehavior_REFRESH=Refreshing viewer |
|
71 |
PolytomousKeyViewPartDataChangeBehavior_UPDATE=Updating Polytomous Key Viewer |
|
72 |
RefreshPolytomousKeyNodesHandler_REFRESH=Refresh Polytomous Key Nodes |
|
73 |
RefreshPolytomousKeyNodesHandler_REFRESHING=Refreshing Polytomous Key Nodes |
|
74 |
RemotingChangeAcceptedTaxonToSynonymHandler_CHOOSE_TAXON=Choose the accepted taxon |
|
75 |
RemotingChangeAcceptedTaxonToSynonymOperation_CHANGE_OP=Change Accepted Taxon to Synonym operation |
|
76 |
RemotingDeletePolytomousKeyOperation_DELETE_OP=Delete Polytomous Key operation |
|
77 |
RemotingDeleteTaxonNodeHandler_NODE_DELETED=Node already deleted |
|
78 |
RemotingDeleteTaxonNodeHandler_NODE_DELETED_MESSAGE=The taxon node was already deleted. Please reopen the taxon navigator to refresh the view. |
|
79 |
RemotingDeleteTaxonNodeOperation_DELETE_OP=Delete Taxon Node operation |
|
80 |
RemotingMoveFactualDataHandler_CHOOSE_TAXA=Choose the accepted taxon |
|
81 |
RemotingMoveFactualDataHandler_CREATE_FAILED=Could not create Taxon |
|
82 |
RemotingMoveFactualDataOperation_MOVE_OP=Move Factual Data operation |
|
83 |
RemotingMoveTaxonNodeHandler_BEHIND=Behind |
|
84 |
RemotingMoveTaxonNodeHandler_CANCEL=Cancel |
|
85 |
RemotingMoveTaxonNodeHandler_CHILD=Child |
|
86 |
RemotingMoveTaxonNodeHandler_CHOOSE_PARENT=Choose new parent |
|
87 |
RemotingMoveTaxonNodeHandler_CHOOSE_TAXON=Choose the taxon above the moved taxon. |
|
88 |
RemotingMoveTaxonNodeHandler_TARGET_NODE=Target node |
|
89 |
RemotingMoveTaxonNodeHandler_TARGET_NODE_MESSAGE=Do you want to move the Taxonnode as child or behind the target node. |
|
90 |
RemotingMoveTaxonNodeHandler_UNSAVED_PARENT=Unsaved Parent Taxon |
|
91 |
RemotingMoveTaxonNodeHandler_UNSAVED_PARENT_MESSAGE=There are unsaved changes in the parent taxon. Please save first. |
|
92 |
RemotingMoveTaxonOperation_MOVE_OP=Move Taxon operation |
|
93 |
RemotingUpdatePolytomousKeyAllNodesOperation_UPDATE_OP=Update All Polytomous Key Nodes operation |
|
94 |
Root_CREATE_CLASSIFICATION=Creating initial classification |
|
95 |
Root_MY_CLASSIFICATION=My Classification |
|
1 | 96 |
SearchBar_0=Use "*" for wildcard searching |
2 | 97 |
SearchBar_1=Search |
3 | 98 |
SearchBar_2=Could not execute search |
... | ... | |
7 | 102 |
SearchBar_7=Synonyms |
8 | 103 |
SearchBar_8=Names (without taxa) |
9 | 104 |
SearchBar_9=Common Names |
105 |
SearchResultLabelProvider_NAME=Name: |
|
106 |
SearchResultLabelProvider_SYNONYM=Synonym: |
|
107 |
SearchResultLabelProvider_TAXON=Taxon: |
|
108 |
SearchResultView_CANCELLED=Cancelled |
|
109 |
SearchResultView_CNT_ENTITIES_FOUND=%d entities found |
|
110 |
SearchResultView_NO_RESULTS=Search returned no results |
|
111 |
SearchResultView_PERFORMING_SEARCH=Performing Search |
|
112 |
SearchResultView_REMOVE_SEARCH_RESULTS=Getting rid of search results |
|
113 |
SearchResultView_SEARCH=Search: '%s' |
|
114 |
SearchResultView_SEARCH_FOR=Search for: |
|
115 |
SearchResultView_SEARCH_STRING=Search String: |
|
116 |
SearchResultView_SEARCHING=Searching... |
|
117 |
SearchResultView_STATUS=Status: |
|
118 |
SetSecundumForSubtreeOperation_CHANGE_SEC_OP=Change secundum reference for all children |
|
119 |
SetSecundumForSubtreeOperation_SET_SEC_TASK=Set secundum reference for subtree |
|
120 |
TaxonLinkHelper_CREATE_FAIL=Could not create Taxon |
|
121 |
TaxonNavigator_LOAD_DATASOURCE=Loading datasources |
|
122 |
TaxonNavigator_RESTORE=Restoring Taxon Navigator |
|
123 |
TaxonNavigator_SAVE_TASK=Saving Taxon Navigator State |
|
124 |
TaxonNavigator_TAXON_TREE=Taxonomic Tree |
|
125 |
TaxonNavigatorDataChangeBehavior_CLEAR_SESSION=Clearing Taxon Navigators session |
|
126 |
TaxonNavigatorDataChangeBehavior_REFRESH_VIEWER=Refreshing viewer |
|
127 |
TaxonNavigatorDataChangeBehavior_UPDATE_NAVIGATOR=Updating Taxon Navigator |
|
128 |
TaxonNavigatorLabels_CHANGE_ACC_TAXON=Change Accepted Taxon to Synonym |
|
129 |
TaxonNavigatorLabels_CLOSE_IMPOSSIBLE=Could not close related taxon name editor. Please close it manually and try again. |
|
130 |
TaxonNavigatorLabels_DELETE_TAXON=Delete Taxon Node |
|
131 |
TaxonNavigatorLabels_MOVE_FACTUAL_DATA=Move Factual Data |
|
132 |
TaxonNavigatorLabels_MOVE_TAXON=Move Taxon |
|
133 |
TaxonNavigatorLabels_NO_CHILDREN_ALLOWED=The chosen taxon must not have any childen. You need to move all childen to another taxon node in the TaxonNavigator before attempting to turn the accepted taxon into a synonym. |
|
134 |
TaxonNavigatorLabels_NOT_A_NODE=Selected object is not a taxon tree node |
|
135 |
TaxonNavigatorLabels_NOT_TAXON_SELECTED=No taxon tree node selected for operation. |
|
136 |
TaxonNavigatorLabels_ONLY_SINGLE_TAXON=The chosen operation is available only for a single taxon. |
|
137 |
TaxonNavigatorLabels_SET_SEC_FOR_CHILDREN=Set new Secundum Reference for all children. |
|
138 |
TaxonNavigatorLabels_UNSAVED_CHANGES=There are unsaved changes in the source taxon. Please save first. |
|
139 |
TaxonNodeLabelProvider_NO_TAXON=>NO TAXON< |
|
140 |
TaxonNodeLabelProvider_NODE_WITH_NO_TAXON=The taxon node does not have a taxon attached to it. Please check your import. TaxonNode: %s |
|
141 |
TaxonNodeLabelProvider_TAXON=Taxon: |
|
142 |
TreeNodeDropAdapter_10=\ |
|
143 |
TreeNodeDropAdapter_BEHIND=Behind |
|
144 |
TreeNodeDropAdapter_CANCEL=Cancel |
|
145 |
TreeNodeDropAdapter_CHILD=Child |
|
146 |
TreeNodeDropAdapter_MOVE_BEHIND=Do you want to move the Taxonnode as child or behind the target node. |
|
147 |
TreeNodeDropAdapter_MOVE_TAXON=Move Taxon |
|
148 |
TreeNodeDropAdapter_MOVING=Moving taxon |
|
149 |
TreeNodeDropAdapter_MOVING_MESSAGE=The operation move accepted taxon to other parent is available only for a single taxon. |
|
150 |
TreeNodeDropAdapter_TARGET_NODE=Target node |
|
151 |
TreeNodeDropAdapter_UNSAVED_PARENT=Unsaved Parent Taxon |
|
152 |
TreeNodeDropAdapter_UNSAVED_PARENT_MESSAGE=There are unsaved changes in the parent taxon. Pleas save first. |
eu.etaxonomy.taxeditor.navigation/src/main/java/eu/etaxonomy/taxeditor/navigation/l10n/messages_de.properties | ||
---|---|---|
1 |
ChangeAcceptedTaxonToSynonymHandler_CHOOSE_TAXON=Choose the accepted taxon |
|
2 |
ChangeAcceptedTaxonToSynonymHandler_CREATE_FAILED=Could not create Taxon |
|
3 |
ChangeAcceptedTaxonToSynonymHandler_MOVE_SYNONYMY=Moving to synonymy |
|
4 |
ChangeAcceptedTaxonToSynonymHandler_MOVE_SYNONYMY_MESSAGE=The operation move accepted taxon to synonymy is available only for a single taxon. |
|
5 |
ChangeAcceptedTaxonToSynonymHandler_PREREQUISITE=Prerequisite not met |
|
6 |
ChangeAcceptedTaxonToSynonymHandler_PREREQUISITE_MESSAGE=The accepted taxon must not have any childen. You need to move all childen to another taxon node in the TaxonNavigator before attempting to turn the accepted taxon into a synonym. |
|
7 |
ChangeAcceptedTaxonToSynonymOperation_CREATE_FAIL=Synonym creation not possible |
|
8 |
ChangeAcceptedTaxonToSynonymOperation_CREATE_SUCCESS=Synonym created but taxon deletion not possible. |
|
9 |
ChangeAcceptedTaxonToSynonymOperation_OP_FAIL=Operation failed |
|
10 |
ClassificationLabelProvider_UNNAMED_TREE=Unnamed Taxonomic Tree |
|
11 |
CloneClassificationHandler_CLONE_CLASSIFICATION=Clone classification |
|
12 |
CreateClassificationHierarchyHandler_CREATE_HIERARCHY=Create Taxon Hierarchy |
|
13 |
CreateClassificationHierarchyHandler_FAILED=Failed to open Editor |
|
14 |
CreateClassificationHierarchyHandler_FAILED_MESSAGE=Could not open distribution view. The hierarchy is corrupted\! |
|
15 |
CreateNewTaxonHierarchyOperation_ADD_HIERARCHY=Add Hierarchy successful |
|
16 |
CreateNewTaxonHierarchyOperation_ADD_HIERARCHY_MESSAGE=New classification is %s\nCreated Genus: %d\nCreated Subspecies: %d |
|
17 |
CreateTaxonNode_CREATE_FAILED=Could not create taxon node |
|
18 |
DeleteHandler_9=Command name not set |
|
19 |
DeleteHandler_CONFIRM=Confirm deletion |
|
20 |
DeleteHandler_CONFIRM_DELETE=Confirm Deletion |
|
21 |
DeleteHandler_CONFIRM_MESSAGE=Do you want to delete the selected key(s)? |
|
22 |
DeleteHandler_DELETE_ALL=Delete all children |
|
23 |
DeleteHandler_DELETE_CLASSIFICATION=Do you really want to delete the classification? |
|
24 |
DeleteHandler_DELETE_NODE=Do you really want to delete the selected node(s)? |
|
25 |
DeleteHandler_MOVE_TO_PARENT=Move children to parent node |
|
26 |
DeleteHandler_SKIP=Skip |
|
27 |
DeleteHandler_THERE_ARE_CHILDNODES=\ There are childnodes, which will be deleted, too. |
|
28 |
DeleteHandler_THERE_ARE_CHILDREN=\ The tree has children, they will be deleted, too. |
|
29 |
DeleteOperation_ABORT=Delete abort |
|
30 |
DeleteOperation_ABORT_MESSAGE=The object could not be deleted, maybe there was no object selected. |
|
31 |
DeleteOperation_DELETE_FAIL=TaxonNode could not be deleted. |
|
32 |
DeleteOperation_DELETE_SUCCESS=TaxonNode was successfully deleted, but related object(s) could not be deleted |
|
33 |
DeleteOperation_FAILED=Delete failed |
|
34 |
EditPolytomousKeyNodesHandler_OPEN_KEYS=Opening Polytomous Keys |
|
35 |
MoveFactualDataHandler_CHOOSE_TAXON=Choose the accepted taxon |
|
36 |
MoveFactualDataHandler_CREATE_FAILED=Could not create Taxon |
|
37 |
MoveFactualDataHandler_UNSAVED_SOURCE=Unsaved Source Taxon |
|
38 |
MoveFactualDataHandler_UNSAVED_SOURCE_MESSAGE=There are unsaved changes in the source taxon. Please save first. |
|
39 |
MoveFactualDataHandler_UNSAVED_TARGET=Unsaved Target Taxon |
|
40 |
MoveFactualDataHandler_UNSAVED_TARGET_MESSAGE=There are unsaved changes in the target taxon. Please save first. |
|
41 |
MoveTaxonHandler_CHOOSE_ABOVE=Choose the taxon above the moved taxon. |
|
42 |
MoveTaxonHandler_CHOOSE_PARENT=Choose new parent |
|
43 |
MoveTaxonHandler_MOVE_TO_PARENT=Move taxon to new parent |
|
44 |
MoveTaxonHandler_TARGET_NODE=Target node |
|
45 |
MoveTaxonHandler_TARGET_NODE_MESSAGE=The choosen target node should be the parent? |
|
46 |
MoveTaxonHandler_UNSAVED_PARENT=Unsaved Parent Taxon |
|
47 |
MoveTaxonHandler_UNSAVED_PARENT_MESSAGE=There are unsaved changes in the parent taxon. Please save first. |
|
48 |
MoveTaxonOperation_NOT_IMPLEMENTED=Not implemented yet. |
|
49 |
NavigationUtil_CREATE_FAILED=Could not create Taxon |
|
50 |
NavigationUtil_INCORRECT_STATE=Incorrect state |
|
51 |
NavigationUtil_INCORRECT_STATE_MESSAGE=The accepted taxon is not in a taxonomic view. This should not have happened. |
|
52 |
NavigationUtil_MULTI_TREE=The accepted taxon is in multiple taxonomic trees. We currently do not know which one you want to open. This case is not handled yet by the software. |
|
53 |
NavigationUtil_NOT_FOUND=Cdm entity not found |
|
54 |
NavigationUtil_NOT_FOUND_MESSAGE=CDM entity could not be found in the database. |
|
55 |
NavigationUtil_NOT_IMPLEMENTED=Not implemented yet |
|
56 |
NavigationUtil_OPEN_ERROR=Error opening the editor |
|
57 |
NavigationUtil_ORPHAN_NAME_MESSAGE=You chose to open a name that has no connection to a taxon. The Editor does not support editing of such a content type at the moment. |
|
58 |
NavigationUtil_ORPHAN_TAXON=This taxon is not connected to a classification. Currently editing of such taxa is not supported yet. |
|
59 |
NavigationUtil_UNKNOWN_TYPE=Unknown type |
|
60 |
NavigationUtil_UNKNOWN_TYPE_MESSAGE=There is no editor available to open this object. |
|
61 |
NavigationUtil_UNSUPPORTED_TYPE=Unsupported Type |
|
62 |
NavigationUtil_UNSUPPORTED_TYPE_MESSAGE=No editor exists for the current selection: |
|
63 |
PolytomousKeyViewLabels_DELETE=Delete Polytomous Key |
|
64 |
PolytomousKeyViewLabels_OPEN_ERROR=Error opening Polytomous Key Editor |
|
65 |
PolytomousKeyViewLabels_UPDATE=Update All Polytomous Key Nodes |
|
66 |
PolytomousKeyViewPart_EXCEPTION=An exception occured while trying to open a selection |
|
67 |
PolytomousKeyViewPart_INIT=Initiating Polytomous Key Viewer |
|
68 |
PolytomousKeyViewPart_SHUTDOWN=Shutting down Polytomous Key Viewer |
|
69 |
PolytomousKeyViewPartDataChangeBehavior_CLEAR=Clearing Polytomous Key Viewer session |
|
70 |
PolytomousKeyViewPartDataChangeBehavior_REFRESH=Refreshing viewer |
|
71 |
PolytomousKeyViewPartDataChangeBehavior_UPDATE=Updating Polytomous Key Viewer |
|
72 |
RefreshPolytomousKeyNodesHandler_REFRESH=Refresh Polytomous Key Nodes |
|
73 |
RefreshPolytomousKeyNodesHandler_REFRESHING=Refreshing Polytomous Key Nodes |
|
74 |
RemotingChangeAcceptedTaxonToSynonymHandler_CHOOSE_TAXON=Choose the accepted taxon |
|
75 |
RemotingChangeAcceptedTaxonToSynonymOperation_CHANGE_OP=Change Accepted Taxon to Synonym operation |
|
76 |
RemotingDeletePolytomousKeyOperation_DELETE_OP=Delete Polytomous Key operation |
|
77 |
RemotingDeleteTaxonNodeHandler_NODE_DELETED=Node already deleted |
|
78 |
RemotingDeleteTaxonNodeHandler_NODE_DELETED_MESSAGE=The taxon node was already deleted. Please reopen the taxon navigator to refresh the view. |
|
79 |
RemotingDeleteTaxonNodeOperation_DELETE_OP=Delete Taxon Node operation |
|
80 |
RemotingMoveFactualDataHandler_CHOOSE_TAXA=Choose the accepted taxon |
|
81 |
RemotingMoveFactualDataHandler_CREATE_FAILED=Could not create Taxon |
|
82 |
RemotingMoveFactualDataOperation_MOVE_OP=Move Factual Data operation |
|
83 |
RemotingMoveTaxonNodeHandler_BEHIND=Behind |
|
84 |
RemotingMoveTaxonNodeHandler_CANCEL=Cancel |
|
85 |
RemotingMoveTaxonNodeHandler_CHILD=Child |
|
86 |
RemotingMoveTaxonNodeHandler_CHOOSE_PARENT=Choose new parent |
|
87 |
RemotingMoveTaxonNodeHandler_CHOOSE_TAXON=Choose the taxon above the moved taxon. |
|
88 |
RemotingMoveTaxonNodeHandler_TARGET_NODE=Target node |
|
89 |
RemotingMoveTaxonNodeHandler_TARGET_NODE_MESSAGE=Do you want to move the Taxonnode as child or behind the target node. |
|
90 |
RemotingMoveTaxonNodeHandler_UNSAVED_PARENT=Unsaved Parent Taxon |
|
91 |
RemotingMoveTaxonNodeHandler_UNSAVED_PARENT_MESSAGE=There are unsaved changes in the parent taxon. Please save first. |
|
92 |
RemotingMoveTaxonOperation_MOVE_OP=Move Taxon operation |
|
93 |
RemotingUpdatePolytomousKeyAllNodesOperation_UPDATE_OP=Update All Polytomous Key Nodes operation |
|
94 |
Root_CREATE_CLASSIFICATION=Creating initial classification |
|
95 |
Root_MY_CLASSIFICATION=My Classification |
|
1 | 96 |
SearchBar_0=Benutze "*" f\u00FCr Platzhalter-Suche |
2 | 97 |
SearchBar_1=Suche |
3 | 98 |
SearchBar_2=Suche konnte nicht ausgef\u00FChrt werden |
... | ... | |
7 | 102 |
SearchBar_7=Synonyme |
8 | 103 |
SearchBar_8=Namen (ohne Taxa) |
9 | 104 |
SearchBar_9=Umgangsprachliche Namen |
105 |
SearchResultLabelProvider_NAME=Name: |
|
106 |
SearchResultLabelProvider_SYNONYM=Synonym: |
|
107 |
SearchResultLabelProvider_TAXON=Taxon: |
|
108 |
SearchResultView_CANCELLED=Cancelled |
|
109 |
SearchResultView_CNT_ENTITIES_FOUND=%d entities found |
|
110 |
SearchResultView_NO_RESULTS=Search returned no results |
|
111 |
SearchResultView_PERFORMING_SEARCH=Performing Search |
|
112 |
SearchResultView_REMOVE_SEARCH_RESULTS=Getting rid of search results |
|
113 |
SearchResultView_SEARCH=Search: '%s' |
|
114 |
SearchResultView_SEARCH_FOR=Search for: |
|
115 |
SearchResultView_SEARCH_STRING=Search String: |
|
116 |
SearchResultView_SEARCHING=Searching... |
|
117 |
SearchResultView_STATUS=Status: |
|
118 |
SetSecundumForSubtreeOperation_CHANGE_SEC_OP=Change secundum reference for all children |
|
119 |
SetSecundumForSubtreeOperation_SET_SEC_TASK=Set secundum reference for subtree |
|
120 |
TaxonLinkHelper_CREATE_FAIL=Could not create Taxon |
|
121 |
TaxonNavigator_LOAD_DATASOURCE=Loading datasources |
|
122 |
TaxonNavigator_RESTORE=Restoring Taxon Navigator |
|
123 |
TaxonNavigator_SAVE_TASK=Saving Taxon Navigator State |
|
124 |
TaxonNavigator_TAXON_TREE=Taxonomic Tree |
|
125 |
TaxonNavigatorDataChangeBehavior_CLEAR_SESSION=Clearing Taxon Navigators session |
|
126 |
TaxonNavigatorDataChangeBehavior_REFRESH_VIEWER=Refreshing viewer |
|
127 |
TaxonNavigatorDataChangeBehavior_UPDATE_NAVIGATOR=Updating Taxon Navigator |
|
128 |
TaxonNavigatorLabels_CHANGE_ACC_TAXON=Change Accepted Taxon to Synonym |
|
129 |
TaxonNavigatorLabels_CLOSE_IMPOSSIBLE=Could not close related taxon name editor. Please close it manually and try again. |
|
130 |
TaxonNavigatorLabels_DELETE_TAXON=Delete Taxon Node |
|
131 |
TaxonNavigatorLabels_MOVE_FACTUAL_DATA=Move Factual Data |
|
132 |
TaxonNavigatorLabels_MOVE_TAXON=Move Taxon |
|
133 |
TaxonNavigatorLabels_NO_CHILDREN_ALLOWED=The chosen taxon must not have any childen. You need to move all childen to another taxon node in the TaxonNavigator before attempting to turn the accepted taxon into a synonym. |
|
134 |
TaxonNavigatorLabels_NOT_A_NODE=Selected object is not a taxon tree node |
|
135 |
TaxonNavigatorLabels_NOT_TAXON_SELECTED=No taxon tree node selected for operation. |
|
136 |
TaxonNavigatorLabels_ONLY_SINGLE_TAXON=The chosen operation is available only for a single taxon. |
|
137 |
TaxonNavigatorLabels_SET_SEC_FOR_CHILDREN=Set new Secundum Reference for all children. |
|
138 |
TaxonNavigatorLabels_UNSAVED_CHANGES=There are unsaved changes in the source taxon. Please save first. |
|
139 |
TaxonNodeLabelProvider_NO_TAXON=>NO TAXON< |
|
140 |
TaxonNodeLabelProvider_NODE_WITH_NO_TAXON=The taxon node does not have a taxon attached to it. Please check your import. TaxonNode: %s |
|
141 |
TaxonNodeLabelProvider_TAXON=Taxon: |
|
142 |
TreeNodeDropAdapter_10=\ |
|
143 |
TreeNodeDropAdapter_BEHIND=Behind |
|
144 |
TreeNodeDropAdapter_CANCEL=Cancel |
|
145 |
TreeNodeDropAdapter_CHILD=Child |
|
146 |
TreeNodeDropAdapter_MOVE_BEHIND=Do you want to move the Taxonnode as child or behind the target node. |
|
147 |
TreeNodeDropAdapter_MOVE_TAXON=Move Taxon |
|
148 |
TreeNodeDropAdapter_MOVING=Moving taxon |
|
149 |
TreeNodeDropAdapter_MOVING_MESSAGE=The operation move accepted taxon to other parent is available only for a single taxon. |
|
150 |
TreeNodeDropAdapter_TARGET_NODE=Target node |
|
151 |
TreeNodeDropAdapter_UNSAVED_PARENT=Unsaved Parent Taxon |
|
152 |
TreeNodeDropAdapter_UNSAVED_PARENT_MESSAGE=There are unsaved changes in the parent taxon. Pleas save first. |
|
153 |
|
eu.etaxonomy.taxeditor.navigation/src/main/java/eu/etaxonomy/taxeditor/navigation/navigator/ClassificationLabelProvider.java | ||
---|---|---|
18 | 18 |
import org.eclipse.ui.navigator.IDescriptionProvider; |
19 | 19 |
|
20 | 20 |
import eu.etaxonomy.cdm.model.taxon.Classification; |
21 |
import eu.etaxonomy.taxeditor.navigation.l10n.Messages; |
|
21 | 22 |
|
22 | 23 |
/** |
23 | 24 |
* <p>ClassificationLabelProvider class.</p> |
... | ... | |
48 | 49 |
public String getText(Object element) { |
49 | 50 |
if(element instanceof Classification){ |
50 | 51 |
String text = ((Classification) element).getName().getText(); |
51 |
return text != null ? text : "Unnamed Taxonomic Tree";
|
|
52 |
return text != null ? text : Messages.ClassificationLabelProvider_UNNAMED_TREE;
|
|
52 | 53 |
} |
53 | 54 |
return new String(); |
54 | 55 |
} |
eu.etaxonomy.taxeditor.navigation/src/main/java/eu/etaxonomy/taxeditor/navigation/navigator/Root.java | ||
---|---|---|
24 | 24 |
import eu.etaxonomy.cdm.model.taxon.Classification; |
25 | 25 |
import eu.etaxonomy.cdm.persistence.hibernate.CdmDataChangeMap; |
26 | 26 |
import eu.etaxonomy.taxeditor.navigation.NavigationUtil; |
27 |
import eu.etaxonomy.taxeditor.navigation.l10n.Messages; |
|
27 | 28 |
import eu.etaxonomy.taxeditor.navigation.operation.CreateClassification; |
28 | 29 |
import eu.etaxonomy.taxeditor.operation.AbstractPostOperation; |
29 | 30 |
import eu.etaxonomy.taxeditor.store.CdmStore; |
... | ... | |
55 | 56 |
*/ |
56 | 57 |
public List<Classification> getParentBeans() { |
57 | 58 |
List<String> propertyPaths = Arrays.asList(new String[]{ |
58 |
"name", |
|
59 |
"rootNode.childNodes"}); |
|
59 |
"name", //$NON-NLS-1$
|
|
60 |
"rootNode.childNodes"}); //$NON-NLS-1$
|
|
60 | 61 |
|
61 | 62 |
List<Classification> classifications = CdmStore.getService(IClassificationService.class).list(null, null, null, null, propertyPaths); |
62 | 63 |
|
63 | 64 |
if(classifications.size() == 0){ |
64 |
Classification classification = Classification.NewInstance("My Classification");
|
|
65 |
AbstractPostOperation operation = new CreateClassification("Creating initial classification", NavigationUtil.getUndoContext(), classification, NavigationUtil.getNavigator(false), NavigationUtil.getNavigator(false), NavigationUtil.getNavigator(false));
|
|
65 |
Classification classification = Classification.NewInstance(Messages.Root_MY_CLASSIFICATION);
|
|
66 |
AbstractPostOperation operation = new CreateClassification(Messages.Root_CREATE_CLASSIFICATION, NavigationUtil.getUndoContext(), classification, NavigationUtil.getNavigator(false), NavigationUtil.getNavigator(false), NavigationUtil.getNavigator(false));
|
|
66 | 67 |
NavigationUtil.executeOperation(operation); |
67 | 68 |
|
68 | 69 |
classifications = CdmStore.getService(IClassificationService.class).list(null, null, null, null, propertyPaths); |
eu.etaxonomy.taxeditor.navigation/src/main/java/eu/etaxonomy/taxeditor/navigation/navigator/SynonymLabelProvider.java | ||
---|---|---|
46 | 46 |
if (element instanceof Synonym && |
47 | 47 |
((Synonym) element).getName() != null) { |
48 | 48 |
|
49 |
return "= " + ((Synonym) element).getName().getTitleCache(); |
|
49 |
return "= " + ((Synonym) element).getName().getTitleCache(); //$NON-NLS-1$
|
|
50 | 50 |
} |
51 | 51 |
return new String(); |
52 | 52 |
} |
eu.etaxonomy.taxeditor.navigation/src/main/java/eu/etaxonomy/taxeditor/navigation/navigator/TaxonLinkHelper.java | ||
---|---|---|
18 | 18 |
import eu.etaxonomy.cdm.model.taxon.TaxonNode; |
19 | 19 |
import eu.etaxonomy.taxeditor.editor.TaxonEditorInput; |
20 | 20 |
import eu.etaxonomy.taxeditor.model.MessagingUtils; |
21 |
import eu.etaxonomy.taxeditor.navigation.l10n.Messages; |
|
21 | 22 |
|
22 | 23 |
/** |
23 | 24 |
* When a taxon is open in an editor and this editor has focus, its entry in the |
... | ... | |
55 | 56 |
// } |
56 | 57 |
// } |
57 | 58 |
} catch (Exception e) { |
58 |
MessagingUtils.warningDialog("Could not create Taxon", this, e.getMessage());
|
|
59 |
MessagingUtils.warningDialog(Messages.TaxonLinkHelper_CREATE_FAIL, this, e.getMessage());
|
|
59 | 60 |
} |
60 | 61 |
} |
61 | 62 |
|
eu.etaxonomy.taxeditor.navigation/src/main/java/eu/etaxonomy/taxeditor/navigation/navigator/TaxonNavigator.java | ||
---|---|---|
51 | 51 |
import eu.etaxonomy.taxeditor.model.IDataChangeBehavior; |
52 | 52 |
import eu.etaxonomy.taxeditor.model.MessagingUtils; |
53 | 53 |
import eu.etaxonomy.taxeditor.navigation.NavigationUtil; |
54 |
import eu.etaxonomy.taxeditor.navigation.l10n.Messages; |
|
54 | 55 |
import eu.etaxonomy.taxeditor.operation.IPostOperationEnabled; |
55 | 56 |
import eu.etaxonomy.taxeditor.preference.PreferencesUtil; |
56 | 57 |
import eu.etaxonomy.taxeditor.session.ICdmEntitySession; |
... | ... | |
64 | 65 |
* @author p.ciardelli |
65 | 66 |
* @author n.hoffmann |
66 | 67 |
* @created 02.06.2009 |
67 |
* @version 1.0 |
|
68 |
* @version 1.0+-
|
|
68 | 69 |
*/ |
69 | 70 |
public class TaxonNavigator extends CommonNavigator implements |
70 | 71 |
IPostOperationEnabled, IConversationEnabled, Observer, |
71 | 72 |
ICdmEntitySessionEnabled, ICdmChangeListener { |
72 | 73 |
|
73 |
/** |
|
74 |
private static final String RESTORING_TAXON_NAVIGATOR = Messages.TaxonNavigator_RESTORE; |
|
75 |
|
|
76 |
/** |
|
74 | 77 |
* Constant |
75 | 78 |
* <code>ID="eu.etaxonomy.taxeditor.navigation.navig"{trunked}</code> |
76 | 79 |
*/ |
77 | 80 |
public static final String ID = "eu.etaxonomy.taxeditor.navigation.navigator"; //$NON-NLS-1$ |
78 | 81 |
|
79 |
private static final String TREE_PATH = "treepath"; |
|
82 |
private static final String TREE_PATH = "treepath"; //$NON-NLS-1$
|
|
80 | 83 |
|
81 |
private static final String TREE_PATHS = "treepaths"; |
|
84 |
private static final String TREE_PATHS = "treepaths"; //$NON-NLS-1$
|
|
82 | 85 |
|
83 | 86 |
private ConversationHolder conversation; |
84 | 87 |
|
... | ... | |
226 | 229 |
IProgressMonitor subProgressMonitor = NavigationUtil |
227 | 230 |
.getSubProgressMonitor(monitor, 1); |
228 | 231 |
|
229 |
subProgressMonitor.beginTask("Restoring Taxon Navigator",
|
|
232 |
subProgressMonitor.beginTask(RESTORING_TAXON_NAVIGATOR,
|
|
230 | 233 |
1 + mementoWork + 5); |
231 |
subProgressMonitor.subTask("Restoring Taxon Navigator");
|
|
234 |
subProgressMonitor.subTask(RESTORING_TAXON_NAVIGATOR);
|
|
232 | 235 |
subProgressMonitor.worked(1); |
233 | 236 |
|
234 | 237 |
conversation = CdmStore.createConversation(); |
... | ... | |
270 | 273 |
return null; |
271 | 274 |
} |
272 | 275 |
|
273 |
for (String uuid : string.split(" ")) { |
|
276 |
for (String uuid : string.split(" ")) { //$NON-NLS-1$
|
|
274 | 277 |
CdmBase cdmBaseObject = CdmStore.getService( |
275 | 278 |
IClassificationService.class).getTaxonNodeByUuid( |
276 | 279 |
UUID.fromString(uuid)); |
... | ... | |
317 | 320 |
memento = memento.createChild(TREE_PATHS); |
318 | 321 |
TreePath[] treePaths = this.getCommonViewer().getExpandedTreePaths(); |
319 | 322 |
|
320 |
monitor.beginTask("Saving Taxon Navigator State", treePaths.length);
|
|
323 |
monitor.beginTask(Messages.TaxonNavigator_SAVE_TASK, treePaths.length);
|
|
321 | 324 |
|
322 | 325 |
for (TreePath treePath : treePaths) { |
323 | 326 |
int pathLength = treePath.getSegmentCount(); |
324 |
String path = ""; |
|
327 |
String path = ""; //$NON-NLS-1$
|
|
325 | 328 |
for (int i = 0; i < pathLength; i++) { |
326 | 329 |
Object segment = treePath.getSegment(i); |
327 | 330 |
if (segment instanceof CdmBase) { |
328 |
path += ((CdmBase) segment).getUuid().toString() + " "; |
|
331 |
path += ((CdmBase) segment).getUuid().toString() + " "; //$NON-NLS-1$
|
|
329 | 332 |
monitor.worked(1); |
330 | 333 |
} else { |
331 | 334 |
MessagingUtils.warn(getClass(), |
332 |
"Non-taxon tree path segment " + segment); |
|
335 |
"Non-taxon tree path segment " + segment); //$NON-NLS-1$
|
|
333 | 336 |
} |
334 | 337 |
} |
335 | 338 |
memento.createChild(TREE_PATH, path.trim()); |
... | ... | |
378 | 381 |
@Override |
379 | 382 |
public String getFrameToolTipText(Object element) { |
380 | 383 |
if (element instanceof Root) { |
381 |
return "Taxonomic Tree";
|
|
384 |
return Messages.TaxonNavigator_TAXON_TREE;
|
|
382 | 385 |
} |
383 | 386 |
return super.getFrameToolTipText(element); |
384 | 387 |
} |
... | ... | |
494 | 497 |
getCommonViewer().getControl().setEnabled(!busy); |
495 | 498 |
if (busy) { |
496 | 499 |
partNameCache = getPartName(); |
497 |
setPartName("Loading datasources");
|
|
500 |
setPartName(Messages.TaxonNavigator_LOAD_DATASOURCE);
|
|
498 | 501 |
} else { |
499 | 502 |
if (partNameCache != null) { |
500 | 503 |
setPartName(partNameCache); |
... | ... | |
564 | 567 |
public Map<Object, List<String>> getPropertyPathsMap() { |
565 | 568 |
Map<Object, List<String>> propertyPathsMap = new HashMap<Object, List<String>>(); |
566 | 569 |
List<String> taxonNodePropertyPaths = Arrays.asList(new String[] { |
567 |
"taxon.name" |
|
570 |
"taxon.name" //$NON-NLS-1$
|
|
568 | 571 |
}); |
569 |
propertyPathsMap.put("childNodes", taxonNodePropertyPaths); |
|
572 |
propertyPathsMap.put("childNodes", taxonNodePropertyPaths); //$NON-NLS-1$
|
|
570 | 573 |
return propertyPathsMap; |
571 | 574 |
} |
572 | 575 |
} |
eu.etaxonomy.taxeditor.navigation/src/main/java/eu/etaxonomy/taxeditor/navigation/navigator/TaxonNavigatorDataChangeBehavior.java | ||
---|---|---|
30 | 30 |
import eu.etaxonomy.taxeditor.model.AbstractDataChangeBehaviour; |
31 | 31 |
import eu.etaxonomy.taxeditor.model.IDataChangeBehavior; |
32 | 32 |
import eu.etaxonomy.taxeditor.navigation.NavigationUtil; |
33 |
import eu.etaxonomy.taxeditor.navigation.l10n.Messages; |
|
33 | 34 |
|
34 | 35 |
/** |
35 | 36 |
* <p>TaxonNavigatorDataChangeBehavior class.</p> |
... | ... | |
41 | 42 |
public class TaxonNavigatorDataChangeBehavior extends AbstractDataChangeBehaviour implements |
42 | 43 |
IDataChangeBehavior { |
43 | 44 |
|
44 |
private final TaxonNavigator source; |
|
45 |
private static final String UPDATING_TAXON_NAVIGATOR = Messages.TaxonNavigatorDataChangeBehavior_UPDATE_NAVIGATOR; |
|
46 |
|
|
47 |
private final TaxonNavigator source; |
|
45 | 48 |
|
46 | 49 |
private Set<CdmBase> staleObjects; |
47 | 50 |
|
... | ... | |
77 | 80 |
Set<CdmBase> affectedObjects = event.getAffectedObjects(); |
78 | 81 |
if(affectedObjects != null) { |
79 | 82 |
for(CdmBase cb : affectedObjects) { |
80 |
staleObjects.add((CdmBase)HibernateProxyHelper.deproxy(cb));
|
|
83 |
staleObjects.add(HibernateProxyHelper.deproxy(cb)); |
|
81 | 84 |
} |
82 | 85 |
} |
83 | 86 |
|
... | ... | |
164 | 167 |
if(isRelevant(events)){ |
165 | 168 |
|
166 | 169 |
final Display display = Display.getCurrent(); |
167 |
Job job = new Job("Updating Taxon Navigator") {
|
|
170 |
Job job = new Job(UPDATING_TAXON_NAVIGATOR) {
|
|
168 | 171 |
|
169 | 172 |
@Override |
170 | 173 |
protected IStatus run(IProgressMonitor monitor) { |
171 |
monitor.beginTask("Updating Taxon Navigator", 3);
|
|
174 |
monitor.beginTask(UPDATING_TAXON_NAVIGATOR, 3);
|
|
172 | 175 |
monitor.worked(1); |
173 | 176 |
|
174 | 177 |
// clear the session completely |
175 |
monitor.subTask("Clearing Taxon Navigators session");
|
|
178 |
monitor.subTask(Messages.TaxonNavigatorDataChangeBehavior_CLEAR_SESSION);
|
|
176 | 179 |
display.asyncExec(new Runnable() { |
177 | 180 |
@Override |
178 | 181 |
public void run() { |
... | ... | |
188 | 191 |
// seems to improve the situation but not sure if final solution |
189 | 192 |
monitor.worked(1); |
190 | 193 |
|
191 |
monitor.subTask("Refreshing viewer");
|
|
194 |
monitor.subTask(Messages.TaxonNavigatorDataChangeBehavior_REFRESH_VIEWER);
|
|
192 | 195 |
|
193 | 196 |
display.asyncExec(new Runnable() { |
194 | 197 |
@Override |
eu.etaxonomy.taxeditor.navigation/src/main/java/eu/etaxonomy/taxeditor/navigation/navigator/TaxonNavigatorLabels.java | ||
---|---|---|
8 | 8 |
*/ |
9 | 9 |
package eu.etaxonomy.taxeditor.navigation.navigator; |
10 | 10 |
|
11 |
import eu.etaxonomy.taxeditor.navigation.l10n.Messages; |
|
12 |
|
|
11 | 13 |
/** |
12 | 14 |
* @author cmathew |
13 | 15 |
* @date 19 Jun 2015 |
... | ... | |
15 | 17 |
*/ |
16 | 18 |
public interface TaxonNavigatorLabels { |
17 | 19 |
|
18 |
public static final String CHANGE_ACCEPTED_TAXON_TO_SYNONYM_LABEL = "Change Accepted Taxon to Synonym";
|
|
19 |
public static final String MOVE_TAXON_LABEL = "Move Taxon";
|
|
20 |
public static final String MOVE_FACTUAL_DATA_LABEL = "Move Factual Data";
|
|
21 |
public static final String DELETE_TAXON_NODE_LABEL = "Delete Taxon Node";
|
|
20 |
public static final String CHANGE_ACCEPTED_TAXON_TO_SYNONYM_LABEL = Messages.TaxonNavigatorLabels_CHANGE_ACC_TAXON;
|
|
21 |
public static final String MOVE_TAXON_LABEL = Messages.TaxonNavigatorLabels_MOVE_TAXON;
|
|
22 |
public static final String MOVE_FACTUAL_DATA_LABEL = Messages.TaxonNavigatorLabels_MOVE_FACTUAL_DATA;
|
|
23 |
public static final String DELETE_TAXON_NODE_LABEL = Messages.TaxonNavigatorLabels_DELETE_TAXON;
|
|
22 | 24 |
|
23 |
public static final String NO_TAXON_SELECTION_MESSAGE = "No taxon tree node selected for operation."; |
|
24 |
public static final String SINGLE_TAXON_SELECTION_MESSAGE = "The chosen operation is available only for a single taxon."; |
|
25 |
public static final String SOURCE_TAXON_HAS_CHILDREN_MESSAGE = "The chosen taxon must not have any childen. You need to move all childen to " + |
|
26 |
"another taxon node in the TaxonNavigator before attempting to turn the accepted " + |
|
27 |
"taxon into a synonym."; |
|
28 |
public static final String RELATED_EDITOR_NOT_CLOSED_MESSAGE = "Could not close related taxon name editor. " + |
|
29 |
"Please close it manually and try again."; |
|
30 |
public static final String SELECTED_OBJECT_NOT_TREE_NODE_MESSAGE = "Selected object is not a taxon tree node"; |
|
31 |
public static final String UNSAVED_CHANGES_MESSAGE = "There are unsaved changes in the source taxon. Please save first."; |
|
32 |
public static final String CHANGE_SECUNDUM_FOR_SUBTREE = "Set new Secundum Reference for all children."; |
|
25 |
public static final String NO_TAXON_SELECTION_MESSAGE = Messages.TaxonNavigatorLabels_NOT_TAXON_SELECTED; |
|
26 |
public static final String SINGLE_TAXON_SELECTION_MESSAGE = Messages.TaxonNavigatorLabels_ONLY_SINGLE_TAXON; |
|
27 |
public static final String SOURCE_TAXON_HAS_CHILDREN_MESSAGE = Messages.TaxonNavigatorLabels_NO_CHILDREN_ALLOWED; |
|
28 |
public static final String RELATED_EDITOR_NOT_CLOSED_MESSAGE = Messages.TaxonNavigatorLabels_CLOSE_IMPOSSIBLE; |
|
29 |
public static final String SELECTED_OBJECT_NOT_TREE_NODE_MESSAGE = Messages.TaxonNavigatorLabels_NOT_A_NODE; |
|
30 |
public static final String UNSAVED_CHANGES_MESSAGE = Messages.TaxonNavigatorLabels_UNSAVED_CHANGES; |
|
31 |
public static final String CHANGE_SECUNDUM_FOR_SUBTREE = Messages.TaxonNavigatorLabels_SET_SEC_FOR_CHILDREN; |
|
33 | 32 |
|
34 | 33 |
|
35 | 34 |
|
eu.etaxonomy.taxeditor.navigation/src/main/java/eu/etaxonomy/taxeditor/navigation/navigator/TaxonNodeLabelProvider.java | ||
---|---|---|
25 | 25 |
import eu.etaxonomy.cdm.model.taxon.Taxon; |
26 | 26 |
import eu.etaxonomy.cdm.model.taxon.TaxonNode; |
27 | 27 |
import eu.etaxonomy.taxeditor.model.MessagingUtils; |
28 |
import eu.etaxonomy.taxeditor.navigation.l10n.Messages; |
|
28 | 29 |
import eu.etaxonomy.taxeditor.preference.Resources; |
29 | 30 |
import eu.etaxonomy.taxeditor.security.RequiredPermissions; |
30 | 31 |
import eu.etaxonomy.taxeditor.store.CdmStore; |
... | ... | |
55 | 56 |
TaxonNode taxonNode = (TaxonNode) HibernateProxyHelper.deproxy(element); |
56 | 57 |
|
57 | 58 |
try{ |
58 |
Taxon taxon = (Taxon) HibernateProxyHelper.deproxy(taxonNode.getTaxon());
|
|
59 |
Taxon taxon = HibernateProxyHelper.deproxy(taxonNode.getTaxon()); |
|
59 | 60 |
if(taxon == null){ |
60 |
MessagingUtils.error(getClass(), "The taxon node does not have a taxon attached to it. Please check your import. TaxonNode: " + element, null);
|
|
61 |
MessagingUtils.error(getClass(), String.format(Messages.TaxonNodeLabelProvider_NODE_WITH_NO_TAXON, element), null);
|
|
61 | 62 |
// throw new RuntimeException("The data your are trying to view is corrupt. Please check your import."); |
62 | 63 |
}else{ |
63 | 64 |
try{ |
... | ... | |
79 | 80 |
public String getDescription(Object anElement) { |
80 | 81 |
if (anElement instanceof TaxonNode) { |
81 | 82 |
Taxon data = ((TaxonNode) anElement).getTaxon(); |
82 |
return "Taxon: " + (data != null ? data.getTitleCache() : ">NO TAXON<");
|
|
83 |
return Messages.TaxonNodeLabelProvider_TAXON + (data != null ? data.getTitleCache() : Messages.TaxonNodeLabelProvider_NO_TAXON);
|
|
83 | 84 |
} |
84 | 85 |
return null; |
85 | 86 |
} |
eu.etaxonomy.taxeditor.navigation/src/main/java/eu/etaxonomy/taxeditor/navigation/navigator/TaxonNodePropertyTester.java | ||
---|---|---|
14 | 14 |
import eu.etaxonomy.cdm.model.taxon.TaxonNode; |
15 | 15 |
public class TaxonNodePropertyTester extends PropertyTester { |
16 | 16 |
|
17 |
private static final Object HAS_SYNONYMS = "hasSynonyms"; |
|
18 |
private static final Object HAS_TAXA = "hasTaxa"; |
|
17 |
private static final Object HAS_SYNONYMS = "hasSynonyms"; //$NON-NLS-1$
|
|
18 |
private static final Object HAS_TAXA = "hasTaxa"; //$NON-NLS-1$
|
|
19 | 19 |
|
20 | 20 |
/** {@inheritDoc} */ |
21 | 21 |
public boolean test(Object receiver, String property, Object[] args, |
eu.etaxonomy.taxeditor.navigation/src/main/java/eu/etaxonomy/taxeditor/navigation/navigator/TreeNodeDropAdapter.java | ||
---|---|---|
33 | 33 |
import eu.etaxonomy.cdm.model.taxon.TaxonNode; |
34 | 34 |
import eu.etaxonomy.cdm.persistence.hibernate.permission.CRUD; |
35 | 35 |
import eu.etaxonomy.taxeditor.navigation.NavigationUtil; |
36 |
import eu.etaxonomy.taxeditor.navigation.l10n.Messages; |
|
36 | 37 |
import eu.etaxonomy.taxeditor.navigation.navigator.operation.MoveTaxonOperation; |
37 | 38 |
import eu.etaxonomy.taxeditor.operation.AbstractPostOperation; |
38 | 39 |
import eu.etaxonomy.taxeditor.operation.IPostOperationEnabled; |
... | ... | |
47 | 48 |
*/ |
48 | 49 |
public class TreeNodeDropAdapter extends ViewerDropAdapter implements IPostOperationEnabled { |
49 | 50 |
|
50 |
private static final Logger logger = Logger.getLogger(TreeNodeDropAdapter.class); |
|
51 |
protected static final String TREE_NODE_DROP_ADAPTER_UNSAVED_PARENT_MESSAGE = Messages.TreeNodeDropAdapter_UNSAVED_PARENT_MESSAGE; |
|
52 |
protected static final String TREE_NODE_DROP_ADAPTER_UNSAVED_PARENT = Messages.TreeNodeDropAdapter_UNSAVED_PARENT; |
|
53 |
protected static final String TREE_NODE_DROP_ADAPTER_MOVE_TAXON = Messages.TreeNodeDropAdapter_MOVE_TAXON; |
|
54 |
protected static final String TREE_NODE_DROP_ADAPTER_CANCEL = Messages.TreeNodeDropAdapter_CANCEL; |
|
55 |
protected static final String TREE_NODE_DROP_ADAPTER_BEHIND = Messages.TreeNodeDropAdapter_BEHIND; |
|
56 |
protected static final String TREE_NODE_DROP_ADAPTER_CHILD = Messages.TreeNodeDropAdapter_CHILD; |
|
57 |
protected static final String DO_YOU_WANT_TO_MOVE_THE_TAXONNODE_AS_CHILD_OR_BEHIND_THE_TARGET_NODE = Messages.TreeNodeDropAdapter_MOVE_BEHIND; |
|
58 |
protected static final String TARGET_NODE = Messages.TreeNodeDropAdapter_TARGET_NODE; |
|
59 |
|
|
60 |
private static final Logger logger = Logger.getLogger(TreeNodeDropAdapter.class); |
|
51 | 61 |
|
52 | 62 |
private final TaxonNavigatorViewer navigatorViewer; |
53 |
|
|
63 |
|
|
54 | 64 |
/** |
55 | 65 |
* @param viewer |
56 | 66 |
*/ |
Also available in: Unified diff
ref #4611 i18n for taxeditor.navigator plugin