Changeset 24 for trunk/IDE/Forms/UMainForm.pas
- Timestamp:
- Nov 10, 2010, 9:42:27 AM (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/IDE/Forms/UMainForm.pas
r22 r24 7 7 uses 8 8 SysUtils, Variants, Classes, Graphics, Controls, Forms, 9 Dialogs, StdCtrls, UCompiler, Registry, 9 Dialogs, StdCtrls, UCompiler, Registry, Contnrs, 10 10 ComCtrls, ExtCtrls, SynEdit, SynHighlighterPas, 11 11 UProject, FileUtil, Menus, ActnList, UCoolDocking, … … 52 52 ToolBar1: TToolBar; 53 53 procedure AProjectCloseExecute(Sender: TObject); 54 procedure AProjectNewExecute(Sender: TObject); 54 55 procedure AProjectOpenExecute(Sender: TObject); 55 56 procedure AProjectSaveAsExecute(Sender: TObject); … … 91 92 procedure TMainForm.ABuildExecute(Sender: TObject); 92 93 begin 94 CodeForm.Save; 95 93 96 // Compile project file 94 97 if (ComboBoxAnalyzer.Items.Count > 0) and (ComboBoxAnalyzer.ItemIndex <> -1) and … … 208 211 begin 209 212 Project.LoadFromFile(FileName); 210 LastOpenedFiles.Add (FileName);213 LastOpenedFiles.AddItem(FileName); 211 214 LastOpenedFiles.ReloadMenu; 212 215 ProjectManager.UpdateProjectTree; … … 235 238 for I := 0 to Compiler.Producers.Count - 1 do 236 239 ComboBoxProducer.AddItem(Compiler.Producers[I].Name, nil); 240 237 241 ComboBoxAnalyzer.Clear; 238 242 for I := 0 to Compiler.Analyzers.Count - 1 do … … 289 293 end; 290 294 295 procedure TMainForm.AProjectNewExecute(Sender: TObject); 296 begin 297 Project.Clear; 298 Project.Name := 'New project'; 299 ProjectManager.UpdateProjectTree; 300 Caption := ApplicationInfo.Name + ' - ' + Project.Name; 301 end; 302 291 303 procedure TMainForm.AProjectSaveAsExecute(Sender: TObject); 292 304 begin 293 305 if SaveDialog1.Execute then begin 294 306 Project.SaveToFile(SaveDialog1.FileName); 307 CodeForm.Save; 295 308 Project.Save; 296 309 end; … … 299 312 procedure TMainForm.AProjectSaveExecute(Sender: TObject); 300 313 begin 314 CodeForm.Save; 301 315 Project.SaveToFile(Project.GetDir(True) + Project.Name + '.tppr'); 302 316 end;
Note:
See TracChangeset
for help on using the changeset viewer.