Toasts – Blame information for rev 55
?pathlinks?
Rev | Author | Line No. | Line |
---|---|---|---|
41 | office | 1 | using System; |
2 | using System.Collections.Generic; |
||
3 | using System.ComponentModel; |
||
4 | using System.Drawing; |
||
5 | using System.Linq; |
||
6 | using System.Runtime.CompilerServices; |
||
7 | using System.Text; |
||
8 | using System.Threading.Tasks; |
||
55 | office | 9 | using Toasts.Annotations; |
10 | |||
41 | office | 11 | namespace Toasts |
12 | { |
||
13 | public class ToastDisplayData : INotifyPropertyChanged |
||
14 | { |
||
49 | office | 15 | private string _userAgent; |
41 | office | 16 | private string _title; |
17 | private string _body; |
||
18 | private bool _enableChime; |
||
19 | private byte[] _chime; |
||
20 | private int _lingerTime; |
||
21 | private Image _image; |
||
22 | private string _content; |
||
43 | office | 23 | private float _contentHeight; |
24 | private Point _pinPoint; |
||
25 | private bool _enablePin; |
||
55 | office | 26 | private Proxy _proxy; |
43 | office | 27 | |
41 | office | 28 | public string Title |
29 | { |
||
30 | get => _title; |
||
31 | set |
||
32 | { |
||
33 | if (value == _title) return; |
||
34 | _title = value; |
||
35 | OnPropertyChanged(); |
||
36 | } |
||
37 | } |
||
38 | |||
39 | public string Body |
||
40 | { |
||
41 | get => _body; |
||
42 | set |
||
43 | { |
||
44 | if (value == _body) return; |
||
45 | _body = value; |
||
46 | OnPropertyChanged(); |
||
47 | } |
||
48 | } |
||
49 | |||
50 | public float ContentHeight |
||
51 | { |
||
52 | get => _contentHeight; |
||
53 | set |
||
54 | { |
||
55 | if (value == _contentHeight) return; |
||
56 | _contentHeight = value; |
||
57 | OnPropertyChanged(); |
||
58 | } |
||
49 | office | 59 | } |
60 | |||
61 | public string UserAgent |
||
62 | { |
||
63 | get => _userAgent; |
||
64 | set |
||
65 | { |
||
66 | if (value == _userAgent) return; |
||
67 | _userAgent = value; |
||
68 | OnPropertyChanged(); |
||
69 | } |
||
41 | office | 70 | } |
71 | |||
72 | public bool EnableChime |
||
73 | { |
||
74 | get => _enableChime; |
||
75 | set |
||
76 | { |
||
77 | if (value == _enableChime) return; |
||
78 | _enableChime = value; |
||
79 | OnPropertyChanged(); |
||
80 | } |
||
81 | } |
||
82 | |||
83 | public byte[] Chime |
||
84 | { |
||
85 | get => _chime; |
||
86 | set |
||
87 | { |
||
88 | if (Equals(value, _chime)) return; |
||
89 | _chime = value; |
||
90 | OnPropertyChanged(); |
||
91 | } |
||
92 | } |
||
93 | |||
94 | public int LingerTime |
||
95 | { |
||
96 | get => _lingerTime; |
||
97 | set |
||
98 | { |
||
99 | if (value == _lingerTime) return; |
||
100 | _lingerTime = value; |
||
101 | OnPropertyChanged(); |
||
102 | } |
||
103 | } |
||
104 | |||
105 | public Image Image |
||
106 | { |
||
107 | get => _image; |
||
108 | set |
||
109 | { |
||
110 | if (Equals(value, _image)) return; |
||
111 | _image = value; |
||
112 | OnPropertyChanged(); |
||
113 | } |
||
114 | } |
||
115 | |||
116 | public string Content |
||
117 | { |
||
118 | get => _content; |
||
119 | set |
||
120 | { |
||
121 | if (value == _content) return; |
||
122 | _content = value; |
||
123 | OnPropertyChanged(); |
||
124 | } |
||
43 | office | 125 | } |
126 | |||
127 | public Point PinPoint |
||
128 | { |
||
129 | get => _pinPoint; |
||
130 | set |
||
131 | { |
||
132 | if (value == _pinPoint) return; |
||
133 | |||
134 | _pinPoint = value; |
||
135 | OnPropertyChanged(); |
||
136 | } |
||
41 | office | 137 | } |
43 | office | 138 | |
139 | public bool EnablePin |
||
140 | { |
||
141 | get => _enablePin; |
||
142 | set |
||
143 | { |
||
144 | if (value == _enablePin) return; |
||
145 | |||
146 | _enablePin = value; |
||
147 | OnPropertyChanged(); |
||
148 | } |
||
149 | } |
||
150 | |||
55 | office | 151 | public Proxy Proxy |
152 | { |
||
153 | get => _proxy; |
||
154 | set |
||
155 | { |
||
156 | if (Equals(value, _proxy)) return; |
||
157 | _proxy = value; |
||
158 | OnPropertyChanged(); |
||
159 | } |
||
160 | } |
||
161 | |||
162 | [UsedImplicitly] |
||
41 | office | 163 | public ToastDisplayData() |
164 | { |
||
165 | |||
166 | } |
||
167 | |||
168 | public event PropertyChangedEventHandler PropertyChanged; |
||
169 | |||
170 | protected virtual void OnPropertyChanged([CallerMemberName] string propertyName = null) |
||
171 | { |
||
172 | PropertyChanged?.Invoke(this, new PropertyChangedEventArgs(propertyName)); |
||
173 | } |
||
174 | } |
||
175 | } |