Skip to main content
summaryrefslogtreecommitdiffstats
path: root/cross
diff options
context:
space:
mode:
authorMarc Khouzam2011-01-14 11:52:53 -0500
committerMarc Khouzam2011-01-14 11:52:53 -0500
commitbe117ed8e8ebe3ad1dcb380505c244ddce86c12b (patch)
tree3ecd53d1376f3ea3268da6b56ae480c33b78c764 /cross
parentdd3fcbb7a34a65ff89435c0053fc1d288c6fb9d9 (diff)
downloadorg.eclipse.cdt-be117ed8e8ebe3ad1dcb380505c244ddce86c12b.tar.gz
org.eclipse.cdt-be117ed8e8ebe3ad1dcb380505c244ddce86c12b.tar.xz
org.eclipse.cdt-be117ed8e8ebe3ad1dcb380505c244ddce86c12b.zip
Bug 333453: checkbox cleared when changing tab in remote application debug configuration.
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 1765a40b4b..1d26b14eb6 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 59ffa92861..9b9d68f304 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