1 |
|
|
2 |
|
|
3 |
|
@author |
4 |
|
|
5 |
|
package pl.magot.vetch.ancal.activities; |
6 |
|
|
7 |
|
|
8 |
|
import java.util.*; |
9 |
|
import pl.magot.vetch.widgets.*; |
10 |
|
import pl.magot.vetch.ancal.AnCalDateUtils; |
11 |
|
import pl.magot.vetch.ancal.CommonActivity; |
12 |
|
import pl.magot.vetch.ancal.R; |
13 |
|
import pl.magot.vetch.ancal.RepeatData; |
14 |
|
import pl.magot.vetch.ancal.database.DataRowAppointment; |
15 |
|
import pl.magot.vetch.ancal.database.DataTable; |
16 |
|
import android.content.Intent; |
17 |
|
import android.os.Bundle; |
18 |
|
import android.widget.*; |
19 |
|
import android.view.*; |
20 |
|
|
21 |
|
|
22 |
|
|
|
|
| 87,6% |
Uncovered Elements: 33 (267) |
Complexity: 63 |
Complexity Density: 0,36 |
|
23 |
|
public class ActivityAppointment extends CommonActivity |
24 |
|
{ |
25 |
|
|
26 |
|
private Calendar dateStart = null; |
27 |
|
private DataRowAppointment dataRow = null; |
28 |
|
private DataTable dataTable = null; |
29 |
|
|
30 |
|
|
31 |
|
private TouchEdit edSubject = null; |
32 |
|
private Button btnStartDate = null; |
33 |
|
private Button btnStartTime = null; |
34 |
|
private CheckBox chkAllDay = null; |
35 |
|
private CheckBox chkAlarm = null; |
36 |
|
private Button btnRepeatSelect = null; |
37 |
|
|
38 |
|
private ImageButton btnDelete = null; |
39 |
|
private ImageButton btnSave = null; |
40 |
|
|
41 |
|
|
42 |
|
private int iRepeatType = -1; |
43 |
|
private int iRepeatEvery = 0; |
44 |
|
private Calendar dateEndOn = null; |
45 |
|
|
46 |
|
|
|
|
| 84,6% |
Uncovered Elements: 2 (13) |
Complexity: 3 |
Complexity Density: 0,33 |
|
47 |
9
|
@Override... |
48 |
|
public void onCreate(Bundle icicle) |
49 |
|
{ |
50 |
9
|
super.onCreate(icicle); |
51 |
9
|
setContentView(R.layout.appointment); |
52 |
|
|
53 |
|
|
54 |
9
|
dataRow = new DataRowAppointment(userdb); |
55 |
9
|
dataTable = new DataTable(dataRow); |
56 |
|
|
57 |
|
|
58 |
9
|
if (GetStartMode() == StartMode.EDIT) |
59 |
3
|
if (!OpenDataForEdit(dataTable)) |
60 |
0
|
finish(); |
61 |
|
|
62 |
|
|
63 |
9
|
InitViews(); |
64 |
9
|
InitState(); |
65 |
|
} |
66 |
|
|
|
|
| 100% |
Uncovered Elements: 0 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
67 |
9
|
@Override... |
68 |
|
public void onStart() |
69 |
|
{ |
70 |
9
|
super.onStart(); |
71 |
|
|
72 |
|
} |
73 |
|
|
|
|
| 100% |
Uncovered Elements: 0 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
74 |
21
|
@Override... |
75 |
|
public void onResume() |
76 |
|
{ |
77 |
21
|
super.onResume(); |
78 |
|
|
79 |
|
} |
80 |
|
|
|
|
| 100% |
Uncovered Elements: 0 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
81 |
21
|
@Override... |
82 |
|
public void onPause() |
83 |
|
{ |
84 |
21
|
super.onPause(); |
85 |
|
|
86 |
|
} |
87 |
|
|
|
|
| 100% |
Uncovered Elements: 0 (15) |
Complexity: 1 |
Complexity Density: 0,07 |
|
88 |
9
|
private void InitViews()... |
89 |
|
{ |
90 |
9
|
edSubject = (TouchEdit)findViewById(R.id.edAppointmentSubject); |
91 |
9
|
edSubject.setOnOpenKeyboard(new TouchEdit.OnOpenKeyboard() |
92 |
|
{ |
|
|
| 100% |
Uncovered Elements: 0 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
93 |
5
|
public void OnOpenKeyboardEvent()... |
94 |
|
{ |
95 |
5
|
KeyboardWidget.Open(ActivityAppointment.this, edSubject.getText().toString()); |
96 |
|
} |
97 |
|
}); |
98 |
|
|
99 |
9
|
btnStartDate = (Button)findViewById(R.id.btnAppointmentStartDate); |
100 |
9
|
btnStartTime = (Button)findViewById(R.id.btnAppointmentStartTime); |
101 |
9
|
chkAllDay = (CheckBox)findViewById(R.id.chkAppointmentAllDay); |
102 |
9
|
chkAlarm = (CheckBox)findViewById(R.id.chkAppointmentAlarm); |
103 |
|
|
104 |
9
|
btnRepeatSelect = (Button)findViewById(R.id.btnRepeatSelect); |
105 |
9
|
btnRepeatSelect.setOnClickListener(new View.OnClickListener() { |
|
|
| 100% |
Uncovered Elements: 0 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
106 |
4
|
public void onClick(View v) {... |
107 |
4
|
OpenRepeatDialog(); |
108 |
|
} |
109 |
|
}); |
110 |
|
|
111 |
9
|
btnSave = (ImageButton)findViewById(R.id.btnAppointmentSave); |
112 |
9
|
btnSave.setOnClickListener(new View.OnClickListener() { |
|
|
| 100% |
Uncovered Elements: 0 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
113 |
8
|
public void onClick(View v) {... |
114 |
8
|
SaveData(); |
115 |
|
} |
116 |
|
}); |
117 |
|
|
118 |
9
|
btnDelete = (ImageButton)findViewById(R.id.btnAppointmentDelete); |
119 |
9
|
btnDelete.setOnClickListener(new View.OnClickListener() { |
|
|
| 100% |
Uncovered Elements: 0 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
120 |
1
|
public void onClick(View v) {... |
121 |
1
|
DeleteData(); |
122 |
|
} |
123 |
|
}); |
124 |
|
|
125 |
9
|
btnStartDate.setOnClickListener(new View.OnClickListener() { |
|
|
| 100% |
Uncovered Elements: 0 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
126 |
2
|
public void onClick(View v) {... |
127 |
|
|
128 |
2
|
DateWidget.Open(ActivityAppointment.this, false, dateStart, prefs.iFirstDayOfWeek); |
129 |
|
|
130 |
|
} |
131 |
|
}); |
132 |
|
|
133 |
9
|
btnStartTime.setOnClickListener(new View.OnClickListener() { |
|
|
| 100% |
Uncovered Elements: 0 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
134 |
2
|
public void onClick(View v) {... |
135 |
|
|
136 |
2
|
TimeWidget.Open(ActivityAppointment.this, false, prefs.b24HourMode, |
137 |
|
dateStart.get(Calendar.HOUR_OF_DAY), dateStart.get(Calendar.MINUTE)); |
138 |
|
|
139 |
|
} |
140 |
|
}); |
141 |
|
|
142 |
9
|
chkAllDay.setOnClickListener(new View.OnClickListener() { |
|
|
| 100% |
Uncovered Elements: 0 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
143 |
4
|
public void onClick(View v) {... |
144 |
4
|
UpdateStartDateTimeView(); |
145 |
|
} |
146 |
|
}); |
147 |
|
|
148 |
|
} |
149 |
|
|
|
|
| 81,2% |
Uncovered Elements: 3 (16) |
Complexity: 5 |
Complexity Density: 0,62 |
|
150 |
6
|
private void SetStartDateByAgendaView(Calendar calDate)... |
151 |
|
{ |
152 |
6
|
if (getIntent() != null) |
153 |
|
{ |
154 |
6
|
Bundle extras = getIntent().getExtras(); |
155 |
6
|
if (extras != null) |
156 |
|
{ |
157 |
6
|
if (extras.containsKey(CommonActivity.bundleAgendaView)) |
158 |
|
{ |
159 |
6
|
int iView = extras.getInt(CommonActivity.bundleAgendaView); |
160 |
6
|
if (iView == 1) |
161 |
|
{ |
162 |
2
|
long lStartDate = extras.getLong(CommonActivity.bundleAgendaViewStartDate); |
163 |
2
|
calDate.setTimeInMillis(lStartDate); |
164 |
|
} |
165 |
|
} |
166 |
|
} |
167 |
|
} |
168 |
|
} |
169 |
|
|
|
|
| 38,9% |
Uncovered Elements: 11 (18) |
Complexity: 5 |
Complexity Density: 0,5 |
|
170 |
6
|
private void SetStartTimeForDayAgendaView(Calendar calDate)... |
171 |
|
{ |
172 |
6
|
if (getIntent() != null) |
173 |
|
{ |
174 |
6
|
Bundle extras = getIntent().getExtras(); |
175 |
6
|
if (extras != null) |
176 |
|
{ |
177 |
6
|
if (extras.containsKey(CommonActivity.bundleHourOfDay)) |
178 |
|
{ |
179 |
0
|
int iView = extras.getInt(CommonActivity.bundleAgendaView); |
180 |
0
|
if (iView == 1) |
181 |
|
{ |
182 |
0
|
int iHourOfDay = extras.getInt(CommonActivity.bundleHourOfDay); |
183 |
0
|
int iMinutes = extras.getInt(CommonActivity.bundleMinutes); |
184 |
0
|
calDate.set(Calendar.HOUR_OF_DAY, iHourOfDay); |
185 |
0
|
calDate.set(Calendar.MINUTE, iMinutes); |
186 |
|
} |
187 |
|
} |
188 |
|
} |
189 |
|
} |
190 |
|
} |
191 |
|
|
|
|
| 90,9% |
Uncovered Elements: 1 (11) |
Complexity: 2 |
Complexity Density: 0,22 |
|
192 |
6
|
private void updateStartDateTimeForNewAppointment(Calendar calDate)... |
193 |
|
{ |
194 |
6
|
int iHour = calDate.get(Calendar.HOUR_OF_DAY); |
195 |
6
|
int iMinute = calDate.get(Calendar.MINUTE); |
196 |
|
|
197 |
6
|
if (iHour < 23) |
198 |
6
|
iHour += 1; |
199 |
6
|
iMinute = 0; |
200 |
|
|
201 |
6
|
calDate.set(Calendar.HOUR_OF_DAY, iHour); |
202 |
6
|
calDate.set(Calendar.MINUTE, iMinute); |
203 |
6
|
calDate.set(Calendar.SECOND, 0); |
204 |
6
|
calDate.set(Calendar.MILLISECOND, 0); |
205 |
|
} |
206 |
|
|
|
|
| 100% |
Uncovered Elements: 0 (38) |
Complexity: 4 |
Complexity Density: 0,12 |
|
207 |
9
|
private void InitState()... |
208 |
|
{ |
209 |
|
|
210 |
9
|
String sSubTitle = utils.GetResStr(R.string.titleDefaultAppointment); |
211 |
|
|
212 |
|
|
213 |
9
|
dateStart = Calendar.getInstance(); |
214 |
9
|
dateEndOn = Calendar.getInstance(); |
215 |
|
|
216 |
9
|
dataRow.SetDuration(prefs.iMinutesDuration); |
217 |
|
|
218 |
|
|
219 |
9
|
if (GetStartMode() == StartMode.NEW) |
220 |
|
{ |
221 |
6
|
sSubTitle = utils.GetResStr(R.string.titleNewAppointment); |
222 |
6
|
btnDelete.setVisibility(View.INVISIBLE); |
223 |
|
|
224 |
|
|
225 |
6
|
SetStartDateByAgendaView(dateStart); |
226 |
6
|
updateStartDateTimeForNewAppointment(dateStart); |
227 |
6
|
SetStartTimeForDayAgendaView(dateStart); |
228 |
|
|
229 |
6
|
chkAllDay.setChecked(false); |
230 |
6
|
chkAlarm.setChecked(true); |
231 |
|
|
232 |
|
|
233 |
6
|
iRepeatType = 0; |
234 |
6
|
iRepeatEvery = 1; |
235 |
6
|
dateEndOn.setTimeInMillis(0); |
236 |
|
} |
237 |
|
|
238 |
|
|
239 |
9
|
if (GetStartMode() == StartMode.EDIT) |
240 |
|
{ |
241 |
3
|
sSubTitle = utils.GetResStr(R.string.titleEditAppointment); |
242 |
|
|
243 |
3
|
dateStart.setTimeInMillis(dataRow.GetStartDate().getTimeInMillis()); |
244 |
|
|
245 |
3
|
btnDelete.setVisibility(View.VISIBLE); |
246 |
3
|
edSubject.setText(dataRow.GetSubject()); |
247 |
3
|
chkAllDay.setChecked(dataRow.GetAllDay()); |
248 |
3
|
chkAlarm.setChecked(dataRow.GetAlarm()); |
249 |
|
|
250 |
|
|
251 |
3
|
iRepeatType = dataRow.GetRepeat().GetRepeatTypeAsInt(); |
252 |
3
|
iRepeatEvery = dataRow.GetRepeat().GetEvery(); |
253 |
3
|
dateEndOn.setTimeInMillis(dataRow.GetRepeat().GetEndOnDate().getTimeInMillis()); |
254 |
|
} |
255 |
|
|
256 |
9
|
restoreStateFromFreezeIfRequired(); |
257 |
|
|
258 |
9
|
SetActivityTitle(sSubTitle); |
259 |
9
|
UpdateStartDateTimeView(); |
260 |
|
|
261 |
9
|
UpdateRepeatInfo(); |
262 |
|
|
263 |
|
|
264 |
9
|
edSubject.requestFocus(); |
265 |
9
|
if (GetStartMode() == StartMode.EDIT) |
266 |
3
|
edSubject.setSelection(edSubject.length()); |
267 |
|
} |
268 |
|
|
|
|
| 100% |
Uncovered Elements: 0 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
269 |
13
|
private void UpdateRepeatInfo()... |
270 |
|
{ |
271 |
13
|
btnRepeatSelect.setText(GetRepeatInfo()); |
272 |
|
} |
273 |
|
|
|
|
| 100% |
Uncovered Elements: 0 (22) |
Complexity: 6 |
Complexity Density: 0,5 |
|
274 |
13
|
private String GetRepeatInfo()... |
275 |
|
{ |
276 |
13
|
String s = utils.GetResStr(R.string.strRepeatTypeNone); |
277 |
13
|
String sUntil = utils.GetResStr(R.string.strRepeatInfoUntil); |
278 |
13
|
String sEndDate = (dateEndOn.getTimeInMillis() == 0)?"":" " + sUntil + " " + AnCalDateUtils.formatMediumDate(this, dateEndOn); |
279 |
|
|
280 |
13
|
if (iRepeatType == 1) |
281 |
2
|
s = String.format(utils.GetResStr(R.string.strRepeatInfoDaily), iRepeatEvery, sEndDate); |
282 |
|
|
283 |
13
|
if (iRepeatType == 2) |
284 |
2
|
s = String.format(utils.GetResStr(R.string.strRepeatInfoWeekly), iRepeatEvery, sEndDate); |
285 |
|
|
286 |
13
|
if (iRepeatType == 3) |
287 |
2
|
s = String.format(utils.GetResStr(R.string.strRepeatInfoMonthly), iRepeatEvery, sEndDate); |
288 |
|
|
289 |
13
|
if (iRepeatType == 4) |
290 |
1
|
s = String.format(utils.GetResStr(R.string.strRepeatInfoYearly), sEndDate); |
291 |
13
|
return s; |
292 |
|
} |
293 |
|
|
|
|
| 100% |
Uncovered Elements: 0 (6) |
Complexity: 2 |
Complexity Density: 0,5 |
|
294 |
17
|
private void UpdateStartDateTimeView()... |
295 |
|
{ |
296 |
17
|
btnStartDate.setText(AnCalDateUtils.formatMediumDate(this, dateStart)); |
297 |
17
|
if (chkAllDay.isChecked()) |
298 |
|
{ |
299 |
8
|
btnStartTime.setText(utils.GetResStr(R.string.labNoTime)); |
300 |
|
} else { |
301 |
9
|
btnStartTime.setText(AnCalDateUtils.formatTime(this, dateStart)); |
302 |
|
} |
303 |
|
} |
304 |
|
|
|
|
| - |
Uncovered Elements: 0 (0) |
Complexity: 1 |
Complexity Density: - |
|
305 |
0
|
protected void onSizeChanged(int w, int h, int oldw, int oldh)... |
306 |
|
{ |
307 |
|
|
308 |
|
} |
309 |
|
|
|
|
| 81,2% |
Uncovered Elements: 3 (16) |
Complexity: 4 |
Complexity Density: 0,33 |
|
310 |
8
|
public void SaveData()... |
311 |
|
{ |
312 |
|
|
313 |
8
|
if ((iRepeatType == 0) && (DateBeforeNow(dateStart))) |
314 |
0
|
return; |
315 |
|
|
316 |
8
|
dataRow.SetSubject(edSubject.getText().toString()); |
317 |
8
|
dataRow.SetStartDate(dateStart); |
318 |
8
|
dataRow.SetAllDay(chkAllDay.isChecked()); |
319 |
8
|
dataRow.SetAlarm(chkAlarm.isChecked()); |
320 |
|
|
321 |
|
|
322 |
8
|
RepeatData rd = dataRow.GetRepeat(); |
323 |
8
|
rd.SetRepeatTypeAsInt(iRepeatType); |
324 |
8
|
rd.SetEvery(iRepeatEvery); |
325 |
8
|
rd.SetEndOnDate(dateEndOn.getTimeInMillis()); |
326 |
|
|
327 |
8
|
if (SaveDataToTable(dataTable)) |
328 |
8
|
CloseActivity(dataTable); |
329 |
|
} |
330 |
|
|
|
|
| 75% |
Uncovered Elements: 1 (4) |
Complexity: 2 |
Complexity Density: 1 |
|
331 |
1
|
public void DeleteData()... |
332 |
|
{ |
333 |
1
|
if (DeleteDataFromTable(dataTable)) |
334 |
1
|
CloseActivity(dataTable); |
335 |
|
} |
336 |
|
|
|
|
| 94,7% |
Uncovered Elements: 2 (38) |
Complexity: 9 |
Complexity Density: 0,35 |
|
337 |
13
|
@Override... |
338 |
|
protected void onActivityResult(int requestCode, int resultCode, Intent data) |
339 |
|
{ |
340 |
13
|
super.onActivityResult(requestCode, resultCode, data); |
341 |
|
|
342 |
13
|
Bundle extras = CommonActivity.getIntentExtras(data); |
343 |
13
|
if (extras != null) |
344 |
|
{ |
345 |
|
|
346 |
|
|
347 |
13
|
if (ActivityAppointmentRepeat.GetActivityResult(requestCode, resultCode, extras)) |
348 |
|
{ |
349 |
4
|
iRepeatType = ActivityAppointmentRepeat.getExtraRepeatType(extras); |
350 |
4
|
iRepeatEvery = ActivityAppointmentRepeat.getExtraRepeatEvery(extras); |
351 |
4
|
dateEndOn.setTimeInMillis(ActivityAppointmentRepeat.getExtraRepeatEndOnDate(extras)); |
352 |
4
|
UpdateRepeatInfo(); |
353 |
4
|
return; |
354 |
|
} |
355 |
|
|
356 |
|
|
357 |
9
|
if (requestCode == DateWidget.SELECT_DATE_REQUEST) |
358 |
|
{ |
359 |
2
|
final long lDate = DateWidget.GetSelectedDateOnActivityResult(requestCode, resultCode, extras, dateStart); |
360 |
2
|
if (lDate != -1) |
361 |
|
{ |
362 |
2
|
UpdateStartDateTimeView(); |
363 |
2
|
return; |
364 |
|
} |
365 |
|
} |
366 |
|
|
367 |
|
|
368 |
7
|
if ((requestCode == TimeWidget.SELECT_TIME_REQUEST) && (resultCode == RESULT_OK)) |
369 |
|
{ |
370 |
2
|
final int iHour = TimeWidget.GetSelectedTimeHourOnActivityResult(requestCode, resultCode, extras); |
371 |
2
|
final int iMinute = TimeWidget.GetSelectedTimeMinuteOnActivityResult(requestCode, resultCode, extras); |
372 |
2
|
dateStart.set(Calendar.HOUR_OF_DAY, iHour); |
373 |
2
|
dateStart.set(Calendar.MINUTE, iMinute); |
374 |
2
|
chkAllDay.setChecked(false); |
375 |
2
|
UpdateStartDateTimeView(); |
376 |
2
|
return; |
377 |
|
} |
378 |
|
|
379 |
|
|
380 |
5
|
if ((requestCode == KeyboardWidget.EDIT_TEXT_REQUEST) && (resultCode == RESULT_OK)) |
381 |
|
{ |
382 |
4
|
String sText = KeyboardWidget.GetTextOnActivityResult(requestCode, resultCode, extras); |
383 |
4
|
edSubject.setText(sText); |
384 |
4
|
return; |
385 |
|
} |
386 |
|
|
387 |
|
} |
388 |
|
} |
389 |
|
|
|
|
| 100% |
Uncovered Elements: 0 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
390 |
4
|
public void OpenRepeatDialog()... |
391 |
|
{ |
392 |
4
|
ActivityAppointmentRepeat.OpenRepeatForEdit(this, bundleOtherDataStartup, iRepeatType, iRepeatEvery, dateEndOn.getTimeInMillis()); |
393 |
|
} |
394 |
|
|
|
|
| 83,3% |
Uncovered Elements: 1 (6) |
Complexity: 2 |
Complexity Density: 0,5 |
|
395 |
3
|
@Override... |
396 |
|
public void SaveDateValuesBeforeChange(Bundle data) |
397 |
|
{ |
398 |
3
|
super.SaveDateValuesBeforeChange(data); |
399 |
3
|
if (GetStartMode() == StartMode.EDIT) |
400 |
|
{ |
401 |
3
|
data.putLong("dateStart", dataRow.GetStartDate().getTimeInMillis()); |
402 |
3
|
data.putLong("dateEndOn", dataRow.GetRepeat().GetEndOnDate().getTimeInMillis()); |
403 |
|
} |
404 |
|
} |
405 |
|
|
|
|
| 100% |
Uncovered Elements: 0 (9) |
Complexity: 3 |
Complexity Density: 0,6 |
|
406 |
8
|
@Override... |
407 |
|
public boolean DateValuesChanged(Bundle data) |
408 |
|
{ |
409 |
8
|
super.DateValuesChanged(data); |
410 |
8
|
if (GetStartMode() == StartMode.EDIT) |
411 |
|
{ |
412 |
2
|
if (dateStart.getTimeInMillis() != data.getLong("dateStart")) |
413 |
1
|
return true; |
414 |
|
} |
415 |
7
|
return false; |
416 |
|
} |
417 |
|
|
|
|
| 100% |
Uncovered Elements: 0 (8) |
Complexity: 1 |
Complexity Density: 0,12 |
|
418 |
12
|
@Override... |
419 |
|
protected void onSaveInstanceState(Bundle outState) |
420 |
|
{ |
421 |
12
|
super.onSaveInstanceState(outState); |
422 |
|
|
423 |
12
|
outState.putString("subject", edSubject.getText().toString()); |
424 |
12
|
outState.putBoolean("alarm", chkAlarm.isChecked()); |
425 |
12
|
outState.putLong("dateStart", dateStart.getTimeInMillis()); |
426 |
12
|
outState.putBoolean("allday", chkAllDay.isChecked()); |
427 |
12
|
outState.putInt("repeatType", iRepeatType); |
428 |
12
|
outState.putInt("repeatEvery", iRepeatEvery); |
429 |
12
|
outState.putLong("dateEndOn", dateEndOn.getTimeInMillis()); |
430 |
|
} |
431 |
|
|
|
|
| 0% |
Uncovered Elements: 7 (7) |
Complexity: 1 |
Complexity Density: 0,14 |
|
432 |
0
|
@Override... |
433 |
|
protected void restoreStateFromFreeze() |
434 |
|
{ |
435 |
0
|
edSubject.setText(freeze.getString("subject")); |
436 |
0
|
chkAlarm.setChecked(freeze.getBoolean("alarm")); |
437 |
0
|
dateStart.setTimeInMillis(freeze.getLong("dateStart")); |
438 |
0
|
chkAllDay.setChecked(freeze.getBoolean("allday")); |
439 |
0
|
iRepeatType = freeze.getInt("repeatType"); |
440 |
0
|
iRepeatEvery = freeze.getInt("repeatEvery"); |
441 |
0
|
dateEndOn.setTimeInMillis(freeze.getLong("dateEndOn")); |
442 |
|
} |
443 |
|
|
444 |
|
} |