質問編集履歴
1
コードの修正
test
CHANGED
File without changes
|
test
CHANGED
@@ -42,10 +42,16 @@
|
|
42
42
|
val dateFormat = SimpleDateFormat("yyyy-MM-dd")
|
43
43
|
val date = dateFormat.parse(strDate)
|
44
44
|
calendar.setTime(date)
|
45
|
-
events.add(EventDay(calendar, R.drawable.icon
|
45
|
+
events.add(EventDay(calendar, R.drawable.icon)
|
46
|
-
calendarView.setEvents(events)
|
47
46
|
cursor.moveToNext()
|
48
47
|
}
|
48
|
+
calendarView.setEvents(events)
|
49
|
+
|
50
|
+
/*例えばここでイベントが付与されている日数を取得したければ↓で済むと思います。*/
|
51
|
+
イベントが付与されている日数=DBに格納されてある数=cursor.count()
|
52
|
+
/*しかし、月毎にイベントが付与されている日数を取得したい場合、どのような処理で
|
53
|
+
取得できるのかわからない状況です。calenderから月を指定してイベント数を取得する
|
54
|
+
方法等はあるのでしょうか?
|
49
55
|
}
|
50
56
|
}
|
51
57
|
}
|