public static void NotifyWithSettings(this IManageToasts toasts, NotificationModel notification, ChannelSettingsModel.NotifyLevel notifyLevel) { switch (notifyLevel) { case ChannelSettingsModel.NotifyLevel.NoNotification: break; case ChannelSettingsModel.NotifyLevel.NotificationOnly: toasts.AddNotification(notification); break; case ChannelSettingsModel.NotifyLevel.NotificationAndToast: toasts.AddNotification(notification); toasts.FlashWindow(); toasts.ShowToast(); break; case ChannelSettingsModel.NotifyLevel.NotificationAndSound: toasts.AddNotification(notification); toasts.FlashWindow(); toasts.PlaySound(); toasts.ShowToast(); break; } }
public override void DisplayNewToast(IChatState chatState, IManageToasts toastsManager) { if (ListArgument == ListKind.NotInterested) { return; } DoNormalToast(toastsManager); }
public override void DisplayNewToast(IChatState chatState, IManageToasts toastsManager) { var settings = chatState.GetChannelSettingsById(TargetChannelId); if (settings == null) return; var setting = new ChannelSettingPair(settings.JoinLeaveNotifyLevel, settings.JoinLeaveNotifyOnlyForInteresting); DoToast(setting, toastsManager, chatState); }
public override void DisplayNewToast(IChatState chatState, IManageToasts toastsManager) { if (!ApplicationSettings.ShowLoginToasts || !chatState.IsInteresting(Model.TargetCharacter.Name) || chatState.CharacterManager.IsOnList(Model.TargetCharacter.Name, ListKind.IgnoreUpdates, false)) { return; } DoNormalToast(toastsManager); }
public override void DisplayNewToast(IChatState chatState, IManageToasts toastsManager) { if (!ApplicationSettings.ShowStatusToasts || !chatState.IsInteresting(Model.TargetCharacter.Name) || chatState.CharacterManager.IsOnList(Model.TargetCharacter.Name, ListKind.IgnoreUpdates, false)) { return; } DoNormalToast(toastsManager); }
public virtual void DisplayNewToast(IChatState chatState, IManageToasts toastsManager) { if (!Model.TargetChannel.Settings.AlertAboutUpdates) { return; } SetToastData(toastsManager.Toast); toastsManager.AddNotification(Model); toastsManager.ShowToast(); }
internal void DoToast(ChannelSettingPair setting, IManageToasts toastManager, IChatState chatState) { if (setting.OnlyForInteresting && !chatState.IsInteresting(Model.TargetCharacter.Name)) { return; } toastManager.NotifyWithSettings(Model, setting.NotifyLevel); if (setting.NotifyLevel >= ChannelSettingsModel.NotifyLevel.NotificationAndToast) { SetToastData(toastManager.Toast); } }
public override void DisplayNewToast(IChatState chatState, IManageToasts toastsManager) { var settings = chatState.GetChannelSettingsById(TargetChannelId); if (settings == null) { return; } var setting = new ChannelSettingPair(settings.PromoteDemoteNotifyLevel, settings.PromoteDemoteNotifyOnlyForInteresting); DoToast(setting, toastsManager, chatState); }
public override void DisplayNewToast(IChatState chatState, IManageToasts toastsManager) { SetToastData(toastsManager.Toast); toastsManager.Toast.Title = Title; toastsManager.Toast.Navigator = new SimpleNavigator(chat => chat.EventAggregator.GetEvent<RequestChangeTabEvent>().Publish(Channel.Id)); toastsManager.Toast.Content = Context; toastsManager.AddNotification(Model); if (Channel.IsSelected) { if (ApplicationSettings.PlaySoundEvenWhenTabIsFocused) toastsManager.PlaySound(); return; } toastsManager.ShowToast(); toastsManager.PlaySound(); toastsManager.FlashWindow(); }
public override void DisplayNewToast(IChatState chatState, IManageToasts toastsManager) { SetToastData(toastsManager.Toast); toastsManager.Toast.Title = Title; toastsManager.Toast.Navigator = new SimpleNavigator(chat => chat.EventAggregator.GetEvent <RequestChangeTabEvent>().Publish(Channel.Id)); toastsManager.Toast.Content = Context; toastsManager.AddNotification(Model); if (Channel.IsSelected) { if (ApplicationSettings.PlaySoundEvenWhenTabIsFocused) { toastsManager.PlaySound(); } return; } toastsManager.ShowToast(); toastsManager.PlaySound(); toastsManager.FlashWindow(); }
internal void DoNormalToast(IManageToasts toastManager) { SetToastData(toastManager.Toast); toastManager.AddNotification(Model); toastManager.ShowToast(); }
internal void DoLoudToast(IManageToasts toastManager) { DoNormalToast(toastManager); toastManager.PlaySound(); toastManager.FlashWindow(); }
public virtual void DisplayNewToast(IChatState chatState, IManageToasts toastsManager) { if (!Model.TargetChannel.Settings.AlertAboutUpdates) return; SetToastData(toastsManager.Toast); toastsManager.AddNotification(Model); toastsManager.ShowToast(); }
public abstract void DisplayNewToast(IChatState chatState, IManageToasts toastsManager);
public override void DisplayNewToast(IChatState chatState, IManageToasts toastsManager) { DoLoudToast(toastsManager); }
public override void DisplayNewToast(IChatState chatState, IManageToasts toastsManager) { DoNormalToast(toastsManager); }
public override void DisplayNewToast(IChatState chatState, IManageToasts toastsManager) { if (ListArgument == ListKind.NotInterested) return; DoNormalToast(toastsManager); }
internal void DoToast(ChannelSettingPair setting, IManageToasts toastManager, IChatState chatState) { if (setting.OnlyForInteresting && !chatState.IsInteresting(Model.TargetCharacter.Name)) return; toastManager.NotifyWithSettings(Model, setting.NotifyLevel); if (setting.NotifyLevel >= ChannelSettingsModel.NotifyLevel.NotificationAndToast) SetToastData(toastManager.Toast); }
public override void DisplayNewToast(IChatState chatState, IManageToasts toastsManager) { Arguments.DisplayNewToast(chatState, toastsManager); }