elm_calendar: Add enum to mark display every day before event day.
Summary: There was no way to add marks on every day before event day. The user may want to add mark something on every day before today. (passed mark or disable etc...) Test Plan: Run elementary_test Calling "elm_calendar_mark_add()" with ELM_CALENDAR_REVERSE_DAILY value. Reviewers: cedric, Hermet Subscribers: cedric, jpeg Differential Revision: https://phab.enlightenment.org/D4276
This commit is contained in:
parent
829f298589
commit
81db8e9f32
|
@ -664,6 +664,20 @@ _populate(Evas_Object *obj)
|
|||
((mtime->tm_year == year) && (mtime->tm_mon <= month))))
|
||||
_cit_mark(obj, maxdays + sd->first_day_it - 1, mark->mark_type);
|
||||
break;
|
||||
|
||||
case ELM_CALENDAR_REVERSE_DAILY:
|
||||
if (((mtime->tm_year == year) && (mtime->tm_mon > month)) ||
|
||||
(mtime->tm_year > year))
|
||||
day = maxdays;
|
||||
else if ((mtime->tm_year == year) && (mtime->tm_mon == month))
|
||||
day = mtime->tm_mday - 1;
|
||||
else
|
||||
break;
|
||||
for (; day >= 1; day--)
|
||||
_cit_mark(obj, day + sd->first_day_it - 1,
|
||||
mark->mark_type);
|
||||
break;
|
||||
|
||||
}
|
||||
}
|
||||
sd->filling = EINA_FALSE;
|
||||
|
|
|
@ -18,9 +18,9 @@ enum Elm.Calendar.Mark.Repeat.Type
|
|||
weekly, [[Marks will be displayed every week after event day (inclusive) - i.e. each seven days.]]
|
||||
monthly, [[Marks will be displayed every month day that coincides to event day. E.g.: if an event is set to 30th Jan, no marks will be displayed on Feb, but will be displayed on 30th Mar.]]
|
||||
annually, [[Marks will be displayed every year that coincides to event day (and month). E.g. an event added to 30th Jan 2012 will be repeated on 30th Jan 2013.]]
|
||||
last_day_of_month [[Marks will be displayed every last day of month after event day (inclusive).
|
||||
|
||||
last_day_of_month, [[Marks will be displayed every last day of month after event day (inclusive).
|
||||
@since 1.7]]
|
||||
reverse_daily [[Marks will be displayed every day before event day. @since 1.19]]
|
||||
}
|
||||
|
||||
enum Elm.Calendar.Weekday
|
||||
|
|
Loading…
Reference in New Issue