Author: lluis
Date: 2008-01-18 04:05:19 -0500 (Fri, 18 Jan 2008)
New Revision: 93234

Modified:
   branches/monodevelop/main/1.0/src/core/MonoDevelop.Projects/ChangeLog
   
branches/monodevelop/main/1.0/src/core/MonoDevelop.Projects/MonoDevelop.Projects.Parser/AssemblyCodeCompletionDatabase.cs
   
branches/monodevelop/main/1.0/src/core/MonoDevelop.Projects/MonoDevelop.Projects.Parser/CodeCompletionDatabase.cs
Log:
2008-01-18  Lluis Sanchez Gual <[EMAIL PROTECTED]> 

        * MonoDevelop.Projects.Parser/AssemblyCodeCompletionDatabase.cs,
          MonoDevelop.Projects.Parser/CodeCompletionDatabase.cs: The assembly 
file
          location may change. Update it when loading the db.



Modified: branches/monodevelop/main/1.0/src/core/MonoDevelop.Projects/ChangeLog
===================================================================
--- branches/monodevelop/main/1.0/src/core/MonoDevelop.Projects/ChangeLog       
2008-01-18 08:55:41 UTC (rev 93233)
+++ branches/monodevelop/main/1.0/src/core/MonoDevelop.Projects/ChangeLog       
2008-01-18 09:05:19 UTC (rev 93234)
@@ -1,3 +1,9 @@
+2008-01-18  Lluis Sanchez Gual <[EMAIL PROTECTED]> 
+
+       * MonoDevelop.Projects.Parser/AssemblyCodeCompletionDatabase.cs,
+         MonoDevelop.Projects.Parser/CodeCompletionDatabase.cs: The assembly 
file
+         location may change. Update it when loading the db.
+
 2008-01-08  Lluis Sanchez Gual <[EMAIL PROTECTED]> 
 
        * MonoDevelop.Projects.CodeGeneration/CodeRefactorer.cs: Added methods 
for

Modified: 
branches/monodevelop/main/1.0/src/core/MonoDevelop.Projects/MonoDevelop.Projects.Parser/AssemblyCodeCompletionDatabase.cs
===================================================================
--- 
branches/monodevelop/main/1.0/src/core/MonoDevelop.Projects/MonoDevelop.Projects.Parser/AssemblyCodeCompletionDatabase.cs
   2008-01-18 08:55:41 UTC (rev 93233)
+++ 
branches/monodevelop/main/1.0/src/core/MonoDevelop.Projects/MonoDevelop.Projects.Parser/AssemblyCodeCompletionDatabase.cs
   2008-01-18 09:05:19 UTC (rev 93234)
@@ -80,6 +80,15 @@
 
                        Read ();
                        
+                       ArrayList oldFiles = new ArrayList ();
+                       foreach (FileEntry e in GetAllFiles ()) {
+                               if (e.FileName != assemblyFile)
+                                       oldFiles.Add (e);
+                       }
+                       
+                       foreach (FileEntry e in oldFiles)
+                               RemoveFile (e.FileName);
+                       
                        if (files [assemblyFile] == null) {
                                AddFile (assemblyFile);
                                headers ["CheckFile"] = assemblyFile;

Modified: 
branches/monodevelop/main/1.0/src/core/MonoDevelop.Projects/MonoDevelop.Projects.Parser/CodeCompletionDatabase.cs
===================================================================
--- 
branches/monodevelop/main/1.0/src/core/MonoDevelop.Projects/MonoDevelop.Projects.Parser/CodeCompletionDatabase.cs
   2008-01-18 08:55:41 UTC (rev 93233)
+++ 
branches/monodevelop/main/1.0/src/core/MonoDevelop.Projects/MonoDevelop.Projects.Parser/CodeCompletionDatabase.cs
   2008-01-18 09:05:19 UTC (rev 93234)
@@ -352,6 +352,12 @@
                {
                        return files [name] as FileEntry;
                }
+               
+               protected IEnumerable<FileEntry> GetAllFiles ()
+               {
+                       foreach (FileEntry fe in files.Values)
+                               yield return fe;
+               }
 
                internal IEnumerable<ClassEntry> GetAllClasses ()
                {

_______________________________________________
Mono-patches maillist  -  Mono-patches@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-patches

Reply via email to