Changeset 20 for trunk/UCore.pas
- Timestamp:
- Oct 5, 2019, 2:00:50 PM (5 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/UCore.pas
r19 r20 15 15 TCore = class(TDataModule) 16 16 AAbout: TAction; 17 AUndo: TAction; 17 18 ASettings: TAction; 18 19 ActionList1: TActionList; 19 20 AExit: TAction; 20 A GameNew: TAction;21 ANew: TAction; 21 22 ApplicationInfo1: TApplicationInfo; 22 23 PersistentForm1: TPersistentForm; … … 25 26 procedure AAboutExecute(Sender: TObject); 26 27 procedure AExitExecute(Sender: TObject); 27 procedure A GameNewExecute(Sender: TObject);28 procedure ANewExecute(Sender: TObject); 28 29 procedure ASettingsExecute(Sender: TObject); 30 procedure AUndoExecute(Sender: TObject); 29 31 procedure DataModuleCreate(Sender: TObject); 30 32 procedure DataModuleDestroy(Sender: TObject); … … 33 35 public 34 36 Game: TGame; 37 procedure UpdateInterface; 35 38 procedure LoadConfig; 36 39 procedure SaveConfig; … … 68 71 end; 69 72 73 procedure TCore.AUndoExecute(Sender: TObject); 74 begin 75 Game.Undo; 76 end; 77 70 78 procedure TCore.AAboutExecute(Sender: TObject); 71 79 begin … … 84 92 end; 85 93 86 procedure TCore.A GameNewExecute(Sender: TObject);94 procedure TCore.ANewExecute(Sender: TObject); 87 95 begin 88 96 FormNew := TFormNew.Create(nil); … … 107 115 begin 108 116 FormMain.Redraw; 117 UpdateInterface; 118 end; 119 120 procedure TCore.UpdateInterface; 121 begin 122 AUndo.Enabled := Game.CanUndo;; 109 123 end; 110 124
Note:
See TracChangeset
for help on using the changeset viewer.