Go to the documentation of this file.00001 package com.generalrobotix.ui.grxui;
00002
00003 import org.eclipse.core.runtime.IPlatformRunnable;
00004 import org.eclipse.swt.widgets.Display;
00005 import org.eclipse.ui.PlatformUI;
00006
00007 public class Application implements IPlatformRunnable {
00008
00009 public Object run(Object args) throws Exception {
00010 Display display = PlatformUI.createDisplay();
00011 try {
00012 int returnCode = PlatformUI.createAndRunWorkbench(display, new ApplicationWorkbenchAdvisor());
00013 if (returnCode == PlatformUI.RETURN_RESTART) {
00014 return IPlatformRunnable.EXIT_RESTART;
00015 }
00016 return IPlatformRunnable.EXIT_OK;
00017 } finally {
00018 display.dispose();
00019 }
00020 }
00021
00022 }