JBoss Tools SVN: r29789 - in trunk/bpel/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui: dialogs and 1 other directory.
by jbosstools-commits@lists.jboss.org
Author: bbrodt
Date: 2011-03-15 09:37:14 -0400 (Tue, 15 Mar 2011)
New Revision: 29789
Modified:
trunk/bpel/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/details/providers/MessageTypeContentProvider.java
trunk/bpel/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/dialogs/TypeSelectorDialog.java
Log:
https://issues.jboss.org/browse/JBIDE-8075
add a Message selection filter to MessageContentProvider
Modified: trunk/bpel/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/details/providers/MessageTypeContentProvider.java
===================================================================
--- trunk/bpel/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/details/providers/MessageTypeContentProvider.java 2011-03-15 12:58:42 UTC (rev 29788)
+++ trunk/bpel/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/details/providers/MessageTypeContentProvider.java 2011-03-15 13:37:14 UTC (rev 29789)
@@ -21,15 +21,24 @@
*/
public class MessageTypeContentProvider extends AbstractContentProvider {
+ // https://issues.jboss.org/browse/JBIDE-8075
+ // provide a filter for enabling/disabling selection of Messages
+ private boolean showMessages = true;
+
@Override
public void collectElements ( Object input, List list) {
- if (input instanceof Definition) {
- list.addAll( ((Definition)input).getEMessages() );
- return;
+ if (showMessages) {
+ if (input instanceof Definition) {
+ list.addAll( ((Definition)input).getEMessages() );
+ return;
+ }
+
+ collectComplex( input, list);
}
-
- collectComplex( input, list);
}
-
+
+ public void setFilter(int filter) {
+ showMessages = (filter!=0);
+ }
}
Modified: trunk/bpel/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/dialogs/TypeSelectorDialog.java
===================================================================
--- trunk/bpel/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/dialogs/TypeSelectorDialog.java 2011-03-15 12:58:42 UTC (rev 29788)
+++ trunk/bpel/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/dialogs/TypeSelectorDialog.java 2011-03-15 13:37:14 UTC (rev 29789)
@@ -134,7 +134,11 @@
showMessages = settings.getBoolean(SHOW_MESSAGES_KEY);
} catch (Exception ex) {
showMessages = false;
- }
+ }
+
+ // https://issues.jboss.org/browse/JBIDE-8075
+ // enable/disable selection of Message objects
+ messageTypeProvider.setFilter(showMessages?1:0);
}
@@ -198,6 +202,10 @@
case BID_MESSAGES :
showMessages = checked;
+ // https://issues.jboss.org/browse/JBIDE-8075
+ // enable/disable selection of Message objects
+ messageTypeProvider.setFilter(showMessages?1:0);
+ bRefresh = true;
break;
default :
13 years, 10 months
JBoss Tools SVN: r29788 - trunk/tests/plugins/org.jboss.tools.ui.bot.ext/src/org/jboss/tools/ui/bot/ext.
by jbosstools-commits@lists.jboss.org
Author: jpeterka
Date: 2011-03-15 08:58:42 -0400 (Tue, 15 Mar 2011)
New Revision: 29788
Added:
trunk/tests/plugins/org.jboss.tools.ui.bot.ext/src/org/jboss/tools/ui/bot/ext/SWTBotFactory.java
Log:
swtbotext: SWTBotFactory added
Added: trunk/tests/plugins/org.jboss.tools.ui.bot.ext/src/org/jboss/tools/ui/bot/ext/SWTBotFactory.java
===================================================================
--- trunk/tests/plugins/org.jboss.tools.ui.bot.ext/src/org/jboss/tools/ui/bot/ext/SWTBotFactory.java (rev 0)
+++ trunk/tests/plugins/org.jboss.tools.ui.bot.ext/src/org/jboss/tools/ui/bot/ext/SWTBotFactory.java 2011-03-15 12:58:42 UTC (rev 29788)
@@ -0,0 +1,69 @@
+package org.jboss.tools.ui.bot.ext;
+
+import org.jboss.tools.ui.bot.ext.view.ConsoleView;
+import org.jboss.tools.ui.bot.ext.view.PackageExplorer;
+import org.jboss.tools.ui.bot.ext.view.ProblemsView;
+import org.jboss.tools.ui.bot.ext.view.ProjectExplorer;
+import org.jboss.tools.ui.bot.ext.view.ServersView;
+
+/**
+ * Provide factory for bot extensions, bot views and other parts. If needed
+ * getter methods can be re-implemented to avoid specific bot issues
+ *
+ * @author jpeterka
+ *
+ */
+public class SWTBotFactory {
+ protected static final SWTBotExt bot = new SWTBotExt();
+ protected static final SWTEclipseExt eclipse = new SWTEclipseExt(bot);
+ protected static final SWTUtilExt util = new SWTUtilExt(bot);
+ protected static final SWTOpenExt open = new SWTOpenExt(bot);
+ protected static final SWTJBTExt jbt = new SWTJBTExt(bot);
+
+ // Views
+ protected static final PackageExplorer packageExplorer = new PackageExplorer();
+ protected static final ProjectExplorer projectExplorer = new ProjectExplorer();
+ protected static final ServersView servers = new ServersView();
+ protected static final ProblemsView problems = new ProblemsView();
+ protected static final ConsoleView console = new ConsoleView();
+
+ public static SWTBotExt getBot() {
+ return bot;
+ }
+
+ public static SWTEclipseExt getEclipse() {
+ return eclipse;
+ }
+
+ public static SWTUtilExt getUtil() {
+ return util;
+ }
+
+ public static SWTOpenExt getOpen() {
+ return open;
+ }
+
+ public static SWTJBTExt getJbt() {
+ return jbt;
+ }
+
+ public static PackageExplorer getPackageexplorer() {
+ return packageExplorer;
+ }
+
+ public static ProjectExplorer getProjectexplorer() {
+ return projectExplorer;
+ }
+
+ public static ServersView getServers() {
+ return servers;
+ }
+
+ public static ProblemsView getProblems() {
+ return problems;
+ }
+
+ public static ConsoleView getConsole() {
+ return console;
+ }
+}
Property changes on: trunk/tests/plugins/org.jboss.tools.ui.bot.ext/src/org/jboss/tools/ui/bot/ext/SWTBotFactory.java
___________________________________________________________________
Added: svn:mime-type
+ text/plain
13 years, 10 months
JBoss Tools SVN: r29787 - trunk/tests/plugins/org.jboss.tools.ui.bot.ext/src/org/jboss/tools/ui/bot/ext/config.
by jbosstools-commits@lists.jboss.org
Author: jpeterka
Date: 2011-03-15 08:55:49 -0400 (Tue, 15 Mar 2011)
New Revision: 29787
Modified:
trunk/tests/plugins/org.jboss.tools.ui.bot.ext/src/org/jboss/tools/ui/bot/ext/config/DBBean.java
Log:
swtbot: dbbean can return proper internal/external driver name
Modified: trunk/tests/plugins/org.jboss.tools.ui.bot.ext/src/org/jboss/tools/ui/bot/ext/config/DBBean.java
===================================================================
--- trunk/tests/plugins/org.jboss.tools.ui.bot.ext/src/org/jboss/tools/ui/bot/ext/config/DBBean.java 2011-03-15 12:54:45 UTC (rev 29786)
+++ trunk/tests/plugins/org.jboss.tools.ui.bot.ext/src/org/jboss/tools/ui/bot/ext/config/DBBean.java 2011-03-15 12:55:49 UTC (rev 29787)
@@ -114,5 +114,19 @@
throw new IllegalArgumentException("Can't get DB type");
}
+ /**
+ * Returns appropriate JDBC driver name
+ * @return jar driver name or hsqldb if internal
+ */
+ public String getDriverName() {
+ if (internal) {
+ return "hsqldb.jar";
+ }
+ else {
+ String[] all = driverPath.split(File.separator);
+ return all[all.length -1];
+ }
+ }
+
}
\ No newline at end of file
13 years, 10 months
JBoss Tools SVN: r29786 - trunk/tests/plugins/org.jboss.tools.ui.bot.ext/src/org/jboss/tools/ui/bot/ext/helper.
by jbosstools-commits@lists.jboss.org
Author: jpeterka
Date: 2011-03-15 08:54:45 -0400 (Tue, 15 Mar 2011)
New Revision: 29786
Modified:
trunk/tests/plugins/org.jboss.tools.ui.bot.ext/src/org/jboss/tools/ui/bot/ext/helper/DatabaseHelper.java
Log:
botext: database helper titles fixed
Modified: trunk/tests/plugins/org.jboss.tools.ui.bot.ext/src/org/jboss/tools/ui/bot/ext/helper/DatabaseHelper.java
===================================================================
--- trunk/tests/plugins/org.jboss.tools.ui.bot.ext/src/org/jboss/tools/ui/bot/ext/helper/DatabaseHelper.java 2011-03-15 12:45:31 UTC (rev 29785)
+++ trunk/tests/plugins/org.jboss.tools.ui.bot.ext/src/org/jboss/tools/ui/bot/ext/helper/DatabaseHelper.java 2011-03-15 12:54:45 UTC (rev 29786)
@@ -264,7 +264,7 @@
ret = "MySQL_5.0";
break;
case mysql51:
- ret = "MySQL_5.1";
+ ret = "MySql_5.1";
break;
case oracle10g:
ret = "Oracle_10";
@@ -316,7 +316,7 @@
ret = "MySQL_5.0";
break;
case mysql51:
- ret = "MySQL 5";
+ ret = "MySQL";
break;
case oracle10g:
ret = "Oracle_10";
13 years, 10 months
JBoss Tools SVN: r29785 - trunk/tests/plugins/org.jboss.tools.ui.bot.ext/src/org/jboss/tools/ui/bot/ext/helper.
by jbosstools-commits@lists.jboss.org
Author: jpeterka
Date: 2011-03-15 08:45:31 -0400 (Tue, 15 Mar 2011)
New Revision: 29785
Modified:
trunk/tests/plugins/org.jboss.tools.ui.bot.ext/src/org/jboss/tools/ui/bot/ext/helper/UserLibraryHelper.java
Log:
swtbotext: added method for adding user library to a project
Modified: trunk/tests/plugins/org.jboss.tools.ui.bot.ext/src/org/jboss/tools/ui/bot/ext/helper/UserLibraryHelper.java
===================================================================
--- trunk/tests/plugins/org.jboss.tools.ui.bot.ext/src/org/jboss/tools/ui/bot/ext/helper/UserLibraryHelper.java 2011-03-15 10:58:31 UTC (rev 29784)
+++ trunk/tests/plugins/org.jboss.tools.ui.bot.ext/src/org/jboss/tools/ui/bot/ext/helper/UserLibraryHelper.java 2011-03-15 12:45:31 UTC (rev 29785)
@@ -23,6 +23,14 @@
import org.eclipse.jdt.core.IClasspathContainer;
import org.eclipse.jdt.core.IClasspathEntry;
import org.eclipse.jdt.core.JavaCore;
+import org.jboss.tools.ui.bot.ext.SWTBotExt;
+import org.jboss.tools.ui.bot.ext.SWTEclipseExt;
+import org.jboss.tools.ui.bot.ext.SWTOpenExt;
+import org.jboss.tools.ui.bot.ext.SWTUtilExt;
+import org.jboss.tools.ui.bot.ext.gen.ActionItem;
+import org.jboss.tools.ui.bot.ext.types.IDELabel;
+import org.jboss.tools.ui.bot.ext.view.PackageExplorer;
+import org.junit.Assert;
/**
* Helper for adding User Libraries (avoiding native dialogs)
@@ -101,4 +109,39 @@
log.error(e.getMessage());
}
}
+
+ /**
+ * Add user library to project
+ * @param libName user library name
+ * @param projectName project name
+ */
+ public static void addUserLibraryToProject(String libName,
+ String projectName) {
+
+ SWTBotExt bot = new SWTBotExt();
+ SWTOpenExt open = new SWTOpenExt(bot);
+ SWTEclipseExt eclipse = new SWTEclipseExt();
+ PackageExplorer projectExplorer = new PackageExplorer();
+
+ // Open Project Properties
+ open.viewOpen(ActionItem.View.JavaPackageExplorer.LABEL);
+ projectExplorer.selectProject(projectName);
+ Assert.assertTrue(eclipse.isProjectInPackageExplorer(projectName));
+ SWTUtilExt util = new SWTUtilExt(bot);
+ util.waitForNonIgnoredJobs();
+ ContextMenuHelper.clickContextMenu(projectExplorer.bot().tree(),
+ "Properties");
+
+ // Add Library
+ eclipse.waitForShell("Properties for " + projectName);
+ bot.tree().expandNode("Java Build Path").select();
+ bot.tabItem("Libraries").activate();
+ bot.button("Add Library...").click();
+ bot.list().select("User Library");
+ bot.clickButton(IDELabel.Button.NEXT);
+ bot.table().getTableItem(libName).check();
+ bot.clickButton(IDELabel.Button.FINISH);
+ bot.clickButton(IDELabel.Button.OK);
+
+ }
}
13 years, 10 months
JBoss Tools SVN: r29784 - trunk/vpe/plugins/org.jboss.tools.vpe.base.test/src/org/jboss/tools/vpe/base/test.
by jbosstools-commits@lists.jboss.org
Author: mareshkau
Date: 2011-03-15 06:58:31 -0400 (Tue, 15 Mar 2011)
New Revision: 29784
Modified:
trunk/vpe/plugins/org.jboss.tools.vpe.base.test/src/org/jboss/tools/vpe/base/test/VpeTestSetup.java
Log:
https://issues.jboss.org/browse/JBIDE-5820, https://jira.jboss.org/jira/browse/JBIDE-5821
we have moved to new wtp version, -> removed not relevant code
Modified: trunk/vpe/plugins/org.jboss.tools.vpe.base.test/src/org/jboss/tools/vpe/base/test/VpeTestSetup.java
===================================================================
--- trunk/vpe/plugins/org.jboss.tools.vpe.base.test/src/org/jboss/tools/vpe/base/test/VpeTestSetup.java 2011-03-15 10:46:16 UTC (rev 29783)
+++ trunk/vpe/plugins/org.jboss.tools.vpe.base.test/src/org/jboss/tools/vpe/base/test/VpeTestSetup.java 2011-03-15 10:58:31 UTC (rev 29784)
@@ -10,10 +10,6 @@
******************************************************************************/
package org.jboss.tools.vpe.base.test;
-import org.eclipse.ui.IViewReference;
-import org.eclipse.ui.PlatformUI;
-//import org.jboss.tools.vpe.ui.test.ProjectsLoader;
-
import junit.extensions.TestSetup;
import junit.framework.TestSuite;
@@ -25,7 +21,7 @@
*
*/
public class VpeTestSetup extends TestSetup {
- private static final String CONTENT_OUTLINE_VIEW_ID = "org.eclipse.ui.views.ContentOutline";
+
public VpeTestSetup(TestSuite test) {
super(test);
@@ -36,14 +32,6 @@
*/
@Override
protected void setUp() throws Exception {
- //added by Maksim Areshkau, Fix for https://jira.jboss.org/jira/browse/JBIDE-5820 https://jira.jboss.org/jira/browse/JBIDE-5821
- //remove this code when we will move on wtp 3.2
- IViewReference[] iviewReferences= PlatformUI.getWorkbench().getActiveWorkbenchWindow().getActivePage().getViewReferences();
- for (IViewReference iViewReference : iviewReferences) {
- if(VpeTestSetup.CONTENT_OUTLINE_VIEW_ID.equalsIgnoreCase(iViewReference.getId())){
- PlatformUI.getWorkbench().getActiveWorkbenchWindow().getActivePage().hideView(iViewReference);
- }
- }
}
/* (non-Javadoc)
13 years, 10 months
JBoss Tools SVN: r29783 - trunk/jsf/tests/org.jboss.tools.jsf.vpe.jsf.test/src/org/jboss/tools/jsf/vpe/jsf/test.
by jbosstools-commits@lists.jboss.org
Author: mareshkau
Date: 2011-03-15 06:46:16 -0400 (Tue, 15 Mar 2011)
New Revision: 29783
Modified:
trunk/jsf/tests/org.jboss.tools.jsf.vpe.jsf.test/src/org/jboss/tools/jsf/vpe/jsf/test/JsfAllTests.java
Log:
https://issues.jboss.org/browse/JBIDE-8488, removing unuseful procedure calling
Modified: trunk/jsf/tests/org.jboss.tools.jsf.vpe.jsf.test/src/org/jboss/tools/jsf/vpe/jsf/test/JsfAllTests.java
===================================================================
--- trunk/jsf/tests/org.jboss.tools.jsf.vpe.jsf.test/src/org/jboss/tools/jsf/vpe/jsf/test/JsfAllTests.java 2011-03-15 09:09:27 UTC (rev 29782)
+++ trunk/jsf/tests/org.jboss.tools.jsf.vpe.jsf.test/src/org/jboss/tools/jsf/vpe/jsf/test/JsfAllTests.java 2011-03-15 10:46:16 UTC (rev 29783)
@@ -13,7 +13,6 @@
import junit.framework.Test;
import junit.framework.TestSuite;
-import org.eclipse.jst.jsp.core.internal.java.search.JSPIndexManager;
import org.jboss.tools.jsf.vpe.jsf.test.jbide.ChangeMessageBundleTest_JBIDE5818;
import org.jboss.tools.jsf.vpe.jsf.test.jbide.ContextMenuDoubleInsertionTest_JBIDE3888;
import org.jboss.tools.jsf.vpe.jsf.test.jbide.EditFontFamilyTest_JBIDE5872;
@@ -94,9 +93,9 @@
import org.jboss.tools.jsf.vpe.jsf.test.jbide.SourceDomUtilTest;
import org.jboss.tools.jsf.vpe.jsf.test.jbide.TestContextPathResolution;
import org.jboss.tools.jsf.vpe.jsf.test.jbide.TestFViewLocaleAttribute_JBIDE5218;
-import org.jboss.tools.jsf.vpe.jsf.test.jbide.UnclosedELExpressionTest;
import org.jboss.tools.jsf.vpe.jsf.test.jbide.TestForUsingComponentsLibrariesWithDefaultNamespace;
import org.jboss.tools.jsf.vpe.jsf.test.jbide.TestOpenOnForXhtmlFiles_JBIDE5577;
+import org.jboss.tools.jsf.vpe.jsf.test.jbide.UnclosedELExpressionTest;
import org.jboss.tools.jsf.vpe.jsf.test.jbide.VPERefreshTest;
import org.jboss.tools.jsf.vpe.jsf.test.jbide.VisualRefreshComment_JBIDE6067;
import org.jboss.tools.jsf.vpe.jsf.test.jbide.VpeI18nTest_JBIDE4887;
@@ -123,8 +122,7 @@
public static final String IMPORT_TEST_WITH_2_URL_PATTERNS_PROJECT_NAME = "TestWith2URLPatterns"; //$NON-NLS-1$
public static Test suite() {
-// FIXME https://issues.jboss.org/browse/JBIDE-8488
-// JSPIndexManager.getInstance().shutdown();
+
TestSuite suite = new TestSuite("Tests for Vpe Jsf components"); //$NON-NLS-1$
// $JUnit-BEGIN$
/*
13 years, 10 months
JBoss Tools SVN: r29782 - branches/jbosstools-3.2.x/deltacloud/plugins/org.jboss.tools.deltacloud.ui/src/org/jboss/tools/deltacloud/ui/views/cloudelements.
by jbosstools-commits@lists.jboss.org
Author: adietish
Date: 2011-03-15 05:09:27 -0400 (Tue, 15 Mar 2011)
New Revision: 29782
Modified:
branches/jbosstools-3.2.x/deltacloud/plugins/org.jboss.tools.deltacloud.ui/src/org/jboss/tools/deltacloud/ui/views/cloudelements/AbstractCloudElementTableView.java
Log:
[JBIDE-7862]
Modified: branches/jbosstools-3.2.x/deltacloud/plugins/org.jboss.tools.deltacloud.ui/src/org/jboss/tools/deltacloud/ui/views/cloudelements/AbstractCloudElementTableView.java
===================================================================
--- branches/jbosstools-3.2.x/deltacloud/plugins/org.jboss.tools.deltacloud.ui/src/org/jboss/tools/deltacloud/ui/views/cloudelements/AbstractCloudElementTableView.java 2011-03-15 08:53:22 UTC (rev 29781)
+++ branches/jbosstools-3.2.x/deltacloud/plugins/org.jboss.tools.deltacloud.ui/src/org/jboss/tools/deltacloud/ui/views/cloudelements/AbstractCloudElementTableView.java 2011-03-15 09:09:27 UTC (rev 29782)
@@ -13,6 +13,7 @@
import java.beans.PropertyChangeEvent;
import java.beans.PropertyChangeListener;
import java.util.ArrayList;
+import java.util.Arrays;
import java.util.List;
import org.eclipse.core.runtime.IAdaptable;
@@ -241,7 +242,7 @@
}
protected abstract ITableContentAndLabelProvider<CLOUDELEMENT> getContentAndLabelProvider();
-
+
private void setViewerInput(DeltaCloud cloud) {
viewer.setInput(cloud);
}
@@ -306,9 +307,10 @@
return clouds[cloudIndex];
}
- private void createColumns(ITableContentAndLabelProvider<CLOUDELEMENT> provider, TableColumnLayout tableLayout, Table table) {
+ private void createColumns(ITableContentAndLabelProvider<CLOUDELEMENT> provider, TableColumnLayout tableLayout,
+ Table table) {
Columns<CLOUDELEMENT> columns = provider.getColumns();
-
+
for (int i = 0; i < columns.getSize(); ++i) {
Column<CLOUDELEMENT> c = columns.getColumn(i);
TableColumn tc = new TableColumn(table, SWT.NONE);
@@ -364,43 +366,59 @@
DeltaCloud[] clouds = getClouds();
final int index = getCloudIndex(cloud, clouds);
Display.getDefault().syncExec(new Runnable() {
-
+
@Override
public void run() {
if (index >= 0) {
int selectionIndex = currentCloudSelector.getSelectionIndex();
currentCloudSelector.removeModifyListener(currentCloudModifyListener);
- currentCloudSelector.setItem(index, cloud.getName());
+ /*
+ * @see [JBIDE-7862]
+ * setting all items seems necessary so that the combo uses the space needed to display the largest cloud name.
+ * If you just replace the item that was renamed, the combo will not shrink (it would only get larger if needed).
+ */
+ currentCloudSelector.setItems(getSelectorItems(cloud, index));
currentCloudSelector.select(selectionIndex);
currentCloudSelector.addModifyListener(currentCloudModifyListener);
}
container.layout(true, true);
-
}
+
+ private String[] getSelectorItems(final DeltaCloud cloud, final int index) {
+ List<String> names = new ArrayList<String>(Arrays.asList(currentCloudSelector.getItems()));
+ names.set(index, cloud.getName());
+ return names.toArray(new String[names.size()]);
+ }
});
}
- public void cloudsChanged(int type, DeltaCloud cloud) {
- DeltaCloud[] clouds = getClouds();
- switch (type) {
- case IDeltaCloudManagerListener.REMOVE_EVENT:
- onCloudRemoved(cloud, clouds);
- break;
- default:
- }
-
- int index = getCloudIndex(currentCloud, clouds);
- String[] cloudNames = toCloudNames(clouds);
- setCloudSelectorItems(cloudNames, currentCloudSelector);
+ public void cloudsChanged(final int type, final DeltaCloud cloud) {
+ viewer.getControl().getDisplay().syncExec(new Runnable() {
- if (cloudNames.length > 0) {
- currentCloudSelector.setText(cloudNames[index]);
- setViewerInput(currentCloud);
- } else {
- currentCloudSelector.setText("");
- setViewerInput(null);
+ @Override
+ public void run() {
+ DeltaCloud[] clouds = getClouds();
+ switch (type) {
+ case IDeltaCloudManagerListener.REMOVE_EVENT:
+ onCloudRemoved(cloud, clouds);
+ break;
+ default:
+ }
+
+ int index = getCloudIndex(currentCloud, clouds);
+ String[] cloudNames = toCloudNames(clouds);
+ setCloudSelectorItems(cloudNames, currentCloudSelector);
+
+ if (cloudNames.length > 0) {
+ currentCloudSelector.setText(cloudNames[index]);
+ setViewerInput(currentCloud);
+ } else {
+ currentCloudSelector.setText("");
+ setViewerInput(null);
+ }
+ container.layout(true, true);
}
- container.layout(true, true);
+ });
}
private void onCloudRemoved(DeltaCloud cloud, DeltaCloud[] clouds) {
13 years, 10 months
JBoss Tools SVN: r29781 - in trunk/deltacloud/plugins/org.jboss.tools.deltacloud.ui/src/org/jboss/tools/deltacloud/ui: views and 1 other directory.
by jbosstools-commits@lists.jboss.org
Author: adietish
Date: 2011-03-15 04:53:22 -0400 (Tue, 15 Mar 2011)
New Revision: 29781
Modified:
trunk/deltacloud/plugins/org.jboss.tools.deltacloud.ui/src/org/jboss/tools/deltacloud/ui/commands/StopInstanceHandler.java
trunk/deltacloud/plugins/org.jboss.tools.deltacloud.ui/src/org/jboss/tools/deltacloud/ui/views/CVMessages.properties
Log:
[JBIDE-8295] externalized confirmation dialog strings
Modified: trunk/deltacloud/plugins/org.jboss.tools.deltacloud.ui/src/org/jboss/tools/deltacloud/ui/commands/StopInstanceHandler.java
===================================================================
--- trunk/deltacloud/plugins/org.jboss.tools.deltacloud.ui/src/org/jboss/tools/deltacloud/ui/commands/StopInstanceHandler.java 2011-03-15 08:18:25 UTC (rev 29780)
+++ trunk/deltacloud/plugins/org.jboss.tools.deltacloud.ui/src/org/jboss/tools/deltacloud/ui/commands/StopInstanceHandler.java 2011-03-15 08:53:22 UTC (rev 29781)
@@ -91,7 +91,7 @@
private void stopInstances(Object[] deltaCloudInstances) {
if (askUserToConfirm()) {
for (int i = 0; i < deltaCloudInstances.length; i++) {
- stopInstance((DeltaCloudInstance) deltaCloudInstances[i]);
+ doStopInstance((DeltaCloudInstance) deltaCloudInstances[i]);
}
}
}
@@ -118,9 +118,9 @@
private boolean askUserToConfirm() {
return UIUtils
.openConfirmationDialog(
- "Confirm instance stop",
- "You are about to stop a running system(s), that might be in production. Are you sure that you want to stop the given instance(s)?",
- "Don't warn me again",
+ CVMessages.getString("StopInstancesConfirm.title"),
+ CVMessages.getString("StopInstancesConfirm.msg"),
+ CVMessages.getString("StopInstancesConfirmDontWarn.msg"),
IDeltaCloudPreferenceConstants.DONT_CONFIRM_CREATE_INSTANCE,
Activator.PLUGIN_ID,
WorkbenchUtils.getActiveShell());
Modified: trunk/deltacloud/plugins/org.jboss.tools.deltacloud.ui/src/org/jboss/tools/deltacloud/ui/views/CVMessages.properties
===================================================================
--- trunk/deltacloud/plugins/org.jboss.tools.deltacloud.ui/src/org/jboss/tools/deltacloud/ui/views/CVMessages.properties 2011-03-15 08:18:25 UTC (rev 29780)
+++ trunk/deltacloud/plugins/org.jboss.tools.deltacloud.ui/src/org/jboss/tools/deltacloud/ui/views/CVMessages.properties 2011-03-15 08:53:22 UTC (rev 29781)
@@ -58,6 +58,9 @@
StopInstancesDialog.msg=Please choose the instances that shall be stopped by checking them:
StopInstancesDialogError.title=Error while stopping instance(s)
StopInstancesDialogError.msg=Could not stop instance(s) {0}
+StopInstancesConfirm.title=Confirm instance stop
+StopInstancesConfirm.msg=You are about to stop a running system(s), that might be in production. Are you sure that you want to stop the given instance(s)?
+StopInstancesConfirmDontWarn.msg=Don't warn me again
RebootingInstance.title=Rebooting Instance
RebootingInstance.msg=Rebooting Instance: {0}
RebootInstancesDialog.title=Reboot Instances
13 years, 10 months
JBoss Tools SVN: r29780 - in trunk/bpel/plugins/org.eclipse.bpel.apache.ode.runtime/src: org and 5 other directories.
by jbosstools-commits@lists.jboss.org
Author: Grid.Qian
Date: 2011-03-15 04:18:25 -0400 (Tue, 15 Mar 2011)
New Revision: 29780
Added:
trunk/bpel/plugins/org.eclipse.bpel.apache.ode.runtime/src/org/
trunk/bpel/plugins/org.eclipse.bpel.apache.ode.runtime/src/org/eclipse/
trunk/bpel/plugins/org.eclipse.bpel.apache.ode.runtime/src/org/eclipse/bpel/
trunk/bpel/plugins/org.eclipse.bpel.apache.ode.runtime/src/org/eclipse/bpel/apache/
trunk/bpel/plugins/org.eclipse.bpel.apache.ode.runtime/src/org/eclipse/bpel/apache/ode/
trunk/bpel/plugins/org.eclipse.bpel.apache.ode.runtime/src/org/eclipse/bpel/apache/ode/runtime/
trunk/bpel/plugins/org.eclipse.bpel.apache.ode.runtime/src/org/eclipse/bpel/apache/ode/runtime/GenericBPELPublisher.java
trunk/bpel/plugins/org.eclipse.bpel.apache.ode.runtime/src/org/eclipse/bpel/apache/ode/runtime/OdeBPELPublisher.java
trunk/bpel/plugins/org.eclipse.bpel.apache.ode.runtime/src/org/eclipse/bpel/apache/ode/runtime/OdePlugin.java
Log:
JBIDE-8366: revert misoperation(delete the src of org.eclipse.bpe.apache.ode.runtime)
Added: trunk/bpel/plugins/org.eclipse.bpel.apache.ode.runtime/src/org/eclipse/bpel/apache/ode/runtime/GenericBPELPublisher.java
===================================================================
--- trunk/bpel/plugins/org.eclipse.bpel.apache.ode.runtime/src/org/eclipse/bpel/apache/ode/runtime/GenericBPELPublisher.java (rev 0)
+++ trunk/bpel/plugins/org.eclipse.bpel.apache.ode.runtime/src/org/eclipse/bpel/apache/ode/runtime/GenericBPELPublisher.java 2011-03-15 08:18:25 UTC (rev 29780)
@@ -0,0 +1,135 @@
+/*******************************************************************************
+ * Copyright (c) 2006 University College London Software Systems Engineering
+ * All rights reserved. This program and the accompanying materials
+ * are 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:
+ * Bruno Wassermann - initial API and implementation
+ *******************************************************************************/
+package org.eclipse.bpel.apache.ode.runtime;
+
+import java.util.Iterator;
+
+import org.eclipse.core.resources.IFile;
+import org.eclipse.core.runtime.IPath;
+import org.eclipse.core.runtime.IProgressMonitor;
+import org.eclipse.jst.server.generic.core.internal.GenericPublisher;
+import org.eclipse.jst.server.generic.core.internal.GenericServer;
+import org.eclipse.jst.server.generic.servertype.definition.Port;
+import org.eclipse.wst.server.core.IModuleArtifact;
+
+/**
+ * An abstract base class offering some utility methods facilitating the process
+ * of deploying a BPEL process onto a runtime and indicating a publisher of
+ * BPEL processes. This extends the generic server
+ * framework. Implementers of the <code>genericpublishers</code> extension point
+ * wishing to publish BPEL processes onto some runtime, may find it convenient
+ * to sub-class this class.
+ * <p>
+ * The minimum requirement on sub-classes is to provide an implementation of
+ * <code>GenericPublisher{@link #publish(IModuleArtifact[], IProgressMonitor)}</code>,
+ * <code>GenericPublisher{@link #unpublish(IProgressMonitor)}</code> and of
+ * <code></code>
+ * <p>
+ * Clients should not instantiate this class or its sub-classes as they will be
+ * instantiated by the WTP server framework. Clients can make use of any
+ * convenience methods contained in this class (all methods defined directly
+ * on <code>GenericBPELPublisher</code>).
+ *
+ *
+ * @author Bruno Wassermann, written Jun 8, 2006
+ */
+public abstract class GenericBPELPublisher extends GenericPublisher {
+
+// TODO add utility methods that may be useful to concrete implementations
+
+ /**
+ * Displays engine-specific validation warnings and errors in the BPEL
+ * Designer.
+ * <p>
+ * Sub-classes can call this method to provide information
+ * about any problems detected during deployment.
+ */
+ protected final void submitValidationMarkers() {
+ // TODO decide on signature/arguments
+ }
+
+ /**
+ * Provides access to the relevant project in the workspace in order to
+ * store a local copy of a generated deployment archive
+ *
+ * @param deployArchive
+ * @param path should probably be relative from project root and if null
+ * will save archive in project root
+ */
+ protected void storeDeploymentArchive(IFile deployArchive, IPath path) {
+ // TODO figure out whether this is really useful
+ // TODO figure out the signature (should it be a file, what's the best
+ // way to allow specifying an additional path?) - maybe look at some
+ // of the methods in the WTP tutorial.
+ }
+
+ /**
+ * Returns the host part of the server on which module is to be published.
+ * For example, 'localhost'.
+ *
+ * @return <code>String</code> representing host part of server on which
+ * module is to be published. Will return <code>null</code>, if called
+ * before {@link GenericPublisher#initialize()} has been called.
+ */
+ protected String getHost() {
+ return getServer().getServer().getHost();
+ }
+
+ /**
+ * Returns http port defined for the server module is to be published on.
+ * <p>
+ * This replicates {@link GenericServer#getHttpPort()}.
+ *
+ * @return int
+ */
+ protected int getHttpPort() {
+ int port = -1;
+ Iterator pIter = getServer().getServerDefinition().getPort().iterator();
+
+ while (pIter.hasNext()) {
+ Port aPort = (Port) pIter.next();
+
+ if(port == -1) {
+ port = Integer.parseInt(getServer().getServerDefinition().getResolver().resolveProperties(aPort.getNo()));
+ }
+ else if( "http".equals(aPort.getProtocol() ) ) { //$NON-NLS-1$
+ port = Integer.parseInt(aPort.getNo());
+ }
+ }
+ if( port == -1) {
+ port = 8080;
+ }
+ return port;
+ }
+
+ /*
+ * we don't have something like validate in here as we are not the provider
+ * of an extension point, but simply providing some utility methods for
+ * sub-classes to use if they so wish.
+ *
+ * if we had provided our own extension point to do publishing, then
+ * we would probably have specified a validate() method in the abstract base
+ * class so that our framework could call its implementation in extensions.
+ *
+ * If it's just a utility method it should have static methods. Otherwise,
+ * allow it to be sub-classed and declare some methods as abstract to
+ * indicate to sub-classes what they need to implement.
+ *
+ * What is true though is that we cannot call such methods automatically as
+ * we are not really offering an extension point.
+ *
+ * TODO clarify explain this point about usage in the class comment! the methods
+ * will not be called automatically as we are not providing an extension
+ * point as initially expected.
+ */
+
+
+}
Property changes on: trunk/bpel/plugins/org.eclipse.bpel.apache.ode.runtime/src/org/eclipse/bpel/apache/ode/runtime/GenericBPELPublisher.java
___________________________________________________________________
Added: svn:mime-type
+ text/plain
Added: trunk/bpel/plugins/org.eclipse.bpel.apache.ode.runtime/src/org/eclipse/bpel/apache/ode/runtime/OdeBPELPublisher.java
===================================================================
--- trunk/bpel/plugins/org.eclipse.bpel.apache.ode.runtime/src/org/eclipse/bpel/apache/ode/runtime/OdeBPELPublisher.java (rev 0)
+++ trunk/bpel/plugins/org.eclipse.bpel.apache.ode.runtime/src/org/eclipse/bpel/apache/ode/runtime/OdeBPELPublisher.java 2011-03-15 08:18:25 UTC (rev 29780)
@@ -0,0 +1,95 @@
+package org.eclipse.bpel.apache.ode.runtime;
+
+/*******************************************************************************
+ * Copyright (c) 2008 IBM Corporation, University of Stuttgart (IAAS) and others.
+ * All rights reserved. This program and the accompanying materials
+ * are 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:
+ * IBM Corporation, University of Stuttgart (IAAS) - initial API and implementation
+ *******************************************************************************/
+
+import java.io.File;
+
+import org.eclipse.bpel.apache.ode.runtime.GenericBPELPublisher;
+import org.eclipse.core.runtime.CoreException;
+import org.eclipse.core.runtime.IPath;
+import org.eclipse.core.runtime.IProgressMonitor;
+import org.eclipse.core.runtime.IStatus;
+import org.eclipse.core.runtime.Status;
+import org.eclipse.core.runtime.NullProgressMonitor;
+import org.eclipse.jst.server.core.PublishUtil;
+import org.eclipse.wst.server.core.IModule;
+import org.eclipse.wst.server.core.IModuleArtifact;
+import org.eclipse.wst.server.core.IRuntime;
+import org.eclipse.wst.server.core.model.IModuleResource;
+import org.eclipse.wst.server.core.model.ModuleDelegate;
+
+/**
+ * BPEL publisher for Apache ODE.
+ *
+ * @author Tammo van Lessen (IAAS)
+ * @author Simon Moser (IBM)
+ */
+public class OdeBPELPublisher extends GenericBPELPublisher {
+
+ public OdeBPELPublisher() {
+ super();
+ }
+
+ @Override
+ public IStatus[] publish(IModuleArtifact[] artifacts, IProgressMonitor monitor) {
+ // resources will always be null for some weird reason :(
+ // therefore we generate a BPELModuleArtifact
+ // the module id value enables us to get BPEL file path relative to its project
+ IModule[] modules = super.getModule();
+
+ try {
+ IModule last = modules[modules.length-1];
+ IPath root = createDeploymentDestination(last);
+ ModuleDelegate delegate = (ModuleDelegate)last.loadAdapter(ModuleDelegate.class, new NullProgressMonitor());
+ IModuleResource[] resources = delegate.members();
+ PublishUtil.publishFull(resources, root, monitor);
+ } catch( CoreException ce ) {
+ // TODO return bad status
+ }
+ return new IStatus[]{Status.OK_STATUS};
+
+ }
+
+ @Override
+ public IStatus[] unpublish(IProgressMonitor monitor) {
+ IModule[] modules = super.getModule();
+ IModule last = modules[modules.length - 1];
+ IStatus[] result = new Status[modules.length];
+ IPath root = createDeploymentDestination(last);
+ PublishUtil.deleteDirectory(root.toFile(), monitor);
+ return result;
+ }
+
+ /**
+ * This method will create a folder inside the WEB-INF\processes subfolder
+ * of the ODE installation
+ */
+ protected IPath createDeploymentDestination(IModule module) {
+ String moduleName = module.getName();
+ String deployAppName = moduleName;
+
+ // get TOMCAT_HOME
+ IRuntime serverDef = getServerRuntime().getRuntime();
+ IPath tomcatHome = serverDef.getLocation();
+
+ // append ODE's Process target Dir tomcatHome
+ IPath deployTarget = tomcatHome.append("webapps").append("ode")
+ .append("WEB-INF").append("processes").append(deployAppName);
+
+ File f = deployTarget.toFile();
+ if (!f.exists()) {
+ f.mkdir();
+ }
+
+ return deployTarget;
+ }
+}
Property changes on: trunk/bpel/plugins/org.eclipse.bpel.apache.ode.runtime/src/org/eclipse/bpel/apache/ode/runtime/OdeBPELPublisher.java
___________________________________________________________________
Added: svn:mime-type
+ text/plain
Added: trunk/bpel/plugins/org.eclipse.bpel.apache.ode.runtime/src/org/eclipse/bpel/apache/ode/runtime/OdePlugin.java
===================================================================
--- trunk/bpel/plugins/org.eclipse.bpel.apache.ode.runtime/src/org/eclipse/bpel/apache/ode/runtime/OdePlugin.java (rev 0)
+++ trunk/bpel/plugins/org.eclipse.bpel.apache.ode.runtime/src/org/eclipse/bpel/apache/ode/runtime/OdePlugin.java 2011-03-15 08:18:25 UTC (rev 29780)
@@ -0,0 +1,41 @@
+package org.eclipse.bpel.apache.ode.runtime;
+
+/*******************************************************************************
+ * Copyright (c) 2008 IBM Corporation, University of Stuttgart (IAAS) and others.
+ * All rights reserved. This program and the accompanying materials
+ * are 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:
+ * IBM Corporation, University of Stuttgart (IAAS) - initial API and implementation
+ *******************************************************************************/
+
+
+import org.eclipse.ui.plugin.AbstractUIPlugin;
+import org.osgi.framework.BundleContext;
+
+/**
+ * Runtime contributor for Apache ODE.
+ *
+ * @author Tammo van Lessen (IAAS)
+ * @author Simon Moser (IBM)
+ */
+public class OdePlugin extends AbstractUIPlugin {
+ public static final String PLUGIN_ID = "org.eclipse.bpel.apache.ode.runtime";
+ private static OdePlugin plugin;
+
+ public void start(BundleContext context) throws Exception {
+ super.start(context);
+ }
+
+ public void stop(BundleContext context) throws Exception {
+ super.stop(context);
+ plugin = null;
+ }
+
+ public static OdePlugin getDefault() {
+ return plugin;
+ }
+
+}
Property changes on: trunk/bpel/plugins/org.eclipse.bpel.apache.ode.runtime/src/org/eclipse/bpel/apache/ode/runtime/OdePlugin.java
___________________________________________________________________
Added: svn:mime-type
+ text/plain
13 years, 10 months