Changeset 34 for trunk/Forms
- Timestamp:
- Feb 18, 2012, 11:17:14 PM (13 years ago)
- Location:
- trunk/Forms
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Forms/UMainForm.lfm
r33 r34 455 455 } 456 456 end 457 object MenuItem31: TMenuItem458 Action = ACompileAndRun459 end460 457 object MenuItemTarget: TMenuItem 461 458 Caption = 'Target' … … 788 785 ShortCut = 16504 789 786 end 790 object ACompileAndRun: TAction791 Caption = 'Compile and run'792 OnExecute = ACompileAndRunExecute793 end794 787 object AProgramRun: TAction 795 788 Category = 'Program' -
trunk/Forms/UMainForm.lrt
r33 r34 18 18 TMAINFORM.AEXIT.CAPTION=Exit 19 19 TMAINFORM.APROGRAMCOMPILE.CAPTION=Compile 20 TMAINFORM.ACOMPILEANDRUN.CAPTION=Compile and run21 20 TMAINFORM.APROGRAMRUN.CAPTION=Run 22 21 TMAINFORM.AABOUT.CAPTION=About -
trunk/Forms/UMainForm.pas
r33 r34 23 23 AAbout: TAction; 24 24 ABreakpointToggle: TAction; 25 ACompileAndRun: TAction;26 25 AViewCompilers: TAction; 27 26 AGenerateNumber: TAction; … … 73 72 MenuItem29: TMenuItem; 74 73 MenuItem30: TMenuItem; 75 MenuItem31: TMenuItem;76 74 MenuItem32: TMenuItem; 77 75 MenuItem33: TMenuItem; … … 113 111 ToolButton9: TToolButton; 114 112 procedure ABreakpointToggleExecute(Sender: TObject); 115 procedure ACompileAndRunExecute(Sender: TObject);116 113 procedure AProgramCompileExecute(Sender: TObject); 117 114 procedure AExitExecute(Sender: TObject); … … 376 373 TTargetInterpretter(CurrentTarget).Input := InterpreterForm.MemoInput.Lines.Text; 377 374 CurrentTarget.SourceCode := MemoSource.Text; 375 if not CurrentTarget.Compiled then CurrentTarget.Compile; 378 376 CurrentTarget.Run; 379 377 end; … … 502 500 end; 503 501 504 procedure TMainForm.ACompileAndRunExecute(Sender: TObject);505 begin506 with CurrentTarget do begin507 Optimization := coNormal;508 SourceCode := MemoSource.Text;509 ProgramName := ExtractFileNameOnly(ProjectFileName);510 ProjectFileName := Self.ProjectFileName;511 Compile;512 CompileToFile;513 if CompiledExtension <> '' then Run;514 end;515 end;516 517 502 procedure TMainForm.AProgramPauseExecute(Sender: TObject); 518 503 begin
Note:
See TracChangeset
for help on using the changeset viewer.