Bug #19001 2013-05-16 05:55

mkaama

Recent projects disappear too happily

I have projects on network drives which are sometimes mapped and sometimes not. When not available, Code::Blocks automatically removes those projects from recent projects list, but I still want to open them later (when the networked drive is online).

Warning 'The perspective '%s' has changed. Do you want to save it?' is a poor defense.

I propose to disable automatic project removal:
===================================================================
--- src/main.cpp	(revision 8900)
+++ src/main.cpp	(working copy)
@@ -2226,7 +2226,7 @@
             wxArrayString files = Manager::Get()->GetConfigManager(_T("app"))->ReadArrayString(_T("/recent_files"));
             for (int i = (int)files.GetCount() - 1; i >= 0; --i)
             {
-                if (wxFileExists(files[i]))
+                //if (wxFileExists(files[i]))
                     m_pFilesHistory->AddFileToHistory(files[i]);
             }
             if (m_pFilesHistory->GetCount() > 0)
@@ -2248,7 +2248,7 @@
             wxArrayString files = Manager::Get()->GetConfigManager(_T("app"))->ReadArrayString(_T("/recent_projects"));
             for (int i = (int)files.GetCount() - 1; i >= 0; --i)
             {
-                if (wxFileExists(files[i]))
+                //if (wxFileExists(files[i]))
                     m_pProjectsHistory->AddFileToHistory(files[i]);
             }
             if (m_pProjectsHistory->GetCount() > 0)
Index: CodeBlocks.cbp
===================================================================
Stale projects can still be removed manually, by clicking on them.
Category
Application::WrongBehaviour
Group
Platform:All
Status
Open
Close date
 
Assigned to
tpetrov