private void CreateNotification(string title, string description) { var notification = new SampleNotification(Guid.NewGuid()) { Title = title, AlwaysVisibleDetails = new List <string> { description }, AllowsUserToDismiss = true }; _notificationGroup.Notifications.Add(notification); Action action = () => ClearNotification(notification); var clearNotificationCommand = new NotificationCommand(action); notification.ClearNotificationAction = clearNotificationCommand; }
private void ClearNotification(SampleNotification notification) { _eventAggregator.Publish(new RemoveStudioNotificationFromGroupEvent(NotificationGroupId, notification.Id)); }