1 package com.bull.eclipse.jonas.actions; 2 3 7 8 import org.eclipse.jface.action.IAction; 9 import org.eclipse.jface.viewers.ISelection; 10 import org.eclipse.ui.IWorkbenchWindow; 11 import org.eclipse.ui.IWorkbenchWindowActionDelegate; 12 13 import com.bull.eclipse.jonas.JonasLauncherPlugin; 14 15 public class StopActionDelegate implements IWorkbenchWindowActionDelegate { 16 private IWorkbenchWindow window; 17 18 21 public void dispose() { 22 } 23 24 27 public void init(IWorkbenchWindow window) { 28 this.window = window; 29 } 30 31 34 public void run(IAction action) { 35 JonasLauncherPlugin.log(JonasLauncherPlugin.getResourceString("msg.stop")); 36 37 try { 38 JonasLauncherPlugin.getDefault().getJonasBootstrap().stop(); 39 } catch (Exception ex) { 40 String msg = JonasLauncherPlugin.getResourceString("msg.stop.failed"); 41 JonasLauncherPlugin.log(msg + "/n"); 42 JonasLauncherPlugin.log(ex); 43 } 44 } 45 46 49 public void selectionChanged(IAction action, ISelection selection) { 50 } 51 52 } 53 54 | Popular Tags |