Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 352337

Summary: Wrong setting applied in "All configurations" if Cancel after Apply
Product: [Tools] CDT Reporter: Tom Tan <hdwkboy>
Component: cdt-build-managedAssignee: Project Inbox <cdt-build-managed-inbox>
Status: RESOLVED INVALID QA Contact: Chris Recoskie <recoskie>
Severity: normal    
Priority: P3 CC: cdtdoug
Version: 8.0   
Target Milestone: ---   
Hardware: PC   
OS: Windows XP   
Whiteboard:

Description Tom Tan CLA 2011-07-18 07:31:38 EDT
Build Identifier: 20110615-0604

please refer to the steps to reproduce.

Reproducible: Always

Steps to Reproduce:
I used Cygwin as the toolchains and CDT Version: Indigo Release, Build id: 20110615-0604
1. Create a C/C++ project.
2. Go to project Properties->Settings page, choose Debug configuration, set Tool Settings->Cygwin C++ Compiler->Preprocessor->Do not search system directories(-nostdinc) checked (default is not checked), then click Apply and OK button.
3. Go to the settings page again, choose [All configurations], then Apply and Cancel this time. 
4. Go to the setting page, you can find -nostdinc is checked in both Debug and Release configurations.
Comment 1 Andrew Gvozdev CLA 2011-07-18 09:44:34 EDT
(In reply to comment #0)
I don't see anything wrong here. Perhaps there is a misunderstanding how "Apply" button works?
> Steps to Reproduce:
> I used Cygwin as the toolchains and CDT Version: Indigo Release, Build id:
> 20110615-0604
> 1. Create a C/C++ project.
> 2. Go to project Properties->Settings page, choose Debug configuration, set Tool
> Settings->Cygwin C++ Compiler->Preprocessor->Do not search system
> directories(-nostdinc) checked (default is not checked), then click Apply and OK
> button.
> 3. Go to the settings page again, choose [All configurations], then Apply and
At that point, Apply button applies your change to all configurations and persists it in the project model. If you choose one specific configuration, it will be "applied" to that specific configuration. How that works under hood - when you open properties a temporary working copy of configuration is created and user changes that one. As soon as "Apply" or "OK" is pressed the changes are "applied" to the real configuration(s). Hitting "Apply" (vs "OK") lets you save the changes in the model but not leave the property pages yet.

> Cancel this time.
Cancel does not do anything here as the new settings have been saved with Apply button.

> 4. Go to the setting page, you can find -nostdinc is checked in both Debug and
> Release configurations.
That is the correct behavior.