home *** CD-ROM | disk | FTP | other *** search
- unit Unixfmgr;
-
- interface
-
- uses
- SysUtils, WinTypes, WinProcs, Messages, Classes, Graphics, Controls,
- Forms, Dialogs, UFMGR34;
-
- type
- TUnixFileManagerForm = class(TComponent)
- private
- { Private declarations }
- TheForm : TCCFileMgrForm;
- FOnCreate : TNotifyEvent;
- FOnDestroy : TNotifyEvent;
- FOnShow : TNotifyEvent;
- FTop : Integer;
- FLeft : Integer;
- protected
- { Protected declarations }
- public
- { Public declarations }
- constructor Create( AOwner : TComponent ); override;
- destructor Destroy; override;
- procedure Show;
- published
- { Published declarations }
- property Top : Integer read FTop write FTop;
- property Left : Integer read FLeft write FLeft;
- property OnCreate : TNotifyEvent read FOnCreate write FOnCreate;
- property OnDestroy : TNotifyEvent read FOnDestroy write FOnDestroy;
- property OnShow : TNotifyEvent read FOnShow write FOnShow;
- end;
-
- procedure Register;
-
- implementation
-
- constructor TUnixFileManagerForm.Create( AOwner : TComponent );
- begin
- inherited Create( AOwner );
- TheForm := TCCFileMgrForm.Create( Application.MainForm );
- TheForm.Visible := false;
- if Assigned( FOnCreate ) then OnCreate( Self );
- end;
-
- destructor TUnixFileManagerForm.Destroy;
- begin
- if Assigned( FOnDestroy ) then OnDestroy( Self );
- if Assigned( TheForm ) then TheForm.Close;
- inherited Destroy;
- end;
-
- procedure TUnixFileManagerForm.Show;
- begin
- if Assigned( FOnShow ) then OnShow( Self );
- TheForm.Position := poDesigned;
- TheForm.Top := Top;
- TheForm.Left := Left;
- TheForm.Visible := true;
- TheForm.Show;
- end;
-
- procedure Register;
- begin
- RegisterComponents('Goodies', [TUnixFileManagerForm]);
- end;
-
- end.
-