gpt4 book ai didi

delphi - 为什么 VK_Control+VKHome 对我不起作用?

转载 作者:行者123 更新时间:2023-12-03 15:16:39 24 4
gpt4 key购买 nike

procedure TSell.ApplicationEvents1Message(var Msg: tagMSG;
var Handled: Boolean);
begin
if (Msg.Message=WM_KEYDOWN)and(Msg.wParam=VK_CONTROL+VK_HOME)then
begin
end;

最佳答案

要检查 VK_CONTROL 虚拟键的状态,必须使用 GetKeyState功能。

尝试这个示例

procedure TSell.ApplicationEvents1Message(var Msg: tagMSG;
var Handled: Boolean);
begin
if (Msg.Message=WM_KEYDOWN) then
if (GetKeyState(VK_CONTROL) < 0) and (Msg.wParam=VK_HOME) then
//do your stuff
end;

关于delphi - 为什么 VK_Control+VKHome 对我不起作用?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/6501240/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com