1 |
(* ***** BEGIN LICENSE BLOCK *****
|
2 |
* Version: MPL 1.1
|
3 |
*
|
4 |
* The contents of this file are subject to the Mozilla Public License Version
|
5 |
* 1.1 (the "License"); you may not use this file except in compliance with
|
6 |
* the License. You may obtain a copy of the License at
|
7 |
* http://www.mozilla.org/MPL/
|
8 |
*
|
9 |
* Software distributed under the License is distributed on an "AS IS" basis,
|
10 |
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
|
11 |
* for the specific language governing rights and limitations under the
|
12 |
* License.
|
13 |
*
|
14 |
* The Original Code is TurboPower SysTools
|
15 |
*
|
16 |
* The Initial Developer of the Original Code is
|
17 |
* TurboPower Software
|
18 |
*
|
19 |
* Portions created by the Initial Developer are Copyright (C) 1996-2002
|
20 |
* the Initial Developer. All Rights Reserved.
|
21 |
*
|
22 |
* Contributor(s):
|
23 |
*
|
24 |
* ***** END LICENSE BLOCK ***** *)
|
25 |
|
26 |
unit EXUSRMG2;
|
27 |
|
28 |
interface
|
29 |
|
30 |
uses
|
31 |
Windows, Messages, SysUtils, Classes, Graphics, Controls, Forms, Dialogs,
|
32 |
StdCtrls, ComCtrls,
|
33 |
|
34 |
StNet;
|
35 |
|
36 |
type
|
37 |
TGroupPropertiesForm = class(TForm)
|
38 |
Label1: TLabel;
|
39 |
GroupNameEdit: TEdit;
|
40 |
Label3: TLabel;
|
41 |
CommentEdit: TEdit;
|
42 |
GroupBox1: TGroupBox;
|
43 |
ListView1: TListView;
|
44 |
OKBtn: TButton;
|
45 |
CancelBtn: TButton;
|
46 |
procedure FormShow(Sender: TObject);
|
47 |
private
|
48 |
{ Private declarations }
|
49 |
public
|
50 |
{ Public declarations }
|
51 |
G : TStNetGroupItem;
|
52 |
ML : TStringList;
|
53 |
end;
|
54 |
|
55 |
var
|
56 |
GroupPropertiesForm: TGroupPropertiesForm;
|
57 |
|
58 |
implementation
|
59 |
|
60 |
{$R *.DFM}
|
61 |
|
62 |
procedure TGroupPropertiesForm.FormShow(Sender: TObject);
|
63 |
var
|
64 |
I : Integer;
|
65 |
MI : TStNetItem;
|
66 |
LI : TListItem;
|
67 |
begin
|
68 |
Caption := Format(Caption, [G.Name]);
|
69 |
GroupNameEdit.Text := G.Name;
|
70 |
CommentEdit.Text := G.Comment;
|
71 |
|
72 |
ML := G.Items;
|
73 |
for I := 0 to ML.Count-1 do begin
|
74 |
MI := TStNetItem(ML.Objects[I]);
|
75 |
LI := ListView1.Items.Add;
|
76 |
LI.Caption := MI.Name;
|
77 |
LI.SubItems.Add(MI.Comment);
|
78 |
end;
|
79 |
end;
|
80 |
|
81 |
end.
|