For setting the images i am doing like this
func calendar(_ calendar: FSCalendar, imageFor date: Date) ->
UIImage? {
let day: Int! = self.gregorian.component(.day, from: date)
if day == 6 || day == 10{
return UIImage(named: "event_calender")
}else if day == 7 || day == 14{
return UIImage(named: "holiday_calender_line")
}
else if day == 7 || day == 14{
return UIImage(named: "birthday_calender_line")
}
else{
return [13,4].contains(day) ? UIImage(named: "icon_cat") : nil
}
}
but how i can change the seleted date image from this delegate method
func calendar(_ calendar: FSCalendar, didSelect date: Date, at monthPosition: FSCalendarMonthPosition) {
print("calendar did select date \(self.formatter.string(from: date))")
}
say current image is "holiday_calender_line" and on selection imwant to change with "holiday_calender_solid".
try this ..