* UIForm: 修复了一个全局热键销毁的判断

This commit is contained in:
Sunny 2021-10-26 09:10:23 +08:00
parent e2979955fc
commit 0a0a71e0da
2 changed files with 5 additions and 2 deletions

Binary file not shown.

View File

@ -17,9 +17,12 @@ namespace Sunny.UI
{
this.UnRegister();
foreach (var hotKey in this.hotKeys.Values)
if (hotKeys != null)
{
Win32.User.UnregisterHotKey(IntPtr.Zero, hotKey.id);
foreach (var hotKey in hotKeys.Values)
{
Win32.User.UnregisterHotKey(IntPtr.Zero, hotKey.id);
}
}
if (disposing && (components != null))