Changeset 66 for trunk/IDE/Forms/UFormMain.pas
- Timestamp:
- Jul 19, 2012, 8:16:57 AM (12 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/IDE/Forms/UFormMain.pas
r65 r66 8 8 SysUtils, Variants, Classes, Graphics, Controls, Forms, Dialogs, StdCtrls, 9 9 ComCtrls, ExtCtrls, SynEdit, SynHighlighterPas, 10 UProject, FileUtil, Menus, ActnList, 11 UFormTargetCode, UFormCodeTree, UGeneralRegistry , UApplicationInfo;10 UProject, FileUtil, Menus, ActnList, DateUtils, 11 UFormTargetCode, UFormCodeTree, UGeneralRegistry; 12 12 13 13 type … … 146 146 procedure ProducerProcessOutput(Text: string); 147 147 public 148 procedure LoadFromRegistry(Root: Integer; Key: string);149 procedure SaveToRegistry(Root: Integer; Key: string);148 procedure LoadFromRegistry(Root: Integer; const Key: string); 149 procedure SaveToRegistry(Root: Integer; const Key: string); 150 150 procedure OpenRecentClick(Sender: TObject); 151 151 function GetSource(Name: string; var SourceCode: string): Boolean; … … 165 165 UFormTargets, UTarget, UExecutor, UFormProjectNew, 166 166 UFormTargetProject, UFormExternalProducerOutput; 167 168 resourcestring 169 SBuildFinished = 'Build finished in %s seconds'; 167 170 168 171 { TFormMain } … … 192 195 Compiler.Compile; 193 196 TargetProject.Files.LoadFromList(Compiler.TargetFiles.Files); 194 TargetProject.MainSource := TProjectFile(TargetProject.Files.First); 197 if TargetProject.Files.Count > 0 then 198 TargetProject.MainSource := TProjectFile(TargetProject.Files.First); 195 199 FormTargetProject.UpdateInterface; 196 200 … … 203 207 end; 204 208 FormProject.TreeViewProjectChange(Self, FormProject.TreeViewProject.Selected); 209 Compiler.ErrorMessage(Format(SBuildFinished, [FloatToStrF(Compiler.ElapsedTime / OneSecond, ffGeneral, 3, 10)]), Point(0, 0), ''); 205 210 FormMessages.Reload; 206 211 end; … … 397 402 end; 398 403 399 procedure TFormMain.LoadFromRegistry(Root: Integer; Key: string);404 procedure TFormMain.LoadFromRegistry(Root: Integer; const Key: string); 400 405 begin 401 406 with TGeneralRegistry.Create(nil) do … … 414 419 end; 415 420 416 procedure TFormMain.SaveToRegistry(Root: Integer; Key: string);421 procedure TFormMain.SaveToRegistry(Root: Integer; const Key: string); 417 422 begin 418 423 with TGeneralRegistry.Create(nil) do
Note:
See TracChangeset
for help on using the changeset viewer.