Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Thunderbird 102 - current category is not remembered / selected #279

Closed
RealRaven2000 opened this issue Jul 1, 2022 · 6 comments
Closed

Comments

@RealRaven2000
Copy link
Owner

When restarting Thunderbird, all categories are selected so that all tabs are selected. I would expect each tab to remember it's category as before.

@RealRaven2000
Copy link
Owner Author

RealRaven2000 commented Jul 16, 2022

Here is a first patch that works reasonably well:

QuickFolders-mx-5.11pre70.zip

This version stores its own session information whenever a new tab is opened / selected / deleted / moved in the current window. It also restores reliably in most cases. It doesn't keep track of multiple windows, so if you open a second and third window and change tabs there and then close them this version may not store the correct category information. For it to work in that case I need to also find an event for when the "Main" (if there is a main) window is focused and store the tabSession again (in case it was overwritten by other windows). I also don't currently know which window is restored when Thunderbird closes all windows because a user selected "close all windows" from the taskbar or shuts down the OS causing the windows to be closed. I consider these as edge cases for the moment.

To see what's happening behind the scenes with the session, enabled Debug mode (from QF advanced settings) and then filter the error console for loadTabSession or storeTabSession.

@RealRaven2000
Copy link
Owner Author

Fixed some code that stores wrong categories when folder is opened in a new tab or a folder / message tab is closed that is currently not selected:

QuickFolders-mx-5.11pre75.zip

As always, to install this version please download the zip file and drag it into Thunderbird Add-ons Manager (without unpacking)

@RealRaven2000
Copy link
Owner Author

Fixed a problem with invalid categories staying in the tab session forever. Now on every categorySelect() call we check for validity of the first category. To do: do a full test with multiple category selection.

QuickFolders-mx-5.11pre89.zip

As always, to install this version please download the zip file and drag it into Thunderbird Add-ons Manager (without unpacking)

@RealRaven2000
Copy link
Owner Author

Next version - there were still some problems with selecting multiple categories and proper recovering from deleted categories. This version does some sanity checking when selecting a tab and removes invalid categories from the tabInfo object - it will switch the tab back to view all categories if none of the categories exist anymore.

QuickFolders-mx-5.11pre92.zip

To install this version please download the zip file and drag it into Thunderbird Add-ons Manager (without unpacking)

@RealRaven2000
Copy link
Owner Author

With the help of a user's profile I managed to remove one more problem when starting up that would still lead to no category (and not __ALL) selected resulting in no visible tab:

QuickFolders-mx-5.11pre93.zip

To install this version please download the zip file and drag it into Thunderbird Add-ons Manager (without unpacking)

RealRaven2000 added a commit that referenced this issue Jul 20, 2022
…ig; fix live update when restoring tabs from file
@RealRaven2000
Copy link
Owner Author

Implemented in 5.11 - Published 23/07/2022

@RealRaven2000 RealRaven2000 unpinned this issue Jul 23, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant