home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Power-Programmierung
/
CD1.mdf
/
pascal
/
library
/
windows
/
listch
/
tlistchk.pas
< prev
Wrap
Pascal/Delphi Source File
|
1994-06-04
|
1KB
|
38 lines
unit TListChk;
interface
uses WinTypes, WinProcs, Objects, OWindows, ODialogs;
type
PListChkBox = ^TListChkBox;
TListChkBox = object(TListBox)
constructor Init(AParent: PWindowsObject; AnId: integer; X,Y,H,W: integer);
constructor InitResource(AParent: PWindowsObject; AnId: integer);
procedure WMCommand(var Msg: TMessage); virtual wm_First+wm_Command;
end;
implementation
constructor TListChkBox.Init(AParent: PWindowsObject; AnId: integer; X,Y,H,W: integer);
begin
inherited Init(AParent, AnId, X,Y,W,H);
Attr.Style := (Attr.Style or LBS_OWNERDRAWFIXED or LBS_HASSTRINGS and not LBS_SORT);
end;
constructor TListChkBox.InitResource(AParent: PWindowsObject; AnId: integer);
begin
inherited InitResource(AParent, AnID);
Attr.Style := (Attr.Style or LBS_OWNERDRAWFIXED or LBS_HASSTRINGS and not LBS_SORT);
end;
procedure TListChkBox.WMCommand(var Msg: TMessage);
begin
if Msg.wParam > 999 then
PostMessage(Parent^.HWindow, WM_COMMAND, Msg.wParam, Msg.lParam);
inherited WMCommand(msg);
end;
end.