Changeset 11 for trunk/Forms/UFormBrowse.pas
- Timestamp:
- May 19, 2015, 11:33:02 PM (9 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Forms/UFormBrowse.pas
r10 r11 7 7 uses 8 8 Classes, SysUtils, FileUtil, Forms, Controls, Graphics, Dialogs, ComCtrls, 9 ExtCtrls, Menus, ActnList, UFindFile ;9 ExtCtrls, Menus, ActnList, UFindFile, UVCS; 10 10 11 11 type … … 15 15 TFormBrowse = class(TForm) 16 16 AAdd: TAction; 17 ALogShow: TAction; 17 18 AOpen: TAction; 18 19 AProperties: TAction; … … 28 29 MenuItem5: TMenuItem; 29 30 MenuItem6: TMenuItem; 31 MenuItem7: TMenuItem; 30 32 PopupMenu1: TPopupMenu; 31 33 Splitter1: TSplitter; … … 33 35 procedure AAddExecute(Sender: TObject); 34 36 procedure ADeleteExecute(Sender: TObject); 37 procedure ALogShowExecute(Sender: TObject); 35 38 procedure AOpenExecute(Sender: TObject); 36 39 procedure ARenameExecute(Sender: TObject); 37 40 procedure FormCreate(Sender: TObject); 38 41 procedure FormDestroy(Sender: TObject); 42 procedure FormShow(Sender: TObject); 39 43 procedure ListView1Data(Sender: TObject; Item: TListItem); 40 44 procedure ListView1DblClick(Sender: TObject); 45 procedure ListView1SelectItem(Sender: TObject; Item: TListItem; 46 Selected: Boolean); 41 47 private 42 48 FileList: TStringList; … … 53 59 54 60 uses 55 UCore ;61 UCore, UFormLog; 56 62 57 63 {$R *.lfm} … … 71 77 end; 72 78 79 procedure TFormBrowse.ListView1SelectItem(Sender: TObject; Item: TListItem; 80 Selected: Boolean); 81 begin 82 UpdateInterface; 83 end; 84 73 85 procedure TFormBrowse.ADeleteExecute(Sender: TObject); 74 86 begin 75 87 88 end; 89 90 procedure TFormBrowse.ALogShowExecute(Sender: TObject); 91 begin 92 FormLog.FileName := Directory + DirectorySeparator + ListView1.Selected.Caption; 93 FormLog.ShowModal; 76 94 end; 77 95 … … 114 132 end; 115 133 134 procedure TFormBrowse.FormShow(Sender: TObject); 135 begin 136 UpdateInterface; 137 end; 138 116 139 procedure TFormBrowse.ReloadList; 117 140 var … … 145 168 ARename.Enabled := Assigned(ListView1.Selected); 146 169 AProperties.Enabled := Assigned(ListView1.Selected); 170 AOpen.Enabled := Assigned(ListView1.Selected); 171 ALogShow.Enabled := Assigned(ListView1.Selected); 147 172 end; 148 173
Note:
See TracChangeset
for help on using the changeset viewer.