Closed Bug 1753558 Opened 2 years ago Closed 2 years ago

Upgrade main calendar views to use CalFilterMixin instead of CalendarViewRefreshJob

Categories

(Calendar :: Calendar Frontend, enhancement)

enhancement

Tracking

(thunderbird_esr91 wontfix)

RESOLVED FIXED
99 Branch
Tracking Status
thunderbird_esr91 --- wontfix

People

(Reporter: darktrojan, Assigned: darktrojan)

References

(Blocks 2 open bugs)

Details

Attachments

(6 files, 2 obsolete files)

In bug 1727711 I built a new component for getting events from the calendars to the UI. I connected it to the Today Pane agenda, and it's been there long enough now that I'm confident it's good. In this bug I'll connect it to the main calendar views (day, week, multi-week, month).

This ties the calendar views to the calendars via CalFilterMixin instead of via CalendarViewRefreshJob and fixes a few related oddities along the way.

Some changes to calFilter were necessary to enable showing only incomplete tasks without causing a bit mess.
Some changes to CalFilterMixin were made so that tests can get a Promise which resolves when a view has finished loading items. This will be improved in a following patch.

The Promise introduced in the last patch should reject if something causes the view to be invalid while it is still loading. This could happen if the date of the view changes or a refresh is forced.

Depends on D139251

I've decided I don't like the abbreviated name CalendarFilterMixin. And we should use private members to avoid cluttering subclasses and potentially causing issues.

Depends on D139252

We don't use this file. It's just lying around, not referenced anywhere.

To use calFilter on the main calendar views, we need to be able to specify whether or not completed tasks are included.
However we need to preserve the old functionality until we can replace the task lists.

Depends on D139446

I've added a Promise which resolves when all items from all calendars have loaded, or rejects if the loading becomes invalid by the parameters changing. This will help speed up tests by removing an arbitrary wait time on each view load.

I renamed it from CalFilterMixin to CalendarFilterMixin as that seems a better fit. And all of the private members are now properly private to avoid cluttering up subclasses.

Depends on D139447

Attachment #9264779 - Attachment is obsolete: true
Attachment #9264780 - Attachment is obsolete: true
Attachment #9264778 - Attachment description: Bug 1753558 - Make CalendarBaseView a subclass of CalFilterMixin. r=henry → Bug 1753558 - Make CalendarBaseView a subclass of CalendarFilterMixin. r=henry

Pushed by geoff@darktrojan.net:
https://hg.mozilla.org/comm-central/rev/45455c783e96
Remove unused calIDecoratedView. r=john.bieling

Status: ASSIGNED → RESOLVED
Closed: 2 years ago
Resolution: --- → FIXED

I knew that would happen. :-(

Status: RESOLVED → REOPENED
Resolution: FIXED → ---
Target Milestone: --- → 99 Branch
Attachment #9265089 - Attachment description: Bug 1753558 - Improve CalendarFilterMixin for new uses. r=henry → Bug 1753558 - Improve CalFilterMixin for new uses. r=henry
Blocks: 1757341

Pushed by geoff@darktrojan.net:
https://hg.mozilla.org/comm-central/rev/d4a1a26aad21
Improve calFilter for new uses. r=henry
https://hg.mozilla.org/comm-central/rev/91720fcc1778
Improve CalFilterMixin for new uses. r=henry

Status: REOPENED → RESOLVED
Closed: 2 years ago2 years ago
Resolution: --- → FIXED
Status: RESOLVED → REOPENED
Resolution: FIXED → ---

Pushed by geoff@darktrojan.net:
https://hg.mozilla.org/comm-central/rev/c48d5def07a6
Drop showDaysOutsideMonth in CalendarMonthBaseView. r=henry

Status: REOPENED → RESOLVED
Closed: 2 years ago2 years ago
Resolution: --- → FIXED

One of these days I'm going to learn about the leave-open keyword and when to use it.

Status: RESOLVED → REOPENED
Resolution: FIXED → ---
Keywords: leave-open
Pushed by geoff@darktrojan.net:
https://hg.mozilla.org/comm-central/rev/79b9ea2e5932
Make CalendarBaseView a subclass of CalendarFilterMixin. r=henry

The item type filter was matching all tasks, even if we only wanted incomplete tasks.

Keywords: leave-open

Pushed by geoff@darktrojan.net:
https://hg.mozilla.org/comm-central/rev/0c4ad7b846e2
Fix calendar filter handling of tasks that change completion status. r=henry

Status: REOPENED → RESOLVED
Closed: 2 years ago2 years ago
Resolution: --- → FIXED
Regressions: 1774117
Regressions: 1795176
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: