Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSean Evoy2005-01-31 20:52:36 +0000
committerSean Evoy2005-01-31 20:52:36 +0000
commit6a104cdd5bfeee8874bab066287fd7e676fe457c (patch)
treeb1b76f63a754e1fc566be8a3f894c7b37f078841 /build/org.eclipse.cdt.managedbuilder.ui
parentdb9b29f9d7073f84cef643e6eee83df1f3d0ea4f (diff)
downloadorg.eclipse.cdt-6a104cdd5bfeee8874bab066287fd7e676fe457c.tar.gz
org.eclipse.cdt-6a104cdd5bfeee8874bab066287fd7e676fe457c.tar.xz
org.eclipse.cdt-6a104cdd5bfeee8874bab066287fd7e676fe457c.zip
Fix for bugzilla 75529 -- [Managed Build] Shouldn't go to the beginning on configuration changing
Corrected a problem whereby a tree selection on a selected option would hide the options.
Diffstat (limited to 'build/org.eclipse.cdt.managedbuilder.ui')
-rw-r--r--build/org.eclipse.cdt.managedbuilder.ui/src/org/eclipse/cdt/managedbuilder/internal/ui/ToolsSettingsBlock.java18
1 files changed, 6 insertions, 12 deletions
diff --git a/build/org.eclipse.cdt.managedbuilder.ui/src/org/eclipse/cdt/managedbuilder/internal/ui/ToolsSettingsBlock.java b/build/org.eclipse.cdt.managedbuilder.ui/src/org/eclipse/cdt/managedbuilder/internal/ui/ToolsSettingsBlock.java
index e406e7aa0f8..f551f4cfef4 100644
--- a/build/org.eclipse.cdt.managedbuilder.ui/src/org/eclipse/cdt/managedbuilder/internal/ui/ToolsSettingsBlock.java
+++ b/build/org.eclipse.cdt.managedbuilder.ui/src/org/eclipse/cdt/managedbuilder/internal/ui/ToolsSettingsBlock.java
@@ -192,10 +192,6 @@ public class ToolsSettingsBlock extends AbstractCOptionPage {
* @param category
*/
private void displayOptionsForCategory(IOptionCategory category) {
- // Do nothing if the selected category is is unchanged
- if (category == selectedCategory) {
- return;
- }
selectedTool = null;
selectedCategory = category;
@@ -241,7 +237,7 @@ public class ToolsSettingsBlock extends AbstractCOptionPage {
// save the last page build options.
// If the last page is tool page then parse all the options
// and put it in the appropriate preference store.
- if (oldPage != null){
+ if (oldPage != null && oldPage != currentSettingsPage){
if(oldPage instanceof BuildOptionSettingsPage) {
((BuildOptionSettingsPage)oldPage).storeSettings();
}
@@ -254,7 +250,7 @@ public class ToolsSettingsBlock extends AbstractCOptionPage {
if(currentSettingsPage instanceof BuildOptionSettingsPage)
((BuildOptionSettingsPage)currentSettingsPage).updateFields();
- if (oldPage != null)
+ if (oldPage != null && oldPage != currentSettingsPage)
oldPage.setVisible(false);
// Set the size of the scrolled area
@@ -267,9 +263,6 @@ public class ToolsSettingsBlock extends AbstractCOptionPage {
* @param tool
*/
private void displayOptionsForTool(ITool tool) {
- if (tool == selectedTool) {
- return;
- }
// Unselect the category
selectedCategory = null;
// record that the tool selection has changed
@@ -316,7 +309,7 @@ public class ToolsSettingsBlock extends AbstractCOptionPage {
currentSettingsPage.setVisible(true);
// Save the last page build options.
- if (oldPage != null){
+ if (oldPage != null && oldPage != currentSettingsPage){
if(oldPage instanceof BuildOptionSettingsPage) {
((BuildOptionSettingsPage)oldPage).storeSettings();
}
@@ -329,7 +322,7 @@ public class ToolsSettingsBlock extends AbstractCOptionPage {
if(currentSettingsPage instanceof BuildToolSettingsPage)
((BuildToolSettingsPage)currentSettingsPage).updateAllOptionField();
- if (oldPage != null)
+ if (oldPage != null && oldPage != currentSettingsPage)
oldPage.setVisible(false);
// Set the size of the scrolled area
@@ -409,6 +402,7 @@ public class ToolsSettingsBlock extends AbstractCOptionPage {
// There is a selected tool defined
primary = selectedTool;
} else if (selectedCategory != null) {
+// if (selectedCategory != null) {
// There is a selected option or category
primary = selectedCategory;
} else {
@@ -423,7 +417,7 @@ public class ToolsSettingsBlock extends AbstractCOptionPage {
}
if (primary != null) {
- optionList.setSelection(new StructuredSelection(primary));
+ optionList.setSelection(new StructuredSelection(primary), true);
}
}

Back to the top