Moved all logging and dialog functionality to the new class MessagingUtils.
[taxeditor.git] / eu.etaxonomy.taxeditor.editor / src / main / java / eu / etaxonomy / taxeditor / editor / handler / OpenChecklistEditorHandler.java
index 5ffa7eec0f51e80391eb9fc406847928ddc85729..cc2bbf04772df20c8212f1eb3fe2287dca68d3ad 100644 (file)
@@ -14,6 +14,7 @@ import eu.etaxonomy.cdm.model.taxon.TaxonNode;
 import eu.etaxonomy.taxeditor.editor.EditorUtil;
 import eu.etaxonomy.taxeditor.editor.view.checklist.ChecklistEditorInput;
 import eu.etaxonomy.taxeditor.model.AbstractUtility;
+import eu.etaxonomy.taxeditor.model.MessagingUtils;
 import eu.etaxonomy.taxeditor.preference.IPreferenceKeys;
 import eu.etaxonomy.taxeditor.preference.PreferencesUtil;
 
@@ -41,9 +42,9 @@ public class OpenChecklistEditorHandler extends AbstractHandler {
                     try {
                         EditorUtil.open(input);
                     } catch (PartInitException e) {
-                        AbstractUtility.error(OpenChecklistEditorHandler.class, "Could not open ChecklistView", e);
+                       MessagingUtils.error(OpenChecklistEditorHandler.class, "Could not open ChecklistView", e);
                     } catch (NullPointerException npe) {
-                        AbstractUtility.errorDialog("Failed to open Editor", OpenChecklistEditorHandler.class,
+                       MessagingUtils.messageDialog("Failed to open Editor", OpenChecklistEditorHandler.class,
                                 "Could not open ChecklistView. The hierarchy is corrupted!", npe);
                     }
                 } else if (selectedElement instanceof TaxonNode) {
@@ -51,9 +52,9 @@ public class OpenChecklistEditorHandler extends AbstractHandler {
                     try {
                         EditorUtil.open(input);
                     } catch (PartInitException e) {
-                        AbstractUtility.error(OpenChecklistEditorHandler.class, "Could not open ChecklistView", e);
+                       MessagingUtils.error(OpenChecklistEditorHandler.class, "Could not open ChecklistView", e);
                     } catch (NullPointerException npe) {
-                        AbstractUtility.errorDialog("Failed to open Editor", OpenChecklistEditorHandler.class,
+                       MessagingUtils.messageDialog("Failed to open Editor", OpenChecklistEditorHandler.class,
                                 "Could not open ChecklistView. The hierarchy is corrupted!", npe);
                     }
                 }