HamBook – Rev 54
?pathlinks?
using System.ComponentModel;
using System.Runtime.CompilerServices;
using Configuration.Annotations;
namespace Configuration
{
public class NotificationState : INotifyPropertyChanged
{
private bool _enabled;
private int _lingerTime = 5000;
private NotificationType _type = NotificationType.None;
public int LingerTime
{
get => _lingerTime;
set
{
if (value == _lingerTime) return;
_lingerTime = value;
OnPropertyChanged();
}
}
public bool Enabled
{
get => _enabled;
set
{
if (value == _enabled) return;
_enabled = value;
OnPropertyChanged();
}
}
public NotificationType Type
{
get => _type;
set
{
if (value == _type) return;
_type = value;
OnPropertyChanged();
}
}
public event PropertyChangedEventHandler PropertyChanged;
[NotifyPropertyChangedInvocator]
protected virtual void OnPropertyChanged([CallerMemberName] string propertyName = null)
{
PropertyChanged?.Invoke(this, new PropertyChangedEventArgs(propertyName));
}
}
}
Generated by GNU Enscript 1.6.5.90.