Fix calendarItemAction persistence in event editor toolbars#64
Fix calendarItemAction persistence in event editor toolbars#64jobisoft merged 5 commits intothunderbird:mainfrom
Conversation
Improves calendarItemAction toolbar persistence across restart and upgrade in calendar event editors (dialog + tab). Stop mutating xulStore in onShutdown(). Ensure button placement on ADDON_INSTALL and ADDON_UPGRADE. Cover both toolbars: event-toolbar and event-tab-toolbar.
jobisoft
left a comment
There was a problem hiding this comment.
I see what you did there, great catch! I added two remarks.
Document why ADDON_UPGRADE is currently included in the startup path: - ADDON_INSTALL covers fresh profiles - ADDON_UPGRADE is only a temporary migration path for legacy persisted toolbar state Also note that this branch should be removed once the behavior is in core and no legacy profile migration is required.
|
I have massively reworked the PR based on the insights I have gained working on calendar API and toolbar code in the last few days. Foremost, the goal is to land this in core in March or April. Overriding The cleanup is needed as mentioned earlier and was moved into the constructor. We are not doing anything special anymore on install or upgrade. This may auto-heal broken profiles, but if not, we will not add code for that case. Would be happy to hear your feedback, but remember to not trigger the edge cases mentioned in bug 2020584. |
|
Example using the new code: |
kewisch
left a comment
There was a problem hiding this comment.
This looks good to me, thanks for making the effort!
Improves calendarItemAction toolbar persistence across restart and upgrade in calendar event editors (dialog + tab).
Stop mutating xulStore in onShutdown().
Ensure button placement on ADDON_INSTALL and ADDON_UPGRADE. Cover both toolbars: event-toolbar and event-tab-toolbar.