Moved all logging and dialog functionality to the new class MessagingUtils.
[taxeditor.git] / eu.etaxonomy.taxeditor.application / src / main / java / eu / etaxonomy / taxeditor / ApplicationWorkbenchWindowAdvisor.java
index f7bcbe89b597117612798eaea02baa0686b51b28..00a48ec537aca90ef3a80f95112033c888ed91ee 100644 (file)
@@ -13,6 +13,7 @@ import org.eclipse.ui.application.IWorkbenchWindowConfigurer;
 import org.eclipse.ui.application.WorkbenchWindowAdvisor;
 import org.osgi.framework.ServiceReference;
 
+import eu.etaxonomy.taxeditor.model.MessagingUtils;
 import eu.etaxonomy.taxeditor.preference.PreferencesUtil;
 import eu.etaxonomy.taxeditor.store.CdmStore;
 import eu.etaxonomy.taxeditor.ui.dialog.LoginDialog;
@@ -84,15 +85,15 @@ public class ApplicationWorkbenchWindowAdvisor extends WorkbenchWindowAdvisor {
                try {
                        agent = agentProvider.createAgent(null);//new URI("file:/Applications/eclipse36/p2"));
                        if (agent == null) {
-                               ApplicationUtil.error(this.getClass(), "No provisioning agent found. This application is not set up for updates.", null);
+                               MessagingUtils.error(this.getClass(), "No provisioning agent found. This application is not set up for updates.", null);
                                return;
                        }
 
                        IStatus status = P2Util.checkForUpdates(agent, null);
 
-                       ApplicationUtil.info(status);
+                       MessagingUtils.info(status);
                } catch (ProvisionException e) {
-                       ApplicationUtil.error(getClass(), e);
+                       MessagingUtils.error(getClass(), e);
                } finally {
                        if(agent != null) agent.stop();
                }