application.java
来自「个人珍藏」· Java 代码 · 共 38 行
JAVA
38 行
package cn.edu.jfcs.app;import org.eclipse.core.runtime.IPlatformRunnable;import org.eclipse.core.runtime.Platform;import org.eclipse.swt.widgets.Display;import org.eclipse.ui.PlatformUI;import cn.edu.jfcs.sys.Login;/** * This class controls all aspects of the application's execution */public class Application implements IPlatformRunnable { /* * (non-Javadoc) * * @see org.eclipse.core.runtime.IPlatformRunnable#run(java.lang.Object) */ public Object run(Object args) throws Exception { Display display = PlatformUI.createDisplay(); try { Platform.endSplash(); Login login = new Login(); if (!login.isLogin()) { return IPlatformRunnable.EXIT_OK; } int returnCode = PlatformUI.createAndRunWorkbench(display, new ApplicationWorkbenchAdvisor()); if (returnCode == PlatformUI.RETURN_RESTART) { return IPlatformRunnable.EXIT_RESTART; } return IPlatformRunnable.EXIT_OK; } finally { display.dispose(); } }}
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?