Sfoglia il codice sorgente

* avoid to save file used by codecomplete

pierre 23 anni fa
parent
commit
a6d1670b82
2 ha cambiato i file con 14 aggiunte e 4 eliminazioni
  1. 6 2
      ide/fpcodcmp.pas
  2. 8 2
      ide/fpcompil.pas

+ 6 - 2
ide/fpcodcmp.pas

@@ -271,7 +271,8 @@ begin
         end;
       Addline('begin');
       Addline('end.');
-      SaveFile;
+      SetModified(true);
+      // SaveFile;
     end;
   StoreBrowserSwitchesConfig:=BrowserSwitches^.GetCurrSelParam;
   BrowserSwitches^.ReadItemsCfg('+');
@@ -632,7 +633,10 @@ END.
 
 {
  $Log$
- Revision 1.8  2002-09-09 06:22:45  pierre
+ Revision 1.9  2002-09-09 06:53:54  pierre
+  * avoid to save file used by codecomplete
+
+ Revision 1.8  2002/09/09 06:22:45  pierre
   * get it to load old and new desktops
 
 

+ 8 - 2
ide/fpcompil.pas

@@ -685,7 +685,10 @@ function CompilerOpenInputFile(const filename: string): pinputfile; {$ifndef FPC
 var f: pinputfile;
     W: PSourceWindow;
 begin
-  W:=EditorWindowFile(FExpand(filename));
+  if assigned(CompilingHiddenFile) then
+    W:=CompilingHiddenFile
+  else
+    W:=EditorWindowFile(FExpand(filename));
   if Assigned(W) and (W^.Editor^.GetModified) then
     f:=new(PFPInputFile, Init(W^.Editor))
   else
@@ -1287,7 +1290,10 @@ end;
 end.
 {
   $Log$
-  Revision 1.12  2002-09-07 15:40:42  peter
+  Revision 1.13  2002-09-09 06:53:54  pierre
+   * avoid to save file used by codecomplete
+
+  Revision 1.12  2002/09/07 15:40:42  peter
     * old logs removed and tabs fixed
 
   Revision 1.11  2002/09/05 08:45:40  pierre