Revision 9a512b18
Added by Patrick Plitzner about 7 years ago
eu.etaxonomy.taxeditor.bulkeditor/src/main/java/eu/etaxonomy/taxeditor/bulkeditor/command/BulkEditorSelectionPropertyTester.java | ||
---|---|---|
2 | 2 |
|
3 | 3 |
import org.eclipse.core.expressions.PropertyTester; |
4 | 4 |
import org.eclipse.jface.viewers.IStructuredSelection; |
5 |
import org.eclipse.jface.viewers.TreeNode; |
|
5 | 6 |
|
6 | 7 |
import eu.etaxonomy.cdm.persistence.dto.UuidAndTitleCache; |
7 | 8 |
import eu.etaxonomy.taxeditor.bulkeditor.input.BulkEditorInputType; |
... | ... | |
20 | 21 |
if(selectedElement!=null){ |
21 | 22 |
if(selectedElement instanceof UuidAndTitleCache){ |
22 | 23 |
return BulkEditorInputType.getByType(((UuidAndTitleCache) selectedElement).getType())!=null; |
24 |
} |
|
25 |
else if(selectedElement instanceof TreeNode){ |
|
26 |
System.out.println(BulkEditorInputType.getByType(((TreeNode) selectedElement).getValue().getClass())!=null); |
|
27 |
return BulkEditorInputType.getByType(((TreeNode) selectedElement).getValue().getClass())!=null; |
|
23 | 28 |
} |
24 | 29 |
return BulkEditorInputType.getByType(selectedElement.getClass())!=null; |
25 | 30 |
} |
Also available in: Unified diff
ref #5923 "Open in.." menu restructuring