Skip to main content
aboutsummaryrefslogtreecommitdiffstats
path: root/cross
diff options
context:
space:
mode:
Diffstat (limited to 'cross')
-rw-r--r--cross/org.eclipse.cdt.launch.remote/src/org/eclipse/cdt/launch/remote/tabs/RemoteCDSFMainTab.java11
-rw-r--r--cross/org.eclipse.cdt.launch.remote/src/org/eclipse/cdt/launch/remote/tabs/RemoteCMainTab.java13
2 files changed, 22 insertions, 2 deletions
diff --git a/cross/org.eclipse.cdt.launch.remote/src/org/eclipse/cdt/launch/remote/tabs/RemoteCDSFMainTab.java b/cross/org.eclipse.cdt.launch.remote/src/org/eclipse/cdt/launch/remote/tabs/RemoteCDSFMainTab.java
index 1765a40b4bb..1d26b14eb6d 100644
--- a/cross/org.eclipse.cdt.launch.remote/src/org/eclipse/cdt/launch/remote/tabs/RemoteCDSFMainTab.java
+++ b/cross/org.eclipse.cdt.launch.remote/src/org/eclipse/cdt/launch/remote/tabs/RemoteCDSFMainTab.java
@@ -1,5 +1,5 @@
/*******************************************************************************
- * Copyright (c) 2006, 2010 PalmSource, Inc. and others.
+ * Copyright (c) 2006, 2011 PalmSource, Inc. 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
@@ -86,6 +86,8 @@ public class RemoteCDSFMainTab extends CMainTab {
private Text preRunText;
private Label preRunLabel;
+ private boolean isInitializing = false;
+
public RemoteCDSFMainTab() {
super(CMainTab.INCLUDE_BUILD_SETTINGS);
}
@@ -519,6 +521,11 @@ public class RemoteCDSFMainTab extends CMainTab {
}
private void useDefaultsFromConnection() {
+ // During initialization, we don't want to use the default
+ // values of the connection, but we want to use the ones
+ // that are part of the configuration
+ if (isInitializing) return;
+
if ((remoteProgText != null) && !remoteProgText.isDisposed()) {
String remoteName = remoteProgText.getText().trim();
String remoteWsRoot = getRemoteWSRoot();
@@ -600,6 +607,7 @@ public class RemoteCDSFMainTab extends CMainTab {
@Override
public void initializeFrom(ILaunchConfiguration config) {
+ isInitializing = true;
String remoteConnection = null;
try {
remoteConnection = config
@@ -629,6 +637,7 @@ public class RemoteCDSFMainTab extends CMainTab {
updateTargetProgFromConfig(config);
updateSkipDownloadFromConfig(config);
updatePropertiesButton();
+ isInitializing = false;
}
/*
diff --git a/cross/org.eclipse.cdt.launch.remote/src/org/eclipse/cdt/launch/remote/tabs/RemoteCMainTab.java b/cross/org.eclipse.cdt.launch.remote/src/org/eclipse/cdt/launch/remote/tabs/RemoteCMainTab.java
index 59ffa928612..9b9d68f304f 100644
--- a/cross/org.eclipse.cdt.launch.remote/src/org/eclipse/cdt/launch/remote/tabs/RemoteCMainTab.java
+++ b/cross/org.eclipse.cdt.launch.remote/src/org/eclipse/cdt/launch/remote/tabs/RemoteCMainTab.java
@@ -1,5 +1,5 @@
/*******************************************************************************
- * Copyright (c) 2006, 2010 PalmSource, Inc. and others.
+ * Copyright (c) 2006, 2011 PalmSource, Inc. 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
@@ -19,6 +19,7 @@
* Anna Dushistova (Mentor Graphics) - [314659] move remote launch/debug to DSF
* Anna Dushistova (Mentor Graphics) - moved to org.eclipse.cdt.launch.remote.tabs
* Anna Dushistova (Mentor Graphics) - [318052] [remote launch] Properties are not saved/used
+ * Anna Dushistova (Mentor Graphics) - [333453] adapted the fix from RemoteCDSFMainTab.java
*******************************************************************************/
package org.eclipse.cdt.launch.remote.tabs;
@@ -87,6 +88,8 @@ public class RemoteCMainTab extends CMainTab {
private Text preRunText;
private Label preRunLabel;
+ private boolean isInitializing = false;
+
public RemoteCMainTab() {
this(true);
}
@@ -332,6 +335,8 @@ public class RemoteCMainTab extends CMainTab {
* @see org.eclipse.debug.ui.ILaunchConfigurationTab#initializeFrom
*/
public void initializeFrom(ILaunchConfiguration config) {
+ isInitializing = true;
+
String remoteConnection = null;
try {
remoteConnection = config
@@ -361,6 +366,7 @@ public class RemoteCMainTab extends CMainTab {
updateTargetProgFromConfig(config);
updateSkipDownloadFromConfig(config);
updatePropertiesButton();
+ isInitializing = false;
}
protected void handleNewRemoteConnectionSelected() {
@@ -597,6 +603,11 @@ public class RemoteCMainTab extends CMainTab {
}
private void useDefaultsFromConnection() {
+ // During initialization, we don't want to use the default
+ // values of the connection, but we want to use the ones
+ // that are part of the configuration
+ if (isInitializing) return;
+
if ((remoteProgText != null) && !remoteProgText.isDisposed()) {
String remoteName = remoteProgText.getText().trim();
String remoteWsRoot = getRemoteWSRoot();

Back to the top