Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我有一个 WPF 应用程序,我通过 this.Hide() 和 System.Windows.Forms.NotifyIcon 将其最小化到系统托盘。当它最小化时,我想要一个键盘钩子最大化应用程序。例如,如何注册像 Windows-Button & T 这样的键盘钩子。
谢谢。
如果您不介意 Win32 API 调用,我会说您最好的选择是调用RegisterHotKey。您将修饰符和键传递给它以捕获,然后将 aWM_HOTKEY发送到您最初传入的 HWND。
WM_HOTKEY