我是否可以知道是否可以使用键盘快捷键从系统托盘最大化我的 Windows 窗体应用程序,而不是单击它?
我目前正在最小化使用这段代码
//Minimize to Tray with over-ride for short cut
private void MinimiseToTray(bool shortCutPressed)
{
notifyIcon.BalloonTipTitle = "Minimize to Tray App";
notifyIcon.BalloonTipText = "You have successfully minimized your app.";
if (FormWindowState.Minimized == this.WindowState || shortCutPressed)
{
notifyIcon.Visible = true;
notifyIcon.ShowBalloonTip(500);
this.Hide();
}
else if (FormWindowState.Normal == this.WindowState)
{
notifyIcon.Visible = false;
}
}
因此,我需要一个可以最大化它的键盘快捷键。非常感谢!