Here are the examples of the csharp api class ActionCenterHistoryChangedTask.ActionCenterChangedBackgroundTask.UpdateAppData(System.Collections.Generic.IReadOnlyList) taken from open source projects. By voting up you can indicate which examples are most useful and appropriate.
1 Example
0
1. Example
Project: WinDevCamp
Source File: ActionCenterChangedBackgroundTask.cs
Source File: ActionCenterChangedBackgroundTask.cs
public void Run(IBackgroundTaskInstance taskInstance) { var toasts = ToastNotificationManager.History.GetHistory(); if (toasts != null) { var count = toasts.Count(); XmlDocument badgeXml = BadgeUpdateManager.GetTemplateContent(BadgeTemplateType.BadgeNumber); XmlElement badgeElement = (XmlElement)badgeXml.SelectSingleNode("/badge"); badgeElement.SetAttribute("value", count.ToString()); BadgeNotification badge = new BadgeNotification(badgeXml); BadgeUpdateManager.CreateBadgeUpdaterForApplication().Update(badge); // Update the app data UpdateAppData(toasts); taskInstance.Progress = 100; } }