Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
Diffstat (limited to 'debug/org.eclipse.cdt.debug.core/src')
-rw-r--r--debug/org.eclipse.cdt.debug.core/src/org/eclipse/cdt/debug/core/CDebugCorePlugin.java13
-rw-r--r--debug/org.eclipse.cdt.debug.core/src/org/eclipse/cdt/debug/core/ICDTLaunchConfigurationConstants.java17
2 files changed, 30 insertions, 0 deletions
diff --git a/debug/org.eclipse.cdt.debug.core/src/org/eclipse/cdt/debug/core/CDebugCorePlugin.java b/debug/org.eclipse.cdt.debug.core/src/org/eclipse/cdt/debug/core/CDebugCorePlugin.java
index 784705a0918..6c06293348d 100644
--- a/debug/org.eclipse.cdt.debug.core/src/org/eclipse/cdt/debug/core/CDebugCorePlugin.java
+++ b/debug/org.eclipse.cdt.debug.core/src/org/eclipse/cdt/debug/core/CDebugCorePlugin.java
@@ -455,6 +455,19 @@ public class CDebugCorePlugin extends Plugin {
}
} catch (CoreException e) {}
+ ILaunchConfigurationType remoteCfg = launchMgr.getLaunchConfigurationType(ICDTLaunchConfigurationConstants.ID_LAUNCH_C_REMOTE_APP);
+ try {
+ if (remoteCfg.getPreferredDelegate(debugSet) == null) {
+ ILaunchDelegate[] delegates = remoteCfg.getDelegates(debugSet);
+ for (ILaunchDelegate delegate : delegates) {
+ if (ICDTLaunchConfigurationConstants.PREFERRED_DEBUG_REMOTE_LAUNCH_DELEGATE.equals(delegate.getId())) {
+ remoteCfg.setPreferredDelegate(debugSet, delegate);
+ break;
+ }
+ }
+ }
+ } catch (CoreException e) {}
+
ILaunchConfigurationType attachCfg = launchMgr.getLaunchConfigurationType(ICDTLaunchConfigurationConstants.ID_LAUNCH_C_ATTACH);
try {
if (attachCfg.getPreferredDelegate(debugSet) == null) {
diff --git a/debug/org.eclipse.cdt.debug.core/src/org/eclipse/cdt/debug/core/ICDTLaunchConfigurationConstants.java b/debug/org.eclipse.cdt.debug.core/src/org/eclipse/cdt/debug/core/ICDTLaunchConfigurationConstants.java
index 03013750f45..e26776c9b01 100644
--- a/debug/org.eclipse.cdt.debug.core/src/org/eclipse/cdt/debug/core/ICDTLaunchConfigurationConstants.java
+++ b/debug/org.eclipse.cdt.debug.core/src/org/eclipse/cdt/debug/core/ICDTLaunchConfigurationConstants.java
@@ -28,6 +28,13 @@ public interface ICDTLaunchConfigurationConstants {
public static final String ID_LAUNCH_C_APP = "org.eclipse.cdt.launch.applicationLaunchType"; //$NON-NLS-1$
/**
+ * This is the remote application launch type id.
+ *
+ * @since 7.1
+ */
+ public static final String ID_LAUNCH_C_REMOTE_APP = "org.eclipse.cdt.launch.remoteApplicationLaunchType"; //$NON-NLS-1$
+
+ /**
* This is the attach launch type id.
*
* @since 6.0
@@ -48,6 +55,16 @@ public interface ICDTLaunchConfigurationConstants {
public static final String PREFERRED_DEBUG_LOCAL_LAUNCH_DELEGATE = "org.eclipse.cdt.dsf.gdb.launch.localCLaunch"; //$NON-NLS-1$
/**
+ * Specifies the default launch delegate for a Remote Debug session.
+ * This default is part of the optional plugin org.eclipse.cdt.launch.remote. If that plugin is not installed
+ * then we won't set a default, which is ok since we only have one other delegate
+ * (which is org.eclipse.cdt.dsf.gdb.launch.remoteCLaunch).
+ * @since 7.1
+ */
+ public static final String PREFERRED_DEBUG_REMOTE_LAUNCH_DELEGATE = "org.eclipse.rse.remotecdt.dsf.debug"; //$NON-NLS-1$
+
+
+ /**
* Specifies the default launch delegate for an Attach Debug session
* @since 7.0
*/

Back to the top