-
Delphi 获取鼠标按键状态源码.rar下载
资源介绍
Delphi 获取鼠标按键状态源码,运行本程序后,操作鼠标左右键和中轮,程序将监控到这些鼠标键被按下的状态,并将信息显示在窗口的标题栏中,本程序同时也实现了动态改变窗口标题文字的功能,各个鼠标按键状态获取及提示信息如下:
procedure TForm1.WMLButtonDblClk(var Message: TWMLButtonDblClk);
begin
Self.Caption := '鼠标左键双击';
end;
procedure TForm1.WMLButtonDown(var Message: TWMLButtonDown);
begin
Self.Caption := '鼠标左键按下';
end;
procedure TForm1.WMMButtonDblClk(var Message: TWMMButtonDblClk);
begin
Self.Caption := '鼠标中键双击';
end;
procedure TForm1.WMMButtonDown(var Message: TWMMButtonDown);
begin
Self.Caption := '鼠标中键按下';
end;
procedure TForm1.WMRButtonDblClk(var Message: TWMRButtonDblClk);
begin
Self.Caption := '鼠标右键双击';
end;
procedure TForm1.WMRButtonDown(var Message: TWMRButtonDown);
begin
Self.Caption := '鼠标右键按下';
end;