JBoss Tools SVN: r38246 - in trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui: propertytable and 2 other directories.
by jbosstools-commits@lists.jboss.org
Author: adietish
Date: 2012-01-27 13:16:53 -0500 (Fri, 27 Jan 2012)
New Revision: 38246
Added:
trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/propertytable/
trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/propertytable/AbstractPropertyCellLabelProvider.java
trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/propertytable/AbstractPropertyTableContentProvider.java
trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/propertytable/ContainerElement.java
trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/propertytable/IProperty.java
trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/propertytable/LinkElement.java
trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/propertytable/PropertyNameCellLabelProvider.java
trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/propertytable/PropertyValueCellLabelProvider.java
trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/propertytable/StringElement.java
trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/utils/TreeUtils.java
Modified:
trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/wizard/ApplicationDetailsContentProvider.java
trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/wizard/ApplicationDetailsDialog.java
Log:
[JBIDE-10724] extracted property table to its own packge (for later reuse). Used TreeEditor to put a link on top of the url to be able to handle clicks on the web url
Added: trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/propertytable/AbstractPropertyCellLabelProvider.java
===================================================================
--- trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/propertytable/AbstractPropertyCellLabelProvider.java (rev 0)
+++ trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/propertytable/AbstractPropertyCellLabelProvider.java 2012-01-27 18:16:53 UTC (rev 38246)
@@ -0,0 +1,30 @@
+/*******************************************************************************
+ * Copyright (c) 2011 Red Hat, Inc.
+ * Distributed under license by Red Hat, Inc. All rights reserved.
+ * This program is made available under the terms of the
+ * Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * Red Hat, Inc. - initial API and implementation
+ ******************************************************************************/
+package org.jboss.tools.openshift.express.internal.ui.propertytable;
+
+import org.eclipse.jface.viewers.CellLabelProvider;
+import org.eclipse.jface.viewers.ViewerCell;
+
+/**
+ * @author Xavier Coulon
+ * @author Andre Dietisheim
+ */
+public abstract class AbstractPropertyCellLabelProvider extends CellLabelProvider {
+
+ @Override
+ public void update(ViewerCell cell) {
+ if (cell.getElement() instanceof IProperty) {
+ update((IProperty) cell.getElement(), cell);
+ }
+ }
+
+ abstract protected void update(IProperty property, ViewerCell cell);
+}
Property changes on: trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/propertytable/AbstractPropertyCellLabelProvider.java
___________________________________________________________________
Added: svn:mime-type
+ text/plain
Added: trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/propertytable/AbstractPropertyTableContentProvider.java
===================================================================
--- trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/propertytable/AbstractPropertyTableContentProvider.java (rev 0)
+++ trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/propertytable/AbstractPropertyTableContentProvider.java 2012-01-27 18:16:53 UTC (rev 38246)
@@ -0,0 +1,48 @@
+/**
+ *
+ */
+package org.jboss.tools.openshift.express.internal.ui.propertytable;
+
+import org.eclipse.jface.viewers.ITreeContentProvider;
+import org.eclipse.jface.viewers.Viewer;
+
+/**
+ * @author Xavier Coulon
+ * @author Andre Dietisheim
+ *
+ */
+public abstract class AbstractPropertyTableContentProvider implements ITreeContentProvider {
+
+ @Override
+ public abstract Object[] getElements(Object inputElement);
+
+ @Override
+ public Object[] getChildren(Object parentElement) {
+ if (!hasChildren(parentElement)) {
+ return new Object[0];
+ }
+ return ((IProperty) parentElement).getChildren();
+ }
+
+ @Override
+ public Object getParent(Object element) {
+ if (element instanceof IProperty) {
+ return ((IProperty) element).getParent();
+ }
+ return null;
+ }
+
+ @Override
+ public boolean hasChildren(Object element) {
+ return element instanceof IProperty
+ && ((IProperty) element).hasChildren();
+ }
+
+ @Override
+ public void dispose() {
+ }
+
+ @Override
+ public void inputChanged(Viewer viewer, Object oldInput, Object newInput) {
+ }
+}
Property changes on: trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/propertytable/AbstractPropertyTableContentProvider.java
___________________________________________________________________
Added: svn:mime-type
+ text/plain
Added: trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/propertytable/ContainerElement.java
===================================================================
--- trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/propertytable/ContainerElement.java (rev 0)
+++ trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/propertytable/ContainerElement.java 2012-01-27 18:16:53 UTC (rev 38246)
@@ -0,0 +1,65 @@
+/*******************************************************************************
+ * Copyright (c) 2011 Red Hat, Inc.
+ * Distributed under license by Red Hat, Inc. All rights reserved.
+ * This program is made available under the terms of the
+ * Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * Red Hat, Inc. - initial API and implementation
+ ******************************************************************************/
+package org.jboss.tools.openshift.express.internal.ui.propertytable;
+
+import java.util.ArrayList;
+import java.util.List;
+
+public class ContainerElement implements IProperty {
+
+ private final String property;
+ private final List<Object> children;
+ private final ContainerElement parent;
+
+ public ContainerElement(String property, ContainerElement parent) {
+ this.property = property;
+ this.children = new ArrayList<Object>();
+ this.parent = parent;
+ }
+
+ public final String getProperty() {
+ return property;
+ }
+
+ public final void add(StringElement child) {
+ children.add(child);
+ }
+
+ public final void add(ContainerElement child) {
+ children.add(child);
+ }
+
+ public final Object[] getChildren() {
+ return children.toArray();
+ }
+
+ public boolean hasChildren() {
+ return !children.isEmpty();
+ }
+
+ public final ContainerElement getParent() {
+ return parent;
+ }
+
+ public boolean isLink() {
+ return false;
+ }
+
+ @Override
+ public String getName() {
+ return property;
+ }
+
+ @Override
+ public String getValue() {
+ return null;
+ }
+ }
\ No newline at end of file
Property changes on: trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/propertytable/ContainerElement.java
___________________________________________________________________
Added: svn:mime-type
+ text/plain
Added: trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/propertytable/IProperty.java
===================================================================
--- trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/propertytable/IProperty.java (rev 0)
+++ trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/propertytable/IProperty.java 2012-01-27 18:16:53 UTC (rev 38246)
@@ -0,0 +1,26 @@
+/*******************************************************************************
+ * Copyright (c) 2011 Red Hat, Inc.
+ * Distributed under license by Red Hat, Inc. All rights reserved.
+ * This program is made available under the terms of the
+ * Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * Red Hat, Inc. - initial API and implementation
+ ******************************************************************************/
+package org.jboss.tools.openshift.express.internal.ui.propertytable;
+
+public interface IProperty {
+
+ public String getName();
+
+ public String getValue();
+
+ public ContainerElement getParent();
+
+ public boolean isLink();
+
+ public boolean hasChildren();
+
+ public Object[] getChildren();
+}
\ No newline at end of file
Property changes on: trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/propertytable/IProperty.java
___________________________________________________________________
Added: svn:mime-type
+ text/plain
Added: trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/propertytable/LinkElement.java
===================================================================
--- trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/propertytable/LinkElement.java (rev 0)
+++ trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/propertytable/LinkElement.java 2012-01-27 18:16:53 UTC (rev 38246)
@@ -0,0 +1,18 @@
+/*******************************************************************************
+ * Copyright (c) 2011 Red Hat, Inc.
+ * Distributed under license by Red Hat, Inc. All rights reserved.
+ * This program is made available under the terms of the
+ * Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * Red Hat, Inc. - initial API and implementation
+ ******************************************************************************/
+package org.jboss.tools.openshift.express.internal.ui.propertytable;
+
+class LinkElement extends StringElement {
+
+ public LinkElement(String property, String value, ContainerElement parent) {
+ super(property, value, true, parent);
+ }
+}
\ No newline at end of file
Property changes on: trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/propertytable/LinkElement.java
___________________________________________________________________
Added: svn:mime-type
+ text/plain
Added: trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/propertytable/PropertyNameCellLabelProvider.java
===================================================================
--- trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/propertytable/PropertyNameCellLabelProvider.java (rev 0)
+++ trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/propertytable/PropertyNameCellLabelProvider.java 2012-01-27 18:16:53 UTC (rev 38246)
@@ -0,0 +1,24 @@
+/*******************************************************************************
+ * Copyright (c) 2011 Red Hat, Inc.
+ * Distributed under license by Red Hat, Inc. All rights reserved.
+ * This program is made available under the terms of the
+ * Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * Red Hat, Inc. - initial API and implementation
+ ******************************************************************************/
+package org.jboss.tools.openshift.express.internal.ui.propertytable;
+
+import org.eclipse.jface.viewers.ViewerCell;
+
+/**
+ * @author Xavier Coulon
+ * @author Andre Dietisheim
+ */
+public class PropertyNameCellLabelProvider extends AbstractPropertyCellLabelProvider {
+
+ protected void update(IProperty property, ViewerCell cell) {
+ cell.setText(property.getName());
+ }
+}
Property changes on: trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/propertytable/PropertyNameCellLabelProvider.java
___________________________________________________________________
Added: svn:mime-type
+ text/plain
Added: trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/propertytable/PropertyValueCellLabelProvider.java
===================================================================
--- trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/propertytable/PropertyValueCellLabelProvider.java (rev 0)
+++ trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/propertytable/PropertyValueCellLabelProvider.java 2012-01-27 18:16:53 UTC (rev 38246)
@@ -0,0 +1,39 @@
+/*******************************************************************************
+ * Copyright (c) 2011 Red Hat, Inc.
+ * Distributed under license by Red Hat, Inc. All rights reserved.
+ * This program is made available under the terms of the
+ * Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * Red Hat, Inc. - initial API and implementation
+ ******************************************************************************/
+package org.jboss.tools.openshift.express.internal.ui.propertytable;
+
+import org.eclipse.jface.viewers.ViewerCell;
+import org.eclipse.swt.SWT;
+import org.eclipse.swt.widgets.Link;
+import org.eclipse.swt.widgets.Tree;
+import org.jboss.tools.openshift.express.internal.ui.utils.TreeUtils;
+
+/**
+ * @author Xavier Coulon
+ * @author Andre Dietisheim
+ */
+public class PropertyValueCellLabelProvider extends AbstractPropertyCellLabelProvider {
+
+ protected void update(IProperty property, ViewerCell cell) {
+ if (property.isLink()) {
+ createLink(property, cell);
+ } else {
+ cell.setText(property.getValue());
+ }
+ }
+
+ private void createLink(IProperty property, final ViewerCell cell) {
+ Link link = new Link((Tree) cell.getControl(), SWT.NONE);
+ link.setText("<a>" + property.getValue() +"</a>");
+ link.setBackground(cell.getBackground());
+ TreeUtils.createTreeEditor(link, property.getValue(), cell);
+ }
+}
Property changes on: trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/propertytable/PropertyValueCellLabelProvider.java
___________________________________________________________________
Added: svn:mime-type
+ text/plain
Added: trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/propertytable/StringElement.java
===================================================================
--- trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/propertytable/StringElement.java (rev 0)
+++ trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/propertytable/StringElement.java 2012-01-27 18:16:53 UTC (rev 38246)
@@ -0,0 +1,35 @@
+/*******************************************************************************
+ * Copyright (c) 2011 Red Hat, Inc.
+ * Distributed under license by Red Hat, Inc. All rights reserved.
+ * This program is made available under the terms of the
+ * Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * Red Hat, Inc. - initial API and implementation
+ ******************************************************************************/
+package org.jboss.tools.openshift.express.internal.ui.propertytable;
+
+public class StringElement extends ContainerElement {
+
+ private final String value;
+ private final boolean isLink;
+
+ public StringElement(String property, String value, ContainerElement parent) {
+ this(property, value, false, parent);
+ }
+
+ public StringElement(String property, String value, boolean isLink, ContainerElement parent) {
+ super(property, parent);
+ this.value = value;
+ this.isLink = isLink;
+ }
+
+ public final String getValue() {
+ return value;
+ }
+
+ public boolean isLink() {
+ return isLink;
+ }
+}
\ No newline at end of file
Property changes on: trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/propertytable/StringElement.java
___________________________________________________________________
Added: svn:mime-type
+ text/plain
Added: trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/utils/TreeUtils.java
===================================================================
--- trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/utils/TreeUtils.java (rev 0)
+++ trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/utils/TreeUtils.java 2012-01-27 18:16:53 UTC (rev 38246)
@@ -0,0 +1,95 @@
+/*******************************************************************************
+ * Copyright (c) 2011 Red Hat, Inc.
+ * Distributed under license by Red Hat, Inc. All rights reserved.
+ * This program is made available under the terms of the
+ * Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * Red Hat, Inc. - initial API and implementation
+ ******************************************************************************/
+package org.jboss.tools.openshift.express.internal.ui.utils;
+
+import org.eclipse.core.runtime.Assert;
+import org.eclipse.jface.viewers.ViewerCell;
+import org.eclipse.swt.SWT;
+import org.eclipse.swt.custom.TableEditor;
+import org.eclipse.swt.custom.TreeEditor;
+import org.eclipse.swt.widgets.Control;
+import org.eclipse.swt.widgets.Event;
+import org.eclipse.swt.widgets.Listener;
+import org.eclipse.swt.widgets.Tree;
+import org.eclipse.swt.widgets.TreeItem;
+
+/**
+ * @author André Dietisheim
+ */
+public class TreeUtils {
+
+ /**
+ * Creates a tree editor for the given cell with the given control.
+ * <p>
+ * A tree editor puts a control over a given cell in a tree. Furthermore it puts text into the cell so that the
+ * column's large enough so that the control has enough room to overlay itself over it
+ *
+ * @param cell the cell to put the control to
+ * @param control the control to put to the given cell
+ * @param cellText the text that's put into the table cell (overlayed by the editor), that only enlarges the
+ * column to have enough room for the editor
+ *
+ * @return the tree editor
+ *
+ * @see ViewerCell
+ * @see TreeEditor
+ */
+ public static TreeEditor createTreeEditor( Control control, String cellText, ViewerCell cell )
+ {
+ Assert.isTrue(cell.getControl() instanceof Tree);
+
+ Tree tree = ( Tree ) cell.getControl();
+ TreeEditor treeEditor = new TreeEditor( tree );
+ initializeTreeEditor( treeEditor, control, cellText, cell );
+ return treeEditor;
+ }
+
+ /**
+ * Initializes a given table editor for a given viewer cell with a given (editor-)control.
+ *
+ * @param treeEditor the table editor
+ * @param control the control
+ * @param cellText the cell text
+ * @param cell the cell
+ *
+ * @see TableEditor
+ * @see ViewerCell
+ */
+ public static void initializeTreeEditor( TreeEditor treeEditor, Control control, String cellText, ViewerCell cell )
+ {
+ treeEditor.grabHorizontal = true;
+ treeEditor.grabVertical = true;
+ treeEditor.horizontalAlignment = SWT.CENTER;
+ treeEditor.verticalAlignment = SWT.CENTER;
+ TreeItem treeItem = ( TreeItem ) cell.getItem();
+ treeEditor.setEditor( control, treeItem, cell.getColumnIndex() );
+ // ensure cell is as large as space needed for link
+ cell.setText( " " + cellText + " ");
+ }
+
+ /**
+ * Sets the height of the rows in a given table. The height might only be increased (compared to the standard
+ * height). Decreasing it below the default height has no effect.
+ *
+ * @param height the height in pixels
+ * @param table the table
+ */
+ public static void setRowHeight( final int height, Tree tree )
+ {
+ tree.addListener( SWT.MeasureItem, new Listener()
+ {
+ public void handleEvent( Event event )
+ {
+ event.height = height;
+ }
+ } );
+ }
+}
Property changes on: trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/utils/TreeUtils.java
___________________________________________________________________
Added: svn:mime-type
+ text/plain
Modified: trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/wizard/ApplicationDetailsContentProvider.java
===================================================================
--- trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/wizard/ApplicationDetailsContentProvider.java 2012-01-27 17:30:19 UTC (rev 38245)
+++ trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/wizard/ApplicationDetailsContentProvider.java 2012-01-27 18:16:53 UTC (rev 38246)
@@ -4,11 +4,10 @@
package org.jboss.tools.openshift.express.internal.ui.wizard;
import java.text.SimpleDateFormat;
-import java.util.ArrayList;
-import java.util.List;
-import org.eclipse.jface.viewers.ITreeContentProvider;
-import org.eclipse.jface.viewers.Viewer;
+import org.jboss.tools.openshift.express.internal.ui.propertytable.AbstractPropertyTableContentProvider;
+import org.jboss.tools.openshift.express.internal.ui.propertytable.ContainerElement;
+import org.jboss.tools.openshift.express.internal.ui.propertytable.StringElement;
import org.jboss.tools.openshift.express.internal.ui.utils.Logger;
import com.openshift.express.client.IApplication;
@@ -17,170 +16,44 @@
/**
* @author Xavier Coulon
+ * @author Andre Dietisheim
*
*/
-public class ApplicationDetailsContentProvider implements ITreeContentProvider {
+public class ApplicationDetailsContentProvider extends AbstractPropertyTableContentProvider {
- private IApplication application;
-
@Override
public Object[] getElements(Object inputElement) {
+ Object[] elements = null;
if (inputElement instanceof IApplication) {
try {
- final SimpleDateFormat format = new SimpleDateFormat("yyyy/MM/dd 'at' HH:mm:ss");
+ IApplication application = (IApplication) inputElement;
final ContainerElement infoContainer = new ContainerElement("info", null);
- infoContainer.add(new SimpleElement("Name", application.getName(), infoContainer));
- infoContainer.add(new SimpleElement("Public URL", application.getApplicationUrl().toString(), true,
+ infoContainer.add(new StringElement("Name", application.getName(), infoContainer));
+ infoContainer.add(new StringElement("Public URL", application.getApplicationUrl().toString(), true,
infoContainer));
- infoContainer.add(new SimpleElement("Type", application.getCartridge().getName(), infoContainer));
- infoContainer.add(new SimpleElement("Created on", format.format(application.getCreationTime()),
- infoContainer));
- infoContainer.add(new SimpleElement("UUID", application.getUUID(), infoContainer));
- infoContainer.add(new SimpleElement("Git URL", application.getGitUri(), infoContainer));
- final ContainerElement cartridgesContainer = new ContainerElement("Cartridges", infoContainer);
- infoContainer.add(cartridgesContainer);
- for (IEmbeddableCartridge cartridge : application.getEmbeddedCartridges()) {
- cartridgesContainer.add(new SimpleElement(cartridge.getName(), cartridge.getUrl().toString(), true,
- cartridgesContainer));
- }
- return new Object[] { infoContainer };
- } catch (OpenShiftException e) {
+ infoContainer.add(new StringElement("Type", application.getCartridge().getName(), infoContainer));
+ final SimpleDateFormat format = new SimpleDateFormat("yyyy/MM/dd 'at' HH:mm:ss");
+ infoContainer.add(
+ new StringElement("Created on", format.format(application.getCreationTime()), infoContainer));
+ infoContainer.add(new StringElement("UUID", application.getUUID(), infoContainer));
+ infoContainer.add(new StringElement("Git URL", application.getGitUri(), infoContainer));
+ infoContainer.add(createCartridges(application, infoContainer));
+ elements = new Object[] { infoContainer };
+ } catch (Exception e) {
Logger.error("Failed to display details for OpenShift application", e);
}
}
- return null;
+ return elements;
}
- @Override
- public Object[] getChildren(Object parentElement) {
- if (parentElement instanceof ContainerElement) {
- return ((ContainerElement) parentElement).getChildren();
+ private ContainerElement createCartridges(IApplication application, ContainerElement infoContainer)
+ throws OpenShiftException {
+ ContainerElement cartridgesContainer = new ContainerElement("Cartridges", infoContainer);
+ for (IEmbeddableCartridge cartridge : application.getEmbeddedCartridges()) {
+ cartridgesContainer.add(
+ new StringElement(cartridge.getName(), cartridge.getUrl().toString(), true,
+ cartridgesContainer));
}
- return new Object[0];
+ return cartridgesContainer;
}
-
- @Override
- public Object getParent(Object element) {
- if (element instanceof SimpleElement) {
- return ((SimpleElement) element).getParent();
- } else if (element instanceof ContainerElement) {
- return ((ContainerElement) element).getParent();
- }
- return null;
- }
-
- @Override
- public boolean hasChildren(Object element) {
- return (element instanceof ContainerElement);
- }
-
- @Override
- public void dispose() {
-
- }
-
- @Override
- public void inputChanged(Viewer viewer, Object oldInput, Object newInput) {
- if (newInput instanceof IApplication) {
- this.application = (IApplication) newInput;
- } else {
- this.application = null;
- }
-
- }
-
- static class SimpleElement {
-
- private final String property;
- private final String value;
- private final ContainerElement parent;
- private final boolean isLink;
-
- public SimpleElement(String property, String value, ContainerElement parent) {
- super();
- this.property = property;
- this.value = value;
- this.parent = parent;
- this.isLink = false;
- }
-
- public SimpleElement(String property, String value, boolean isLink, ContainerElement parent) {
- super();
- this.property = property;
- this.value = value;
- this.parent = parent;
- this.isLink = isLink;
- }
-
- /**
- * @return the property
- */
- public final String getProperty() {
- return property;
- }
-
- /**
- * @return the value
- */
- public final String getValue() {
- return value;
- }
-
- /**
- * @return the parent container
- */
- public final ContainerElement getParent() {
- return parent;
- }
-
- /**
- * @return the isLink
- */
- public boolean isLink() {
- return isLink;
- }
- }
-
- static class ContainerElement {
-
- private final String property;
- private final List<Object> children;
- private final ContainerElement parent;
-
- public ContainerElement(String property, ContainerElement parent) {
- this.property = property;
- this.children = new ArrayList<Object>();
- this.parent = parent;
- }
-
- /**
- * @return the property
- */
- public final String getProperty() {
- return property;
- }
-
- public final void add(SimpleElement child) {
- children.add(child);
- }
-
- public final void add(ContainerElement child) {
- children.add(child);
- }
-
- /**
- * @return the value
- */
- public final Object[] getChildren() {
- return children.toArray();
- }
-
- /**
- * @return the parent container
- */
- public final ContainerElement getParent() {
- return parent;
- }
- }
-
}
Modified: trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/wizard/ApplicationDetailsDialog.java
===================================================================
--- trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/wizard/ApplicationDetailsDialog.java 2012-01-27 17:30:19 UTC (rev 38245)
+++ trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/wizard/ApplicationDetailsDialog.java 2012-01-27 18:16:53 UTC (rev 38246)
@@ -10,9 +10,6 @@
******************************************************************************/
package org.jboss.tools.openshift.express.internal.ui.wizard;
-import java.util.concurrent.Callable;
-
-import org.eclipse.core.runtime.ILog;
import org.eclipse.jface.dialogs.IDialogConstants;
import org.eclipse.jface.dialogs.TitleAreaDialog;
import org.eclipse.jface.layout.GridDataFactory;
@@ -20,33 +17,24 @@
import org.eclipse.jface.layout.TreeColumnLayout;
import org.eclipse.jface.viewers.CellLabelProvider;
import org.eclipse.jface.viewers.ColumnWeightData;
-import org.eclipse.jface.viewers.StyledCellLabelProvider;
-import org.eclipse.jface.viewers.StyledString;
-import org.eclipse.jface.viewers.StyledString.Styler;
import org.eclipse.jface.viewers.TreeViewer;
import org.eclipse.jface.viewers.TreeViewerColumn;
-import org.eclipse.jface.viewers.ViewerCell;
import org.eclipse.osgi.util.NLS;
import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.SelectionAdapter;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.graphics.TextStyle;
import org.eclipse.swt.widgets.Composite;
import org.eclipse.swt.widgets.Control;
-import org.eclipse.swt.widgets.Display;
import org.eclipse.swt.widgets.Label;
import org.eclipse.swt.widgets.Shell;
-import org.eclipse.swt.widgets.Text;
import org.eclipse.swt.widgets.Tree;
import org.eclipse.swt.widgets.TreeColumn;
-import org.jboss.tools.common.ui.BrowserUtil;
import org.jboss.tools.openshift.express.internal.ui.OpenShiftImages;
-import org.jboss.tools.openshift.express.internal.ui.OpenShiftUIActivator;
+import org.jboss.tools.openshift.express.internal.ui.propertytable.PropertyNameCellLabelProvider;
+import org.jboss.tools.openshift.express.internal.ui.propertytable.PropertyValueCellLabelProvider;
import com.openshift.express.client.IApplication;
/**
- * @author Andr� Dietisheim
+ * @author Andre Dietisheim
* @author Xavier Coulon
*/
public class ApplicationDetailsDialog extends TitleAreaDialog {
@@ -74,80 +62,18 @@
Composite dialogArea = new Composite(parent, SWT.NONE);
GridDataFactory.fillDefaults()
.align(SWT.FILL, SWT.FILL).grab(true, true).applyTo(dialogArea);
- GridLayoutFactory.fillDefaults().margins(6, 6).applyTo(dialogArea);
+ GridLayoutFactory.fillDefaults().margins(10, 10).applyTo(dialogArea);
TreeViewer viewer = createApplicationDetailsTable(dialogArea);
fillApplicationDetailsTable(viewer);
-
+
Label buttonsSeparator = new Label(parent, SWT.HORIZONTAL | SWT.SEPARATOR);
GridDataFactory.fillDefaults()
.align(SWT.FILL, SWT.TOP).grab(true, false).applyTo(buttonsSeparator);
- // createDetails("Name:", application.getName(), treeTableContainer);
- // createDetails("Type:", application.getCartridge().getName(),
- // treeTableContainer);
- // createDetails("Embedded Cartridges:", new
- // ErrorMessageCallable<String>("Embedded Cartridges") {
- //
- // @Override
- // public String call() throws Exception {
- // return StringUtils.toString(application.getEmbeddedCartridges(),
- // new StringUtils.ToStringConverter<IEmbeddableCartridge>() {
- //
- // @Override
- // public String toString(IEmbeddableCartridge cartridge) {
- // return cartridge.getName();
- // }
- // });
- // }
- //
- // }.get(), treeTableContainer);
- // createDetails("Creation Time:", new
- // ErrorMessageCallable<String>("Creation Time") {
- //
- // @Override
- // public String call() throws Exception {
- // return RFC822DateUtils.getString(application.getCreationTime());
- // }
- // }.get(), treeTableContainer);
- // createDetails("UUIDxx:", new ErrorMessageCallable<String>("UUID") {
- //
- // @Override
- // public String call() throws Exception {
- // return application.getUUID();
- // }
- // }.get(), treeTableContainer);
- // createDetails("Git URL:", new ErrorMessageCallable<String>("Git URL")
- // {
- //
- // @Override
- // public String call() throws Exception {
- // return application.getGitUri();
- // }
- // }.get(), treeTableContainer);
- //
- // Label publicUrlLabel = new Label(treeTableContainer, SWT.NONE);
- // publicUrlLabel.setText("Public URL:");
- // GridDataFactory.fillDefaults().align(SWT.LEFT,
- // SWT.CENTER).applyTo(publicUrlLabel);
- // Link publicUrlLink = new Link(treeTableContainer, SWT.WRAP);
- // String applicationUrl = new
- // ErrorMessageCallable<String>("Public URL") {
- //
- // @Override
- // public String call() throws Exception {
- // return application.getApplicationUrl();
- // }
- // }.get();
- // publicUrlLink.setText("<a>" + applicationUrl + "</a>");
- // GridDataFactory.fillDefaults().align(SWT.FILL, SWT.CENTER).grab(true,
- // false).applyTo(publicUrlLink);
- // publicUrlLink.addSelectionListener(onPublicUrl(applicationUrl));
-
return dialogArea;
}
private void fillApplicationDetailsTable(final TreeViewer viewer) {
- viewer.setContentProvider(new ApplicationDetailsContentProvider());
viewer.setInput(application);
viewer.expandToLevel(2);
}
@@ -156,57 +82,19 @@
Composite tableContainer = new Composite(parent, SWT.NONE);
TreeColumnLayout treeLayout = new TreeColumnLayout();
tableContainer.setLayout(treeLayout);
-
+
Tree tree = new Tree(tableContainer, SWT.BORDER | SWT.FULL_SELECTION | SWT.V_SCROLL | SWT.H_SCROLL);
tree.setLinesVisible(true);
tree.setHeaderVisible(true);
-// GridDataFactory.fillDefaults().align(SWT.FILL, SWT.FILL).grab(true, true).hint(500, tree.getItemHeight() * 10).applyTo(tableContainer);
- GridDataFactory.fillDefaults().align(SWT.FILL, SWT.FILL).grab(true, true).hint(500, 300).applyTo(tableContainer);
+ GridDataFactory.fillDefaults()
+ .align(SWT.FILL, SWT.FILL).grab(true, true).hint(500, 300).applyTo(tableContainer);
- TreeViewer viewer = new TreeViewer(tree);
- createTreeColumn("Property", 1, new CellLabelProvider() {
- @Override
- public void update(ViewerCell cell) {
- if (cell.getElement() instanceof ApplicationDetailsContentProvider.SimpleElement) {
- ApplicationDetailsContentProvider.SimpleElement element = (ApplicationDetailsContentProvider.SimpleElement) cell
- .getElement();
- cell.setText(element.getProperty());
- } else if (cell.getElement() instanceof ApplicationDetailsContentProvider.ContainerElement) {
- ApplicationDetailsContentProvider.ContainerElement element = (ApplicationDetailsContentProvider.ContainerElement) cell
- .getElement();
- cell.setText(element.getProperty());
- }
- }
- }, viewer, treeLayout);
+ final TreeViewer viewer = new TreeViewer(tree);
+ viewer.setContentProvider(new ApplicationDetailsContentProvider());
+ createTreeColumn("Property", 1, new PropertyNameCellLabelProvider(), viewer, treeLayout);
+ createTreeColumn("Value", 3, new PropertyValueCellLabelProvider(), viewer, treeLayout);
- createTreeColumn("Value", 3, new StyledCellLabelProvider() {
- @Override
- public void update(ViewerCell cell) {
- if (cell.getElement() instanceof ApplicationDetailsContentProvider.SimpleElement) {
- ApplicationDetailsContentProvider.SimpleElement element = (ApplicationDetailsContentProvider.SimpleElement) cell
- .getElement();
- cell.setText(element.getValue());
- if (element.isLink()) {
- Styler style = new Styler() {
- @Override
- public void applyStyles(TextStyle textStyle) {
- textStyle.foreground = Display.getDefault().getSystemColor(SWT.COLOR_BLUE);
- textStyle.underline = true;
- }
-
- };
- StyledString styledString = new StyledString(cell.getText(), style);
- cell.setStyleRanges(styledString.getStyleRanges());
- cell.setText(styledString.getString());
- // cell.setCursor(new Cursor(Display.getCurrent(),
- // SWT.CURSOR_HAND));
- }
- }
- }
- }, viewer, treeLayout);
-
return viewer;
-
}
private void createTreeColumn(String name, int weight, CellLabelProvider cellLabelProvider, TreeViewer treeViewer,
@@ -230,47 +118,4 @@
protected void createButtonsForButtonBar(Composite parent) {
createButton(parent, IDialogConstants.OK_ID, IDialogConstants.OK_LABEL, true);
}
-
- private SelectionAdapter onPublicUrl(final String applicationUrl) {
- return new SelectionAdapter() {
-
- @Override
- public void widgetSelected(SelectionEvent e) {
- ILog log = OpenShiftUIActivator.getDefault().getLog();
- BrowserUtil.checkedCreateExternalBrowser(applicationUrl, OpenShiftUIActivator.PLUGIN_ID, log);
- }
- };
- }
-
- private void createDetails(String name, String value, Composite container) {
- Label label = new Label(container, SWT.None);
- label.setText(name);
- GridDataFactory.fillDefaults().align(SWT.LEFT, SWT.CENTER).applyTo(label);
- Text text = new Text(container, SWT.NONE);
- text.setEditable(false);
- text.setBackground(container.getBackground());
- GridDataFactory.fillDefaults().align(SWT.FILL, SWT.CENTER).grab(true, false).applyTo(text);
- text.setText(value);
- }
-
- private abstract class ErrorMessageCallable<T> implements Callable<T> {
-
- private String fieldName;
-
- public ErrorMessageCallable(String fieldName) {
- this.fieldName = fieldName;
- }
-
- public T get() {
- try {
- return call();
- } catch (Exception e) {
- setErrorMessage(NLS.bind("Could not get {0}: {1}", fieldName, e.getMessage()));
- return null;
- }
- }
-
- @Override
- public abstract T call() throws Exception;
- }
}
13 years, 11 months
JBoss Tools SVN: r38245 - trunk/cdi/plugins/org.jboss.tools.cdi.ui/src/org/jboss/tools/cdi/ui/marker.
by jbosstools-commits@lists.jboss.org
Author: dazarov
Date: 2012-01-27 12:30:19 -0500 (Fri, 27 Jan 2012)
New Revision: 38245
Modified:
trunk/cdi/plugins/org.jboss.tools.cdi.ui/src/org/jboss/tools/cdi/ui/marker/AddLocalBeanMarkerResolution.java
trunk/cdi/plugins/org.jboss.tools.cdi.ui/src/org/jboss/tools/cdi/ui/marker/MakeFieldProtectedMarkerResolution.java
trunk/cdi/plugins/org.jboss.tools.cdi.ui/src/org/jboss/tools/cdi/ui/marker/MakeFieldStaticMarkerResolution.java
trunk/cdi/plugins/org.jboss.tools.cdi.ui/src/org/jboss/tools/cdi/ui/marker/MakeMethodBusinessMarkerResolution.java
trunk/cdi/plugins/org.jboss.tools.cdi.ui/src/org/jboss/tools/cdi/ui/marker/MakeMethodPublicMarkerResolution.java
Log:
Constructions like "flag & Flags.AccPublic == 0" changed to Flags.isPublic(flag)
Modified: trunk/cdi/plugins/org.jboss.tools.cdi.ui/src/org/jboss/tools/cdi/ui/marker/AddLocalBeanMarkerResolution.java
===================================================================
--- trunk/cdi/plugins/org.jboss.tools.cdi.ui/src/org/jboss/tools/cdi/ui/marker/AddLocalBeanMarkerResolution.java 2012-01-27 15:52:45 UTC (rev 38244)
+++ trunk/cdi/plugins/org.jboss.tools.cdi.ui/src/org/jboss/tools/cdi/ui/marker/AddLocalBeanMarkerResolution.java 2012-01-27 17:30:19 UTC (rev 38245)
@@ -73,17 +73,16 @@
// make method public
int position = method.getSourceRange().getOffset();
- if((flag & Flags.AccPublic) == 0){
- if((flag & Flags.AccPrivate) != 0){
+ if(!Flags.isPublic(flag)){
+ if(Flags.isPrivate(flag)){
position += text.indexOf(PRIVATE);
edit.addChild(new ReplaceEdit(position, PRIVATE.length(), PUBLIC));
- }else if((flag & Flags.AccProtected) != 0){
+ }else if(Flags.isProtected(flag)){
position += text.indexOf(PROTECTED);
edit.addChild(new ReplaceEdit(position, PROTECTED.length(), PUBLIC));
}else{
String type = Signature.getSignatureSimpleName(method.getReturnType());
position += text.indexOf(type);
- buffer.replace(position, 0, PUBLIC+SPACE);
edit.addChild(new InsertEdit(position, PUBLIC+SPACE));
}
}
Modified: trunk/cdi/plugins/org.jboss.tools.cdi.ui/src/org/jboss/tools/cdi/ui/marker/MakeFieldProtectedMarkerResolution.java
===================================================================
--- trunk/cdi/plugins/org.jboss.tools.cdi.ui/src/org/jboss/tools/cdi/ui/marker/MakeFieldProtectedMarkerResolution.java 2012-01-27 15:52:45 UTC (rev 38244)
+++ trunk/cdi/plugins/org.jboss.tools.cdi.ui/src/org/jboss/tools/cdi/ui/marker/MakeFieldProtectedMarkerResolution.java 2012-01-27 17:30:19 UTC (rev 38245)
@@ -111,7 +111,7 @@
String text = buffer.getText(field.getSourceRange().getOffset(), field.getSourceRange().getLength());
int position = field.getSourceRange().getOffset();
- if((flag & Flags.AccPublic) != 0){
+ if(Flags.isPublic(flag)){
position += text.indexOf(PUBLIC);
TextEdit re = new ReplaceEdit(position, PUBLIC.length(), PROTECTED);
edit.addChild(re);
Modified: trunk/cdi/plugins/org.jboss.tools.cdi.ui/src/org/jboss/tools/cdi/ui/marker/MakeFieldStaticMarkerResolution.java
===================================================================
--- trunk/cdi/plugins/org.jboss.tools.cdi.ui/src/org/jboss/tools/cdi/ui/marker/MakeFieldStaticMarkerResolution.java 2012-01-27 15:52:45 UTC (rev 38244)
+++ trunk/cdi/plugins/org.jboss.tools.cdi.ui/src/org/jboss/tools/cdi/ui/marker/MakeFieldStaticMarkerResolution.java 2012-01-27 17:30:19 UTC (rev 38245)
@@ -64,15 +64,15 @@
String text = buffer.getText(field.getSourceRange().getOffset(), field.getSourceRange().getLength());
int position = field.getSourceRange().getOffset();
- if((flag & Flags.AccPublic) != 0){
+ if(Flags.isPublic(flag)){
position += text.indexOf(CDIMarkerResolutionUtils.PUBLIC)+CDIMarkerResolutionUtils.PUBLIC.length();
InsertEdit ie = new InsertEdit(position, CDIMarkerResolutionUtils.SPACE+CDIMarkerResolutionUtils.STATIC);
edit.addChild(ie);
- }else if((flag & Flags.AccPrivate) != 0){
+ }else if(Flags.isPrivate(flag)){
position += text.indexOf(CDIMarkerResolutionUtils.PRIVATE)+CDIMarkerResolutionUtils.PRIVATE.length();
InsertEdit ie = new InsertEdit(position, CDIMarkerResolutionUtils.SPACE+CDIMarkerResolutionUtils.STATIC);
edit.addChild(ie);
- }else if((flag & Flags.AccProtected) != 0){
+ }else if(Flags.isProtected(flag)){
position += text.indexOf(CDIMarkerResolutionUtils.PROTECTED)+CDIMarkerResolutionUtils.PROTECTED.length();
InsertEdit ie = new InsertEdit(position, CDIMarkerResolutionUtils.SPACE+CDIMarkerResolutionUtils.STATIC);
edit.addChild(ie);
Modified: trunk/cdi/plugins/org.jboss.tools.cdi.ui/src/org/jboss/tools/cdi/ui/marker/MakeMethodBusinessMarkerResolution.java
===================================================================
--- trunk/cdi/plugins/org.jboss.tools.cdi.ui/src/org/jboss/tools/cdi/ui/marker/MakeMethodBusinessMarkerResolution.java 2012-01-27 15:52:45 UTC (rev 38244)
+++ trunk/cdi/plugins/org.jboss.tools.cdi.ui/src/org/jboss/tools/cdi/ui/marker/MakeMethodBusinessMarkerResolution.java 2012-01-27 17:30:19 UTC (rev 38245)
@@ -76,20 +76,19 @@
// make method public
int position = method.getSourceRange().getOffset();
- if((flag & Flags.AccPublic) != 0){
- // do nothing
- }else if((flag & Flags.AccPrivate) != 0){
- position += text.indexOf(PRIVATE);
- buffer.replace(position, PRIVATE.length(), PUBLIC);
- }else if((flag & Flags.AccProtected) != 0){
- position += text.indexOf(PROTECTED);
- buffer.replace(position, PROTECTED.length(), PUBLIC);
- }else{
- String type = Signature.getSignatureSimpleName(method.getReturnType());
- position += text.indexOf(type);
- buffer.replace(position, 0, PUBLIC+SPACE);
+ if(!Flags.isPublic(flag)){
+ if(Flags.isPrivate(flag)){
+ position += text.indexOf(PRIVATE);
+ buffer.replace(position, PRIVATE.length(), PUBLIC);
+ }else if(Flags.isProtected(flag)){
+ position += text.indexOf(PROTECTED);
+ buffer.replace(position, PROTECTED.length(), PUBLIC);
+ }else{
+ String type = Signature.getSignatureSimpleName(method.getReturnType());
+ position += text.indexOf(type);
+ buffer.replace(position, 0, PUBLIC+SPACE);
+ }
}
-
compilationUnit.commitWorkingCopy(false, new NullProgressMonitor());
compilationUnit.discardWorkingCopy();
Modified: trunk/cdi/plugins/org.jboss.tools.cdi.ui/src/org/jboss/tools/cdi/ui/marker/MakeMethodPublicMarkerResolution.java
===================================================================
--- trunk/cdi/plugins/org.jboss.tools.cdi.ui/src/org/jboss/tools/cdi/ui/marker/MakeMethodPublicMarkerResolution.java 2012-01-27 15:52:45 UTC (rev 38244)
+++ trunk/cdi/plugins/org.jboss.tools.cdi.ui/src/org/jboss/tools/cdi/ui/marker/MakeMethodPublicMarkerResolution.java 2012-01-27 17:30:19 UTC (rev 38245)
@@ -69,12 +69,12 @@
// make method public
int position = workingCopyMethod.getSourceRange().getOffset();
- if((flag & Flags.AccPublic) == 0){
- if((flag & Flags.AccPrivate) != 0){
+ if(!Flags.isPublic(flag)){
+ if(Flags.isPrivate(flag)){
position += text.indexOf(CDIMarkerResolutionUtils.PRIVATE);
ReplaceEdit re = new ReplaceEdit(position, CDIMarkerResolutionUtils.PRIVATE.length(), CDIMarkerResolutionUtils.PUBLIC);
edit.addChild(re);
- }else if((flag & Flags.AccProtected) != 0){
+ }else if(Flags.isProtected(flag)){
position += text.indexOf(CDIMarkerResolutionUtils.PROTECTED);
ReplaceEdit re = new ReplaceEdit(position, CDIMarkerResolutionUtils.PROTECTED.length(), CDIMarkerResolutionUtils.PUBLIC);
edit.addChild(re);
13 years, 11 months
JBoss Tools SVN: r38244 - in workspace/bfitzpat/org.jboss.tools.esb.visualizer: src/org/jboss/tools/esb/visualizer/views and 1 other directory.
by jbosstools-commits@lists.jboss.org
Author: bfitzpat
Date: 2012-01-27 10:52:45 -0500 (Fri, 27 Jan 2012)
New Revision: 38244
Added:
workspace/bfitzpat/org.jboss.tools.esb.visualizer/src/org/jboss/tools/esb/visualizer/views/ESBNode.java
workspace/bfitzpat/org.jboss.tools.esb.visualizer/src/org/jboss/tools/esb/visualizer/views/ESBNodeWithChildren.java
Removed:
workspace/bfitzpat/org.jboss.tools.esb.visualizer/src/org/jboss/tools/esb/visualizer/views/TreeObject.java
workspace/bfitzpat/org.jboss.tools.esb.visualizer/src/org/jboss/tools/esb/visualizer/views/TreeParent.java
Modified:
workspace/bfitzpat/org.jboss.tools.esb.visualizer/plugin.xml
workspace/bfitzpat/org.jboss.tools.esb.visualizer/src/org/jboss/tools/esb/visualizer/views/ESBDomParser.java
workspace/bfitzpat/org.jboss.tools.esb.visualizer/src/org/jboss/tools/esb/visualizer/views/ESBVisualizerView.java
Log:
[JBIDE-10726] A bit of refactoring, adding Show In support to JBoss perspective
Modified: workspace/bfitzpat/org.jboss.tools.esb.visualizer/plugin.xml
===================================================================
--- workspace/bfitzpat/org.jboss.tools.esb.visualizer/plugin.xml 2012-01-27 11:34:16 UTC (rev 38243)
+++ workspace/bfitzpat/org.jboss.tools.esb.visualizer/plugin.xml 2012-01-27 15:52:45 UTC (rev 38244)
@@ -29,5 +29,11 @@
id="org.jboss.tools.esb.visualizer.views.ESBVisualizerView">
</showInPart>
</perspectiveExtension>
+ <perspectiveExtension
+ targetID="org.jboss.tools.common.ui.JBossPerspective">
+ <showInPart
+ id="org.jboss.tools.esb.visualizer.views.ESBVisualizerView">
+ </showInPart>
+ </perspectiveExtension>
</extension>
</plugin>
Modified: workspace/bfitzpat/org.jboss.tools.esb.visualizer/src/org/jboss/tools/esb/visualizer/views/ESBDomParser.java
===================================================================
--- workspace/bfitzpat/org.jboss.tools.esb.visualizer/src/org/jboss/tools/esb/visualizer/views/ESBDomParser.java 2012-01-27 11:34:16 UTC (rev 38243)
+++ workspace/bfitzpat/org.jboss.tools.esb.visualizer/src/org/jboss/tools/esb/visualizer/views/ESBDomParser.java 2012-01-27 15:52:45 UTC (rev 38244)
@@ -24,7 +24,7 @@
import org.eclipse.core.runtime.IPath;
import org.eclipse.core.runtime.Path;
import org.jboss.tools.esb.visualizer.Activator;
-import org.jboss.tools.esb.visualizer.views.TreeObject.ESBType;
+import org.jboss.tools.esb.visualizer.views.ESBNode.ESBType;
import org.osgi.framework.Bundle;
import org.w3c.dom.Document;
import org.w3c.dom.Element;
@@ -34,7 +34,7 @@
public class ESBDomParser {
Document dom;
- TreeParent root;
+ ESBNodeWithChildren root;
public boolean isFileESBConfig ( String filepath ) {
//get the factory
@@ -66,7 +66,7 @@
public void parseXmlFile(String filepath){
- root = new TreeParent("Invisible Root");
+ root = new ESBNodeWithChildren("Invisible Root");
//get the factory
DocumentBuilderFactory dbf = DocumentBuilderFactory.newInstance();
@@ -120,8 +120,8 @@
}
}
if(providersElement != null) {
- TreeParent providersRoot = new TreeParent("Providers");
- providersRoot.setEsbObjectType(TreeObject.ESBType.PROVIDER);
+ ESBNodeWithChildren providersRoot = new ESBNodeWithChildren("Providers");
+ providersRoot.setEsbObjectType(ESBNode.ESBType.PROVIDER);
processChildren(providersRoot, providersElement);
root.addChild(providersRoot);
}
@@ -138,15 +138,15 @@
}
}
if(servicesElement != null) {
- TreeParent servicesRoot = new TreeParent("Services");
- servicesRoot.setEsbObjectType(TreeObject.ESBType.SERVICE);
+ ESBNodeWithChildren servicesRoot = new ESBNodeWithChildren("Services");
+ servicesRoot.setEsbObjectType(ESBNode.ESBType.SERVICE);
processChildren(servicesRoot, servicesElement);
root.addChild(servicesRoot);
}
}
}
- private void processChildren ( TreeParent parent, Element el ) {
+ private void processChildren ( ESBNodeWithChildren parent, Element el ) {
el.normalize();
parent.setData(el);
@@ -186,7 +186,7 @@
name = child.getTagName();
}
- TreeParent childNode = new TreeParent(name);
+ ESBNodeWithChildren childNode = new ESBNodeWithChildren(name);
String ref = child.getAttribute("busidref");
if (ref != null && ref.trim().length() > 0) {
childNode.setRef(ref);
@@ -200,7 +200,7 @@
}
}
- public TreeParent getRoot() {
+ public ESBNodeWithChildren getRoot() {
return this.root;
}
Copied: workspace/bfitzpat/org.jboss.tools.esb.visualizer/src/org/jboss/tools/esb/visualizer/views/ESBNode.java (from rev 38219, workspace/bfitzpat/org.jboss.tools.esb.visualizer/src/org/jboss/tools/esb/visualizer/views/TreeObject.java)
===================================================================
--- workspace/bfitzpat/org.jboss.tools.esb.visualizer/src/org/jboss/tools/esb/visualizer/views/ESBNode.java (rev 0)
+++ workspace/bfitzpat/org.jboss.tools.esb.visualizer/src/org/jboss/tools/esb/visualizer/views/ESBNode.java 2012-01-27 15:52:45 UTC (rev 38244)
@@ -0,0 +1,74 @@
+/*******************************************************************************
+ * Copyright (c) 2012 Red Hat, Inc.
+ * Distributed under license by Red Hat, Inc. All rights reserved.
+ * This program is made available under the terms of the
+ * Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * Red Hat, Inc. - initial API and implementation
+ ******************************************************************************/
+package org.jboss.tools.esb.visualizer.views;
+
+import org.eclipse.core.runtime.IAdaptable;
+
+public class ESBNode implements IAdaptable {
+ private String name;
+ private ESBNodeWithChildren parent;
+ private String ref;
+ private boolean wasMovedFlag = false;
+ private ESBType esbObjectType;
+ private Object data;
+
+ public enum ESBType {
+ ACTION, BUS, LISTENER, PROVIDER,
+ ESB, PROPERTY, SERVICE
+ }
+
+ public ESBNode(String name) {
+ this.name = name;
+ }
+ public String getName() {
+ return name;
+ }
+ public void setName(String newName) {
+ this.name = newName;
+ }
+ public void setParent(ESBNodeWithChildren parent) {
+ this.parent = parent;
+ }
+ public ESBNodeWithChildren getParent() {
+ return parent;
+ }
+ public String toString() {
+ return getName();
+ }
+ @SuppressWarnings("rawtypes")
+ public Object getAdapter(Class key) {
+ return null;
+ }
+ public String getRef() {
+ return ref;
+ }
+ public void setRef(String ref) {
+ this.ref = ref;
+ }
+ protected boolean wasMoved() {
+ return wasMovedFlag;
+ }
+ protected void setWasMoved(boolean wasMoved) {
+ this.wasMovedFlag = wasMoved;
+ }
+ protected ESBType getEsbObjectType() {
+ return esbObjectType;
+ }
+ protected void setEsbObjectType(ESBType esbObjectType) {
+ this.esbObjectType = esbObjectType;
+ }
+ protected Object getData() {
+ return data;
+ }
+ protected void setData(Object data) {
+ this.data = data;
+ }
+}
\ No newline at end of file
Property changes on: workspace/bfitzpat/org.jboss.tools.esb.visualizer/src/org/jboss/tools/esb/visualizer/views/ESBNode.java
___________________________________________________________________
Added: svn:mime-type
+ text/plain
Copied: workspace/bfitzpat/org.jboss.tools.esb.visualizer/src/org/jboss/tools/esb/visualizer/views/ESBNodeWithChildren.java (from rev 38219, workspace/bfitzpat/org.jboss.tools.esb.visualizer/src/org/jboss/tools/esb/visualizer/views/TreeParent.java)
===================================================================
--- workspace/bfitzpat/org.jboss.tools.esb.visualizer/src/org/jboss/tools/esb/visualizer/views/ESBNodeWithChildren.java (rev 0)
+++ workspace/bfitzpat/org.jboss.tools.esb.visualizer/src/org/jboss/tools/esb/visualizer/views/ESBNodeWithChildren.java 2012-01-27 15:52:45 UTC (rev 38244)
@@ -0,0 +1,36 @@
+/*******************************************************************************
+ * Copyright (c) 2012 Red Hat, Inc.
+ * Distributed under license by Red Hat, Inc. All rights reserved.
+ * This program is made available under the terms of the
+ * Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * Red Hat, Inc. - initial API and implementation
+ ******************************************************************************/
+package org.jboss.tools.esb.visualizer.views;
+
+import java.util.ArrayList;
+
+public class ESBNodeWithChildren extends ESBNode {
+
+ private ArrayList<ESBNode> children;
+ public ESBNodeWithChildren(String name) {
+ super(name);
+ children = new ArrayList<ESBNode>();
+ }
+ public void addChild(ESBNode child) {
+ children.add(child);
+ child.setParent(this);
+ }
+ public void removeChild(ESBNode child) {
+ children.remove(child);
+ child.setParent(null);
+ }
+ public ESBNode [] getChildren() {
+ return (ESBNode [])children.toArray(new ESBNode[children.size()]);
+ }
+ public boolean hasChildren() {
+ return children.size()>0;
+ }
+}
Property changes on: workspace/bfitzpat/org.jboss.tools.esb.visualizer/src/org/jboss/tools/esb/visualizer/views/ESBNodeWithChildren.java
___________________________________________________________________
Added: svn:mime-type
+ text/plain
Modified: workspace/bfitzpat/org.jboss.tools.esb.visualizer/src/org/jboss/tools/esb/visualizer/views/ESBVisualizerView.java
===================================================================
--- workspace/bfitzpat/org.jboss.tools.esb.visualizer/src/org/jboss/tools/esb/visualizer/views/ESBVisualizerView.java 2012-01-27 11:34:16 UTC (rev 38243)
+++ workspace/bfitzpat/org.jboss.tools.esb.visualizer/src/org/jboss/tools/esb/visualizer/views/ESBVisualizerView.java 2012-01-27 15:52:45 UTC (rev 38244)
@@ -57,7 +57,7 @@
import org.eclipse.zest.layouts.constraints.BasicEntityConstraint;
import org.eclipse.zest.layouts.constraints.LayoutConstraint;
import org.jboss.tools.esb.visualizer.Activator;
-import org.jboss.tools.esb.visualizer.views.TreeObject.ESBType;
+import org.jboss.tools.esb.visualizer.views.ESBNode.ESBType;
/**
* This class serves as a simple read-only way to visualize an ESB configuration
@@ -178,7 +178,7 @@
ESBDomParser parser = new ESBDomParser();
parser.parseXmlFile(filepath);
clearGraph();
- TreeParent root = parser.getRoot();
+ ESBNodeWithChildren root = parser.getRoot();
root.setEsbObjectType(ESBType.ESB);
GraphNode rootnode = new GraphNode(gv.getGraphControl(),
ZestStyles.NODES_CACHE_LABEL,
@@ -218,10 +218,10 @@
* @param root
* @param parent
*/
- private void drawNodes ( GraphNode root, TreeParent parent ) {
+ private void drawNodes ( GraphNode root, ESBNodeWithChildren parent ) {
if (parent.hasChildren()) {
for (int i = 0; i < parent.getChildren().length; i++) {
- TreeParent tp = (TreeParent) parent.getChildren()[i];
+ ESBNodeWithChildren tp = (ESBNodeWithChildren) parent.getChildren()[i];
GraphNode p = new GraphNode(gv.getGraphControl(), SWT.NONE, tp.getName());
if (tp.getEsbObjectType() != null) {
switch (tp.getEsbObjectType()) {
@@ -267,8 +267,8 @@
Iterator<GraphNode> nodeIter = gv.getGraphControl().getGraphModel().getNodes().iterator();
while (nodeIter.hasNext()) {
GraphNode node = nodeIter.next();
- if (node.getData() != null && node.getData() instanceof TreeParent) {
- TreeParent tp = (TreeParent) node.getData();
+ if (node.getData() != null && node.getData() instanceof ESBNodeWithChildren) {
+ ESBNodeWithChildren tp = (ESBNodeWithChildren) node.getData();
if (tp.getRef() != null && tp.getRef().trim().length() > 0) {
GraphNode refNode = findNode(tp.getRef(), root);
if (refNode != null) {
@@ -499,8 +499,8 @@
GraphNode graphnode = (GraphNode) object;
Object data = graphnode.getData();
- if (data != null && data instanceof TreeObject) {
- boolean wasMoved = ((TreeObject)data).wasMoved();
+ if (data != null && data instanceof ESBNode) {
+ boolean wasMoved = ((ESBNode)data).wasMoved();
basicEntityConstraint.hasPreferredLocation = wasMoved;
}
}
@@ -519,8 +519,8 @@
Graph graph = ((GraphViewer) e.getSource()).getGraphControl();
if (!graph.getSelection().isEmpty()) {
GraphNode node = (GraphNode) graph.getSelection().get(0);
- if (node.getData() != null && node.getData() instanceof TreeObject) {
- TreeObject to = (TreeObject)node.getData();
+ if (node.getData() != null && node.getData() instanceof ESBNode) {
+ ESBNode to = (ESBNode)node.getData();
to.setWasMoved(!to.wasMoved());
if (to.wasMoved()) {
node.setBorderWidth(3);
@@ -580,8 +580,13 @@
Object first = ss.getFirstElement();
if (first instanceof IFile) {
String path = ((IFile)first).getLocation().toOSString();
- visualizeESB(path);
- return true;
+ ESBDomParser parser = new ESBDomParser();
+ if (parser.isFileESBConfig(path)) {
+ visualizeESB(path);
+ return true;
+ } else {
+ return false;
+ }
}
}
return false;
Deleted: workspace/bfitzpat/org.jboss.tools.esb.visualizer/src/org/jboss/tools/esb/visualizer/views/TreeObject.java
===================================================================
--- workspace/bfitzpat/org.jboss.tools.esb.visualizer/src/org/jboss/tools/esb/visualizer/views/TreeObject.java 2012-01-27 11:34:16 UTC (rev 38243)
+++ workspace/bfitzpat/org.jboss.tools.esb.visualizer/src/org/jboss/tools/esb/visualizer/views/TreeObject.java 2012-01-27 15:52:45 UTC (rev 38244)
@@ -1,74 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2012 Red Hat, Inc.
- * Distributed under license by Red Hat, Inc. All rights reserved.
- * This program is made available under the terms of the
- * Eclipse Public License v1.0 which accompanies this distribution,
- * and is available at http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Red Hat, Inc. - initial API and implementation
- ******************************************************************************/
-package org.jboss.tools.esb.visualizer.views;
-
-import org.eclipse.core.runtime.IAdaptable;
-
-public class TreeObject implements IAdaptable {
- private String name;
- private TreeParent parent;
- private String ref;
- private boolean wasMovedFlag = false;
- private ESBType esbObjectType;
- private Object data;
-
- public enum ESBType {
- ACTION, BUS, LISTENER, PROVIDER,
- ESB, PROPERTY, SERVICE
- }
-
- public TreeObject(String name) {
- this.name = name;
- }
- public String getName() {
- return name;
- }
- public void setName(String newName) {
- this.name = newName;
- }
- public void setParent(TreeParent parent) {
- this.parent = parent;
- }
- public TreeParent getParent() {
- return parent;
- }
- public String toString() {
- return getName();
- }
- @SuppressWarnings("rawtypes")
- public Object getAdapter(Class key) {
- return null;
- }
- public String getRef() {
- return ref;
- }
- public void setRef(String ref) {
- this.ref = ref;
- }
- protected boolean wasMoved() {
- return wasMovedFlag;
- }
- protected void setWasMoved(boolean wasMoved) {
- this.wasMovedFlag = wasMoved;
- }
- protected ESBType getEsbObjectType() {
- return esbObjectType;
- }
- protected void setEsbObjectType(ESBType esbObjectType) {
- this.esbObjectType = esbObjectType;
- }
- protected Object getData() {
- return data;
- }
- protected void setData(Object data) {
- this.data = data;
- }
-}
\ No newline at end of file
Deleted: workspace/bfitzpat/org.jboss.tools.esb.visualizer/src/org/jboss/tools/esb/visualizer/views/TreeParent.java
===================================================================
--- workspace/bfitzpat/org.jboss.tools.esb.visualizer/src/org/jboss/tools/esb/visualizer/views/TreeParent.java 2012-01-27 11:34:16 UTC (rev 38243)
+++ workspace/bfitzpat/org.jboss.tools.esb.visualizer/src/org/jboss/tools/esb/visualizer/views/TreeParent.java 2012-01-27 15:52:45 UTC (rev 38244)
@@ -1,36 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2012 Red Hat, Inc.
- * Distributed under license by Red Hat, Inc. All rights reserved.
- * This program is made available under the terms of the
- * Eclipse Public License v1.0 which accompanies this distribution,
- * and is available at http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Red Hat, Inc. - initial API and implementation
- ******************************************************************************/
-package org.jboss.tools.esb.visualizer.views;
-
-import java.util.ArrayList;
-
-public class TreeParent extends TreeObject {
-
- private ArrayList<TreeObject> children;
- public TreeParent(String name) {
- super(name);
- children = new ArrayList<TreeObject>();
- }
- public void addChild(TreeObject child) {
- children.add(child);
- child.setParent(this);
- }
- public void removeChild(TreeObject child) {
- children.remove(child);
- child.setParent(null);
- }
- public TreeObject [] getChildren() {
- return (TreeObject [])children.toArray(new TreeObject[children.size()]);
- }
- public boolean hasChildren() {
- return children.size()>0;
- }
-}
13 years, 11 months
JBoss Tools SVN: r38243 - trunk/openshift/plugins/org.jboss.tools.openshift.express.ui.
by jbosstools-commits@lists.jboss.org
Author: adietish
Date: 2012-01-27 06:34:16 -0500 (Fri, 27 Jan 2012)
New Revision: 38243
Modified:
trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/plugin.xml
Log:
[JBIDE-10735] shortened the labels for both new OpenShift wizards
Modified: trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/plugin.xml
===================================================================
--- trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/plugin.xml 2012-01-27 10:57:32 UTC (rev 38242)
+++ trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/plugin.xml 2012-01-27 11:34:16 UTC (rev 38243)
@@ -17,7 +17,7 @@
class="org.jboss.tools.openshift.express.internal.ui.wizard.CreateNewApplicationWizard"
icon="icons/openshift-logo-white-icon.png"
id="org.jboss.ide.eclipse.as.openshift.express.ui.wizard.createNewApplicationWizard"
- name="Create a new OpenShift Express Application">
+ name="OpenShift Express Application">
</wizard>
</extension>
<extension
@@ -31,7 +31,7 @@
class="org.jboss.tools.openshift.express.internal.ui.wizard.ImportExistingApplicationWizard"
icon="icons/openshift-logo-white-icon.png"
id="org.jboss.tools.openshift.express.ui.importExistingApplicationWizard"
- name="Import an existing OpenShift Express Application">
+ name="Existing OpenShift Express Application">
</wizard>
</extension>
<extension
13 years, 11 months
JBoss Tools SVN: r38242 - trunk/tests/plugins/org.jboss.tools.ui.bot.ext/src/org/jboss/tools/ui/bot/ext/view.
by jbosstools-commits@lists.jboss.org
Author: jjankovi
Date: 2012-01-27 05:57:32 -0500 (Fri, 27 Jan 2012)
New Revision: 38242
Modified:
trunk/tests/plugins/org.jboss.tools.ui.bot.ext/src/org/jboss/tools/ui/bot/ext/view/ViewBase.java
Log:
Changing modifier of Logger attributes to protected - to be used in subclasses as well
Modified: trunk/tests/plugins/org.jboss.tools.ui.bot.ext/src/org/jboss/tools/ui/bot/ext/view/ViewBase.java
===================================================================
--- trunk/tests/plugins/org.jboss.tools.ui.bot.ext/src/org/jboss/tools/ui/bot/ext/view/ViewBase.java 2012-01-27 10:53:47 UTC (rev 38241)
+++ trunk/tests/plugins/org.jboss.tools.ui.bot.ext/src/org/jboss/tools/ui/bot/ext/view/ViewBase.java 2012-01-27 10:57:32 UTC (rev 38242)
@@ -3,7 +3,6 @@
import org.apache.log4j.Logger;
import org.eclipse.swtbot.eclipse.finder.widgets.SWTBotView;
import org.eclipse.swtbot.swt.finder.SWTBot;
-import org.eclipse.swtbot.swt.finder.SWTBotTestCase;
import org.jboss.tools.ui.bot.ext.SWTBotExt;
import org.jboss.tools.ui.bot.ext.SWTOpenExt;
import org.jboss.tools.ui.bot.ext.SWTTestExt;
@@ -24,7 +23,7 @@
protected final SWTUtilExt util;
protected final SWTBotExt bot;
- Logger log = Logger.getLogger(ViewBase.class);
+ protected Logger log = Logger.getLogger(ViewBase.class);
public ViewBase() {
open = SWTTestExt.open;
13 years, 11 months
JBoss Tools SVN: r38241 - trunk/tests/plugins/org.jboss.tools.ui.bot.ext/src/org/jboss/tools/ui/bot/ext/gen.
by jbosstools-commits@lists.jboss.org
Author: jjankovi
Date: 2012-01-27 05:53:47 -0500 (Fri, 27 Jan 2012)
New Revision: 38241
Modified:
trunk/tests/plugins/org.jboss.tools.ui.bot.ext/src/org/jboss/tools/ui/bot/ext/gen/ActionItem.java
Log:
Annotation Properties view added
Modified: trunk/tests/plugins/org.jboss.tools.ui.bot.ext/src/org/jboss/tools/ui/bot/ext/gen/ActionItem.java
===================================================================
--- trunk/tests/plugins/org.jboss.tools.ui.bot.ext/src/org/jboss/tools/ui/bot/ext/gen/ActionItem.java 2012-01-27 10:18:06 UTC (rev 38240)
+++ trunk/tests/plugins/org.jboss.tools.ui.bot.ext/src/org/jboss/tools/ui/bot/ext/gen/ActionItem.java 2012-01-27 10:53:47 UTC (rev 38241)
@@ -142,6 +142,21 @@
}
};
}
+
+ public static class JAXWSAnnotationProperties {
+ /**
+ * represents item : JAX-WS->Annotation Properties
+ */
+ public static final IView LABEL = new IView() {
+ public String getName() { return "Annotation Properties";}
+ public List<String> getGroupPath() {
+ List<String> l = new Vector<String>();
+ l.add("JAX-WS");
+ return l;
+ }
+ };
+ }
+
public static class PluginDevelopmentPluginDependencies {
/**
* represents item : Plug-in Development->Plug-in Dependencies
13 years, 11 months
JBoss Tools SVN: r38240 - trunk/central/plugins/org.jboss.tools.central/src/org/jboss/tools/central/configurators.
by jbosstools-commits@lists.jboss.org
Author: adietish
Date: 2012-01-27 05:18:06 -0500 (Fri, 27 Jan 2012)
New Revision: 38240
Modified:
trunk/central/plugins/org.jboss.tools.central/src/org/jboss/tools/central/configurators/DefaultJBossCentralConfigurator.java
Log:
[JBIDE-10721] corrected the referenced OpenShift wizard id so that the new wizard shows up again.
Modified: trunk/central/plugins/org.jboss.tools.central/src/org/jboss/tools/central/configurators/DefaultJBossCentralConfigurator.java
===================================================================
--- trunk/central/plugins/org.jboss.tools.central/src/org/jboss/tools/central/configurators/DefaultJBossCentralConfigurator.java 2012-01-27 09:59:00 UTC (rev 38239)
+++ trunk/central/plugins/org.jboss.tools.central/src/org/jboss/tools/central/configurators/DefaultJBossCentralConfigurator.java 2012-01-27 10:18:06 UTC (rev 38240)
@@ -73,7 +73,7 @@
//wizardIds.add("org.jboss.tools.seam.ui.wizards.SeamProjectWizard");
//wizardIds.add("org.eclipse.m2e.core.wizards.Maven2ProjectWizard");
//wizardIds.add(JBossCentralActivator.NEW_PROJECT_EXAMPLES_WIZARD_ID);
- wizardIds.add("org.jboss.ide.eclipse.as.openshift.express.ui.wizard.ImportProjectNewWizard");
+ wizardIds.add("org.jboss.ide.eclipse.as.openshift.express.ui.wizard.createNewApplicationWizard");
return wizardIds;
}
13 years, 11 months
JBoss Tools SVN: r38239 - trunk/openshift/plugins/org.jboss.tools.openshift.express.client.
by jbosstools-commits@lists.jboss.org
Author: adietish
Date: 2012-01-27 04:59:00 -0500 (Fri, 27 Jan 2012)
New Revision: 38239
Modified:
trunk/openshift/plugins/org.jboss.tools.openshift.express.client/openshift-java-client-1.0.1-SNAPSHOT.jar
Log:
added latest client jar
Modified: trunk/openshift/plugins/org.jboss.tools.openshift.express.client/openshift-java-client-1.0.1-SNAPSHOT.jar
===================================================================
(Binary files differ)
13 years, 11 months
JBoss Tools SVN: r38238 - trunk/central/plugins/org.jboss.tools.central/icons.
by jbosstools-commits@lists.jboss.org
Author: fbricon
Date: 2012-01-27 04:19:25 -0500 (Fri, 27 Jan 2012)
New Revision: 38238
Modified:
trunk/central/plugins/org.jboss.tools.central/icons/spring_wiz.gif
Log:
JBIDE-10627 : add new spring wizard icon
Modified: trunk/central/plugins/org.jboss.tools.central/icons/spring_wiz.gif
===================================================================
(Binary files differ)
13 years, 11 months
JBoss Tools SVN: r38237 - trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/behaviour.
by jbosstools-commits@lists.jboss.org
Author: rob.stryker(a)jboss.com
Date: 2012-01-27 03:31:34 -0500 (Fri, 27 Jan 2012)
New Revision: 38237
Modified:
trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/behaviour/ExpressWizardFragment.java
Log:
JBIDE-10716 - small detail posting error if creds fail
Modified: trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/behaviour/ExpressWizardFragment.java
===================================================================
--- trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/behaviour/ExpressWizardFragment.java 2012-01-27 04:48:23 UTC (rev 38236)
+++ trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/behaviour/ExpressWizardFragment.java 2012-01-27 08:31:34 UTC (rev 38237)
@@ -221,8 +221,8 @@
} catch(OpenShiftException ose) {
error = "Application \"" + app + "\" not found: " + ose.getMessage();
}
- ExpressWizardFragment.this.error = error;
}
+ ExpressWizardFragment.this.error = error;
}
};
}
13 years, 11 months