This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 134884

Summary: IDE doesn't close file if it has been added via 'Add Existing Item...' wizard
Product: cnd Reporter: soldatov <soldatov>
Component: ProjectAssignee: Thomas Preisler <thp>
Status: RESOLVED FIXED    
Severity: blocker    
Priority: P4    
Version: 6.x   
Hardware: All   
OS: All   
Issue Type: DEFECT Exception Reporter:

Description soldatov 2008-05-12 20:52:59 UTC
Many time ago I created issue 79466 (When "C/C++ Project with Existing Makefile" project is closing, then source files
should be closed automatically). It has been closed as 'WONTFIX', but now that problem is resolved. When I am closing
makefile based project, then IDE closes almost all files. But IDE ignores files which I added via 'Add Existing Item...'
wizard. Can IDE close such files automatically also?

Scenario:
- Create /home/sova/test/test.c file
- In NetBeans create new C/C++ project in /home/sova/NetBeansProjects folder
- Add /home/sova/test/test.c file via 'Add Existing Item...' wizard
- Open this file in built-in editor
- Close project
==> 'test.c' file is opened

Workaround:
Need to add /home/sova/test folder into 'General|Source Folders' table in 'Project Properties' window
Comment 1 Thomas Preisler 2008-11-18 06:10:42 UTC
not for 7.0
Comment 2 Thomas Preisler 2008-11-18 21:03:25 UTC
next
Comment 3 Thomas Preisler 2009-10-24 05:36:58 UTC
This issue was actually fixed when we moved unmanaged projects to 'true source roots'. You manage files in the project by adding or removing source folders 
from General|Source Folders and the Add Existing Item... action doesn't exist anymore.