private void Exit_Click(object sender, EventArgs e) { if (System.Windows.MessageBox.Show("确定要关闭吗?", "退出", MessageBoxButton.YesNo, MessageBoxImage.Question, MessageBoxResult.No) == MessageBoxResult.Yes) { notifiy.Dispose(); TaskBarUtil.RefreshNotificationArea(); System.Windows.Application.Current.Shutdown(); } }
private void App_Exit(object sender, ExitEventArgs e) { notifiy.Dispose(); TaskBarUtil.RefreshNotificationArea(); }