MainWndProc运行观察
把MainWndProc改写成如下代码,便于观察:
procedure TWinControl.MainWndProc(var Message: TMessage);
begin
WindowProc(Message);
end;
写个小程序观察汇编:
procedure TForm1.Button5Click(Sender: TObject);
var
m: Tmessage;
begin
m.WParam := 100;
m.Msg := WM_SIZE;
m.LParam := 20;
MainWndProc(m);
end;