请问DispatchMessage(Msg);之后应该转到procedure TApplication.WndProc(var Message: TMessage);那么什么时候执行窗体的mainWndProc
function TApplication.ProcessMessage(var Msg: TMsg): Boolean;
var
Handled: Boolean;
begin
Result := False;
if PeekMessage(Msg, 0, 0, 0, PM_REMOVE) then
begin
Result := True;
if Msg.Message <> WM_QUIT then
begin
Handled := False;
if Assigned(FOnMessage) then FOnMessage(Msg, Handled);
if not IsHintMsg(Msg) and not Handled and not IsMDIMsg(Msg) and
not IsKeyMsg(Msg) and not IsDlgMsg(Msg) then
begin
TranslateMessage(Msg);
DispatchMessage(Msg);
end;
end
else
FTerminate := True; // 看到我们刚才提高的这个标志了吗
end;
end;
请问DispatchMessage(Msg);之后应该转到procedure TApplication.WndProc(var Message: TMessage);那么什么时候执行窗体的mainWndProc