FileDocCategorySizeDatePackage
NewAction.javaAPI DocExample1291Fri Dec 05 15:26:24 GMT 2003org.eclipsebook.ch11.Ch11_02

NewAction.java

package org.eclipsebook.ch11.Ch11_02;

import org.eclipse.jface.action.IAction;
import org.eclipse.jface.dialogs.MessageDialog;
import org.eclipse.jface.viewers.ISelection;
import org.eclipse.ui.IWorkbenchWindow;
import org.eclipse.ui.IWorkbenchWindowActionDelegate;

/**
 * TODO: Provide description for "NewAction".
 * @see IWorkbenchWindowActionDelegate
 */
public class NewAction implements IWorkbenchWindowActionDelegate {
	private IWorkbenchWindow workbenchWindow;
	/**
	 * TODO: Implement the "NewAction" constructor.
	 */
	public NewAction() {
	}

	/**
	 * TODO: Implement "run".
	 * @see IWorkbenchWindowActionDelegate#run
	 */
	public void run(IAction action)  {
		MessageDialog.openInformation(
		workbenchWindow.getShell(),
		"New Plug-in",
		"No worries.");
	}

	/**
	 * TODO: Implement "selectionChanged".
	 * @see IWorkbenchWindowActionDelegate#selectionChanged
	 */
	public void selectionChanged(IAction action, ISelection selection)  {
	}

	/**
	 * TODO: Implement "dispose".
	 * @see IWorkbenchWindowActionDelegate#dispose
	 */
	public void dispose()  {
	}

	/**
	 * TODO: Implement "init".
	 * @see IWorkbenchWindowActionDelegate#init
	 */
	public void init(IWorkbenchWindow window)  {
		workbenchWindow = window;
	}
}