增加隐藏托盘图标的功能

This commit is contained in:
liufei
2021-12-13 10:53:55 +08:00
parent 00f581a03e
commit 8958bddb25
4 changed files with 42 additions and 2 deletions

View File

@@ -95,6 +95,8 @@ namespace GeekDesk
ShowApp();
}
BarIcon.Text = Constants.MY_NAME;
//注册热键
RegisterHotKey(true);
RegisterCreateToDoHotKey(true);
@@ -510,6 +512,16 @@ namespace GeekDesk
p.Start();
Application.Current.Shutdown();
}
/// <summary>
/// 关闭托盘图标
/// </summary>
/// <param name="sender"></param>
/// <param name="e"></param>
private void CloseBarIcon(object sender, RoutedEventArgs e)
{
appData.AppConfig.ShowBarIcon = false;
}
}