unit Unit1; interface uses Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms, Dialogs; type TForm1 = class(TForm) procedure FormMouseDown(Sender: TObject; Button: TMouseButton; Shift: TShiftState; X, Y: Integer); private procedure WMMouseDown(var msg: TMessage); message WM_LBUTTONDOWN; { Private declarations } public { Public declarations } end; var Form1: TForm1; implementation {$R *.dfm} //运行后在窗体上点击左键会激活: procedure TForm1.WMMouseDown(var msg: TMessage); begin ShowMessage('WM_LBUTTONDOWN'); end; //运行后在窗体上点击右键会激活: procedure TForm1.FormMouseDown(Sender: TObject; Button: TMouseButton; Shift: TShiftState; X, Y: Integer); begin ShowMessage('这是Delphi事件'); //被阻挡,但没有阻挡右键 end; end.