Project

General

Profile

Download (837 Bytes) Statistics
| Branch: | Tag: | Revision:
1
package eu.etaxonomy.taxeditor.editor.handler;
2

    
3
import org.eclipse.core.commands.AbstractHandler;
4
import org.eclipse.core.commands.ExecutionEvent;
5
import org.eclipse.core.commands.ExecutionException;
6
import org.eclipse.ui.PartInitException;
7

    
8
import eu.etaxonomy.taxeditor.editor.EditorUtil;
9
import eu.etaxonomy.taxeditor.editor.view.derivate.DerivateViewEditorInput;
10
import eu.etaxonomy.taxeditor.model.MessagingUtils;
11

    
12
public class OpenDerivateViewHandler extends AbstractHandler {
13

    
14
    @Override
15
    public Object execute(ExecutionEvent event) throws ExecutionException {
16
        try {
17
            EditorUtil.open(new DerivateViewEditorInput());
18
        } catch (PartInitException e) {
19
            MessagingUtils.error(OpenDerivateViewHandler.class, "Derivative Editor could not be opened", e);
20
        }
21
        return null;
22
    }
23

    
24
}
(3-3/7)