| author | Rainer Pielmann | 2012-05-10 06:01:27 (EDT) |
|---|---|---|
| committer | Manik Kishore | 2012-05-16 00:56:14 (EDT) |
| commit | e5b949a89f29d1c1d44e7cb36ed20f52c6904416 (patch) (side-by-side diff) | |
| tree | 6690b78226b9dd7ea2e2ad383eb531f9f4a8c025 | |
| parent | 532dfc63c03fd61582518c85dee013722fbea405 (diff) | |
| download | org.eclipse.stardust.ide-e5b949a89f29d1c1d44e7cb36ed20f52c6904416.zip org.eclipse.stardust.ide-e5b949a89f29d1c1d44e7cb36ed20f52c6904416.tar.gz org.eclipse.stardust.ide-e5b949a89f29d1c1d44e7cb36ed20f52c6904416.tar.bz2 | |
Jira-ID: CRNT-24191
Test and debug configurations can't be created and run from property page of messaging applications
git-svn-id: http://emeafrazerg/svn/ipp/product/trunk/stardust/ide@56210 8100b5e0-4d52-466c-ae9c-bdeccbdeaf6b
| -rw-r--r-- | modeling/org.eclipse.stardust.modeling.transformation/src/org/eclipse/stardust/modeling/transformation/messaging/modeling/application/AbstractMessageProcessingPropertyPage.java | 25 |
1 files changed, 22 insertions, 3 deletions
diff --git a/modeling/org.eclipse.stardust.modeling.transformation/src/org/eclipse/stardust/modeling/transformation/messaging/modeling/application/AbstractMessageProcessingPropertyPage.java b/modeling/org.eclipse.stardust.modeling.transformation/src/org/eclipse/stardust/modeling/transformation/messaging/modeling/application/AbstractMessageProcessingPropertyPage.java index da2449e..494d715 100644 --- a/modeling/org.eclipse.stardust.modeling.transformation/src/org/eclipse/stardust/modeling/transformation/messaging/modeling/application/AbstractMessageProcessingPropertyPage.java +++ b/modeling/org.eclipse.stardust.modeling.transformation/src/org/eclipse/stardust/modeling/transformation/messaging/modeling/application/AbstractMessageProcessingPropertyPage.java @@ -157,12 +157,13 @@ public abstract class AbstractMessageProcessingPropertyPage { ILaunchManager lm = DebugPlugin.getDefault().getLaunchManager(); ILaunchConfigurationType ct = lm - .getLaunchConfigurationType("org.eclipse.stardust.modeling.transformation.messaging.modeling.application.launch.testType"); //$NON-NLS-1$ - + .getLaunchConfigurationType("org.eclipse.stardust.modeling.transformation.application.launch.testType"); //$NON-NLS-1$ try { ILaunchConfiguration[] cfgs = lm.getLaunchConfigurations(ct); - testConfigurationsComboViewer.setInput(cfgs); + testConfigurationsComboViewer.setInput(cfgs); + int selectionIndex = findConfigurationIndex(cfgs); + testConfigurationsComboViewer.getCombo().select(selectionIndex); } catch (CoreException e) { @@ -171,6 +172,24 @@ public abstract class AbstractMessageProcessingPropertyPage } } + private int findConfigurationIndex(ILaunchConfiguration[] cfgs) + { + String configValue = AttributeUtil.getAttributeValue( + (IExtensibleElement) getModelElement(), Constants.TEST_CONFIGURATION); + if (configValue != null) + { + for (int i = 0; i < cfgs.length; i++) + { + ILaunchConfiguration cfg = cfgs[i]; + if (cfg.getName().startsWith(configValue)) + { + return i; + } + } + } + return -1; + } + protected void loadMessageFormat(IModelElement element) { AttributeUtil.setAttribute((IExtensibleElement) element, |

