mirror of
https://github.com/M66B/FairEmail.git
synced 2024-12-22 07:42:52 +00:00
Fixed selecting messages of a week
This commit is contained in:
parent
3fbff12889
commit
d30538ae13
1 changed files with 7 additions and 1 deletions
|
@ -1230,7 +1230,13 @@ public class FragmentMessages extends FragmentBase
|
||||||
cal.set(Calendar.SECOND, 0);
|
cal.set(Calendar.SECOND, 0);
|
||||||
cal.set(Calendar.MILLISECOND, 0);
|
cal.set(Calendar.MILLISECOND, 0);
|
||||||
|
|
||||||
cal.add(Calendar.DATE, 1);
|
if (date_week) {
|
||||||
|
cal.setMinimalDaysInFirstWeek(4); // ISO 8601
|
||||||
|
cal.setFirstDayOfWeek(Calendar.MONDAY);
|
||||||
|
cal.set(Calendar.DAY_OF_WEEK, Calendar.MONDAY);
|
||||||
|
cal.add(Calendar.DATE, 7);
|
||||||
|
} else
|
||||||
|
cal.add(Calendar.DATE, 1);
|
||||||
long to = cal.getTimeInMillis();
|
long to = cal.getTimeInMillis();
|
||||||
|
|
||||||
cal.add(Calendar.DATE, date_week ? -7 : -1);
|
cal.add(Calendar.DATE, date_week ? -7 : -1);
|
||||||
|
|
Loading…
Reference in a new issue