home *** CD-ROM | disk | FTP | other *** search
- unit DeviceProps;
-
- interface
-
- uses
- Windows, Messages, SysUtils, Classes, Graphics, Controls, Forms, Dialogs,
- ComCtrls, MSI_Devices, StdCtrls, ExtCtrls;
-
- type
- TpropDevice = class(TFrame)
- pc: TPageControl;
- tsGeneral: TTabSheet;
- Image1: TImage;
- Bevel3: TBevel;
- lMfg: TLabel;
- lType: TLabel;
- lLocation: TLabel;
- stName: TEdit;
- stMfg: TStaticText;
- stType: TStaticText;
- stLocation: TStaticText;
- Bevel1: TBevel;
- Label1: TLabel;
- Label2: TLabel;
- Label3: TLabel;
- stDriverDate: TStaticText;
- stDriverProv: TStaticText;
- stDriverVer: TStaticText;
- private
- FDevice: TObject;
- public
- property Device: TObject read FDevice write FDevice;
- procedure Refresh;
- end;
-
- implementation
-
- {$R *.DFM}
-
- { TpropDevice }
-
- procedure TpropDevice.Refresh;
- begin
- pc.ActivePage:=tsGeneral;
- with PDevice(Device)^ do begin
- if Trim(FriendlyName)='' then
- stName.Text:=Description
- else
- stName.Text:=FriendlyName;
- if Trim(ClassDesc)='' then
- stType.Caption:=ClassName
- else
- stType.Caption:=ClassDesc;
- stMfg.Caption:=Manufacturer;
- stLocation.caption:=Location;
- stDriverprov.Caption:=Driverprovider;
- stDriverdate.Caption:=Driverdate;
- stDriverVer.Caption:=DriverVersion;
- end;
- end;
-
- end.
-