perf: wpf Win10+Toast通知使用系统内置通知声而不是独立播放

This commit is contained in:
status102
2025-08-04 15:12:12 +08:00
parent 422e8832f4
commit 0d4bbb4c07

View File

@@ -267,7 +267,7 @@ namespace MaaWpfGui.Helper
#region
private List<NotificationAction> _actions = new List<NotificationAction>();
private List<NotificationAction> _actions = [];
#endregion
@@ -345,8 +345,10 @@ namespace MaaWpfGui.Helper
// 显示通知
_notificationPoster.ShowNotification(content);
// 播放通知提示音
PlayNotificationSound(sound);
if (_notificationPoster is not NotificationImplWinRT)
{
PlayNotificationSound(sound); // 播放通知提示音
}
// 任务栏闪烁
FlashWindowEx();