|
From: Dan C. <cor...@us...> - 2010-01-17 16:33:26
|
Update of /cvsroot/jcommander/plugins/org.jcommander.ui.app/src/org/jcommander/ui/app In directory sfp-cvsdas-3.v30.ch3.sourceforge.com:/tmp/cvs-serv30451/src/org/jcommander/ui/app Modified Files: PlatformRunnable.java Log Message: IPlatformRunnable is deprecated and was replaced by IApplication. For SWTBot to be able to find our plugin, we must make it implement IApplication. See ID: 2932702 Index: PlatformRunnable.java =================================================================== RCS file: /cvsroot/jcommander/plugins/org.jcommander.ui.app/src/org/jcommander/ui/app/PlatformRunnable.java,v retrieving revision 1.11 retrieving revision 1.12 diff -C2 -d -r1.11 -r1.12 *** PlatformRunnable.java 6 Aug 2006 10:32:17 -0000 1.11 --- PlatformRunnable.java 17 Jan 2010 16:33:18 -0000 1.12 *************** *** 4,13 **** package org.jcommander.ui.app; ! import org.eclipse.core.runtime.*; ! import org.eclipse.osgi.service.datalocation.*; ! import org.eclipse.swt.widgets.*; ! import org.eclipse.ui.*; ! import org.jcommander.ui.app.singleton.*; ! import org.jcommander.ui.logger.*; /** --- 4,16 ---- package org.jcommander.ui.app; ! import org.eclipse.core.runtime.Platform; ! import org.eclipse.equinox.app.IApplication; ! import org.eclipse.equinox.app.IApplicationContext; ! import org.eclipse.osgi.service.datalocation.Location; ! import org.eclipse.swt.widgets.Display; ! import org.eclipse.ui.PlatformUI; ! import org.jcommander.ui.app.singleton.ApplicationEntryPoint; ! import org.jcommander.ui.app.singleton.SingletonAppLauncher; ! import org.jcommander.ui.logger.LoggerPlugin; /** *************** *** 16,20 **** * @author sky_halud */ ! public class PlatformRunnable implements IPlatformRunnable { // TODO Implement support for command line parameters --- 19,23 ---- * @author sky_halud */ ! public class PlatformRunnable implements IApplication { // TODO Implement support for command line parameters *************** *** 25,30 **** * those running stand-alone. */ ! public Object run(Object args) throws Exception { String[] strArgs = null; if(args instanceof String[]){ strArgs = (String[])args; --- 28,34 ---- * those running stand-alone. */ ! public Object start(IApplicationContext context) throws Exception { String[] strArgs = null; + Object args = context.getArguments().get(IApplicationContext.APPLICATION_ARGS); if(args instanceof String[]){ strArgs = (String[])args; *************** *** 48,52 **** if(!first){ LoggerPlugin.rootLogger.info("Exitting from duplicate instance"); ! return IPlatformRunnable.EXIT_OK; } } --- 52,56 ---- if(!first){ LoggerPlugin.rootLogger.info("Exitting from duplicate instance"); ! return IApplication.EXIT_OK; } } *************** *** 54,60 **** if(returnCode == PlatformUI.RETURN_RESTART){ ! return IPlatformRunnable.EXIT_RESTART; }else{ ! return IPlatformRunnable.EXIT_OK; } } --- 58,64 ---- if(returnCode == PlatformUI.RETURN_RESTART){ ! return IApplication.EXIT_RESTART; }else{ ! return IApplication.EXIT_OK; } } *************** *** 111,114 **** --- 115,123 ---- } } + + public void stop() { + // TODO Auto-generated method stub + + } } |