wahaha136 发表于 2013-12-6 17:01:07

本主题需向作者支付 2 鱼币 才能浏览 购买主题

comeheres 发表于 2013-12-6 23:48:50

procedure WMKeyDown(var msg:TMessage);message WM_KEYDOWN;
procedure WMSysKeyDown(var msg:TWMSysKeyDown);message WM_SysKeyDown;
procedure WMSysKeyUp(var msg:TWMSysKeyUp);message WM_SysKeyUp;

procedure TForm1.WMKeyDown(var msg: TMessage);
begin
if (msg.WParam=VK_F4) and (Alt=True) then
    msg.WParam:=0;
end;

procedure TForm1.WMSysKeyDown(var msg: TWMSysKeyDown);
begin
if msg.CharCode=VK_MENU then
    Alt:=True;
end;

procedure TForm1.WMSysKeyUp(var msg: TWMSysKeyUp);
begin
if msg.CharCode=VK_MENU then
    Alt:=False;

wahaha136 发表于 2013-12-7 08:13:03

看不懂啊
页: [1]
查看完整版本: 求大神指导