123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133 |
- using System.ComponentModel;
- namespace CyberX8_Core
- {
- public class SignalTowerItem : INotifyPropertyChanged
- {
- public event PropertyChangedEventHandler PropertyChanged;
- public void InvokePropertyChanged(string propertyName)
- {
- if (PropertyChanged != null)
- {
- PropertyChanged(this, new PropertyChangedEventArgs(propertyName));
- }
- }
- private string _name;
- public string Name
- {
- get { return _name; }
- set { _name = value; InvokePropertyChanged("Name"); }
- }
- private bool _isRed;
- public bool IsRed
- {
- get { return _isRed; }
- set
- {
- _isRed = value;
- if (value) IsRedBlinking = false; InvokePropertyChanged("IsRed");
- }
- }
- private bool _isRedBlinking;
- public bool IsRedBlinking
- {
- get { return _isRedBlinking; }
- set
- {
- _isRedBlinking = value;
- if (value) IsRed = false; InvokePropertyChanged("IsRedBlinking");
- }
- }
- private bool _isGreen;
- public bool IsGreen
- {
- get { return _isGreen; }
- set
- {
- _isGreen = value;
- if (value) IsGreenBlinking = false; InvokePropertyChanged("IsGreen");
- }
- }
- private bool _isGreenBlinking;
- public bool IsGreenBlinking
- {
- get { return _isGreenBlinking; }
- set
- {
- _isGreenBlinking = value;
- if (value) IsGreen = false; InvokePropertyChanged("IsGreenBlinking");
- }
- }
- private bool _isBlue;
- public bool IsBlue
- {
- get { return _isBlue; }
- set
- {
- _isBlue = value;
- if (value) IsBlueBlinking = false; InvokePropertyChanged("IsBlue");
- }
- }
- private bool _isBlueBlinking;
- public bool IsBlueBlinking
- {
- get { return _isBlueBlinking; }
- set
- {
- _isBlueBlinking = value;
- if (value) IsBlue = false; InvokePropertyChanged("IsBlueBlinking");
- }
- }
- private bool _isYellow;
- public bool IsYellow
- {
- get { return _isYellow; }
- set
- {
- _isYellow = value;
- if (value) IsYellowBlinking = false; InvokePropertyChanged("IsYellow");
- }
- }
- private bool _isYellowBlinking;
- public bool IsYellowBlinking
- {
- get { return _isYellowBlinking; }
- set
- {
- _isYellowBlinking = value;
- if (value) IsYellow = false; InvokePropertyChanged("IsYellowBlinking");
- }
- }
- private bool _isBuzzer;
- public bool IsBuzzer
- {
- get { return _isBuzzer; }
- set
- {
- _isBuzzer = value;
- if (value) IsBuzzerBlinking = false; InvokePropertyChanged("IsBuzzer");
- }
- }
- private bool _isBuzzerBlinking;
- public bool IsBuzzerBlinking
- {
- get { return _isBuzzerBlinking; }
- set
- {
- _isBuzzerBlinking = value;
- if (value) IsBuzzer = false; InvokePropertyChanged("IsBuzzerBlinking");
- }
- }
- }
- }
|