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

Avoid accidentally running filters through Shortcut, add confirmation dialog #132

Closed
RealRaven2000 opened this issue Oct 28, 2022 · 6 comments
Assignees

Comments

@RealRaven2000
Copy link
Owner

RealRaven2000 commented Oct 28, 2022

The premium features to run filters on all or selected mails can be triggered accidentally when doing a search and typing (if the focus accidentally has been removed from the search box).

image

I believe this is not a problem when we are in the Inbox, (as filters are ran there automatically anyway) but it should be avoided to trigger this action from any other folder - I just accidentally moved 5000+ messages from one folder to another and thankfully found the location through a list into the filter log.

Therefore a message box "Do you want to run the filters on selected mails / all mails now?" should be inserted before the action is carried out. We will also add a checkbox to remove this question if needed.

@RealRaven2000
Copy link
Owner Author

RealRaven2000 commented Oct 28, 2022

Test version below. Confirmation option is switched on as new default, but can be disabled:

image

Once a shortcut is used the following confirmation dialogs are shown:

image

image

Test version:
quickFilters-wx-5.6.1pre10.zip

note: you have to restart Thunderbird after installation because unfortunately it doesn't remove the original keyboard event handler!

@RealRaven2000 RealRaven2000 changed the title Avoid accidentally running filters through Shortcut, challenge messagebox Avoid accidentally running filters through Shortcut, add confirmation dialog Oct 28, 2022
@RealRaven2000
Copy link
Owner Author

As an additional problem that just came to light: the shortcut is also triggered when we edit a search (both the quick filter and the global search field on the main toolbar). So we will have to do additional methods to avoid triggering the function when a textbox on the main UI has the focus.

@Amoeba00
Copy link

Amoeba00 commented Nov 6, 2022

Just wanted to comment that I appreciate you posting your own tickets and workflow. I wish Thunderbird were a bit better with IMAP, but at least your program makes it work better. Thanks.

@RealRaven2000
Copy link
Owner Author

Just wanted to comment that I appreciate you posting your own tickets and workflow. I wish Thunderbird were a bit better with IMAP, but at least your program makes it work better. Thanks.

Thanks for the feedback @Amoeba00 - I think working on changes in my (100% open source) Add-ons is good practice as it keeps me motivated and adds at least a minimum of "documentation" as I go, always nice to see somebody is watching. I was grappling with the keyboard listener not being removed when quickFilters updated so I added a fix for that:

quickFilters-wx-5.6.1pre18.zip

This version (and all versions going forward) will tidy up after itself and remove the listener when quickFilters is removed / updated to avoid double triggering. [it can't tidy up any older version of itself as removing event listeners need to point to the exact function that was added] I probably need to add a more detailed description why this change is important when you work with "staggered filters" - that is a row of filters that operate after one another and target emails selectively. With the shortcuts enabled (and without the alert box) it was very easy to accidentally move lots of mails from one folder when trying to do a quicksearch and unintendedly using the Shift Key to enter search terms. I am now also guarding against triggering key shortcuts when in those search boxes - something I had apparently already done in QuickFolders.

@RealRaven2000
Copy link
Owner Author

Latest version:

quickFilters-wx-5.7pre43.zip

Installation: download the zip file then drag into Add-ons Manager without unpacking.

@RealRaven2000
Copy link
Owner Author

Implemented in 5.7 - Published 22/Dec/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

2 participants