ref #7321 fix NPE in PolytomousKeyListLabelProvider
[taxeditor.git] / eu.etaxonomy.taxeditor.editor / src / main / java / eu / etaxonomy / taxeditor / editor / key / e4 / handler / ApplyLayoutHandlerE4.java
1 /**
2 *
3 */
4 package eu.etaxonomy.taxeditor.editor.key.e4.handler;
5
6 import javax.inject.Named;
7
8 import org.eclipse.e4.core.di.annotations.Execute;
9 import org.eclipse.e4.ui.model.application.ui.basic.MPart;
10 import org.eclipse.e4.ui.services.IServiceConstants;
11
12 import eu.etaxonomy.taxeditor.editor.key.e4.AbstractGraphKeyEditorE4;
13
14 /**
15 * @author n.hoffmann
16 *
17 */
18 public class ApplyLayoutHandlerE4 {
19
20 @Execute
21 public void execute(@Named(IServiceConstants.ACTIVE_PART)MPart activePart) {
22 AbstractGraphKeyEditorE4 graphKeyEditorE4 = (AbstractGraphKeyEditorE4) activePart.getObject();
23 graphKeyEditorE4.applyLayout();
24 }
25
26 }