[jboss-cvs] jbosside/core/plugins/org.jboss.ide.eclipse.packages.ui/src/main/org/jboss/ide/eclipse/packages/ui/actions ...
Marshall Culpepper
mculpepper at jboss.com
Mon Nov 6 16:36:50 EST 2006
User: mculpepper
Date: 06/11/06 16:36:50
Added: core/plugins/org.jboss.ide.eclipse.packages.ui/src/main/org/jboss/ide/eclipse/packages/ui/actions
NewSARAction.java BuildPackagesAction.java
NewJARAction.java NewEJBJARAction.java
NewWARAction.java NewEARAction.java
Log:
initial commit of the new "packages" tooling ui plugin
Revision Changes Path
1.1 date: 2006/11/06 21:36:50; author: mculpepper; state: Exp;jbosside/core/plugins/org.jboss.ide.eclipse.packages.ui/src/main/org/jboss/ide/eclipse/packages/ui/actions/NewSARAction.java
Index: NewSARAction.java
===================================================================
package org.jboss.ide.eclipse.packages.ui.actions;
import org.jboss.ide.eclipse.ui.util.ActionWithDelegate;
public class NewSARAction extends ActionWithDelegate {
public NewSARAction() {
// TODO Auto-generated constructor stub
}
public void run() {
// TODO Auto-generated method stub
}
}
1.1 date: 2006/11/06 21:36:50; author: mculpepper; state: Exp;jbosside/core/plugins/org.jboss.ide.eclipse.packages.ui/src/main/org/jboss/ide/eclipse/packages/ui/actions/BuildPackagesAction.java
Index: BuildPackagesAction.java
===================================================================
/*
* JBoss, a division of Red Hat
* Copyright 2006, Red Hat Middleware, LLC, and individual contributors as indicated
* by the @authors tag. See the copyright.txt in the distribution for a
* full listing of individual contributors.
*
* This is free software; you can redistribute it and/or modify it
* under the terms of the GNU Lesser General Public License as
* published by the Free Software Foundation; either version 2.1 of
* the License, or (at your option) any later version.
*
* This software is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public
* License along with this software; if not, write to the Free
* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
*/
package org.jboss.ide.eclipse.packages.ui.actions;
import org.eclipse.core.resources.IProject;
import org.eclipse.core.runtime.IProgressMonitor;
import org.eclipse.jface.dialogs.ProgressMonitorDialog;
import org.eclipse.ui.IWorkbenchWindow;
import org.eclipse.ui.IWorkbenchWindowActionDelegate;
import org.jboss.ide.eclipse.core.util.ProjectUtil;
import org.jboss.ide.eclipse.packages.core.model.IPackage;
import org.jboss.ide.eclipse.packages.core.model.PackagesCore;
import org.jboss.ide.eclipse.ui.util.ActionWithDelegate;
public class BuildPackagesAction extends ActionWithDelegate implements IWorkbenchWindowActionDelegate {
private IWorkbenchWindow window;
public void dispose() {
}
public void run() {
if (getSelection() != null)
{
IProject project = ProjectUtil.getProject(getSelection());
if (project != null)
{
ProgressMonitorDialog dialog = new ProgressMonitorDialog(window.getShell());
IProgressMonitor monitor = dialog.getProgressMonitor();
//dialog.setBlockOnOpen(false);
dialog.open();
IPackage[] packages = PackagesCore.getProjectPackages(project, monitor);
for (int i = 0; i < packages.length; i++)
{
PackagesCore.buildPackage(packages[i], monitor);
}
dialog.close();
}
}
}
public void init(IWorkbenchWindow window) {
this.window = window;
}
}
1.1 date: 2006/11/06 21:36:50; author: mculpepper; state: Exp;jbosside/core/plugins/org.jboss.ide.eclipse.packages.ui/src/main/org/jboss/ide/eclipse/packages/ui/actions/NewJARAction.java
Index: NewJARAction.java
===================================================================
package org.jboss.ide.eclipse.packages.ui.actions;
import org.eclipse.jface.dialogs.Dialog;
import org.eclipse.jface.resource.ImageDescriptor;
import org.eclipse.jface.wizard.WizardDialog;
import org.eclipse.ui.PlatformUI;
import org.jboss.ide.eclipse.packages.ui.PackagesUIPlugin;
import org.jboss.ide.eclipse.packages.ui.wizards.NewJARWizard;
import org.jboss.ide.eclipse.ui.util.ActionWithDelegate;
public class NewJARAction extends ActionWithDelegate
{
public void run() {
NewJARWizard wizard = new NewJARWizard();
wizard.init(PlatformUI.getWorkbench(), getSelection());
WizardDialog dialog = new WizardDialog(PlatformUI.getWorkbench().getActiveWorkbenchWindow().getShell(), wizard);
int response = dialog.open();
if (response == Dialog.OK)
{
}
}
public ImageDescriptor getImageDescriptor() {
return PackagesUIPlugin.getImageDescriptor(PackagesUIPlugin.IMG_NEW_PACKAGE);
}
public String getText() {
return "JAR";
}
public String getToolTipText() {
return "Create a new JAR package";
}
}
1.1 date: 2006/11/06 21:36:50; author: mculpepper; state: Exp;jbosside/core/plugins/org.jboss.ide.eclipse.packages.ui/src/main/org/jboss/ide/eclipse/packages/ui/actions/NewEJBJARAction.java
Index: NewEJBJARAction.java
===================================================================
package org.jboss.ide.eclipse.packages.ui.actions;
import org.jboss.ide.eclipse.ui.util.ActionWithDelegate;
public class NewEJBJARAction extends ActionWithDelegate {
public NewEJBJARAction() {
// TODO Auto-generated constructor stub
}
public void run() {
// TODO Auto-generated method stub
}
}
1.1 date: 2006/11/06 21:36:50; author: mculpepper; state: Exp;jbosside/core/plugins/org.jboss.ide.eclipse.packages.ui/src/main/org/jboss/ide/eclipse/packages/ui/actions/NewWARAction.java
Index: NewWARAction.java
===================================================================
package org.jboss.ide.eclipse.packages.ui.actions;
import org.eclipse.jface.dialogs.Dialog;
import org.eclipse.jface.resource.ImageDescriptor;
import org.eclipse.jface.wizard.WizardDialog;
import org.eclipse.ui.IViewActionDelegate;
import org.eclipse.ui.IViewPart;
import org.eclipse.ui.PlatformUI;
import org.jboss.ide.eclipse.packages.ui.PackagesUIPlugin;
import org.jboss.ide.eclipse.packages.ui.wizards.NewWARWizard;
import org.jboss.ide.eclipse.ui.util.ActionWithDelegate;
public class NewWARAction extends ActionWithDelegate implements IViewActionDelegate {
public void run() {
NewWARWizard wizard = new NewWARWizard();
wizard.init(PlatformUI.getWorkbench(), getSelection());
WizardDialog dialog = new WizardDialog(PlatformUI.getWorkbench().getActiveWorkbenchWindow().getShell(), wizard);
int response = dialog.open();
if (response == Dialog.OK)
{
}
}
public ImageDescriptor getImageDescriptor() {
return PackagesUIPlugin.getImageDescriptor(PackagesUIPlugin.IMG_WAR);
}
public String getText() {
return "WAR";
}
public String getToolTipText() {
return "Create a new WAR package";
}
public void init(IViewPart view) {
}
}
1.1 date: 2006/11/06 21:36:50; author: mculpepper; state: Exp;jbosside/core/plugins/org.jboss.ide.eclipse.packages.ui/src/main/org/jboss/ide/eclipse/packages/ui/actions/NewEARAction.java
Index: NewEARAction.java
===================================================================
package org.jboss.ide.eclipse.packages.ui.actions;
import org.jboss.ide.eclipse.ui.util.ActionWithDelegate;
public class NewEARAction extends ActionWithDelegate {
public NewEARAction() {
// TODO Auto-generated constructor stub
}
public void run() {
// TODO Auto-generated method stub
}
}
More information about the jboss-cvs-commits
mailing list