Bug 446837 - Add recursive option to "Hide this folder in the folder selection dialog"
Summary: Add recursive option to "Hide this folder in the folder selection dialog"
Status: RESOLVED FIXED
Alias: None
Product: kmail2
Classification: Applications
Component: folders (show other bugs)
Version: 5.19.0
Platform: openSUSE Linux
: NOR wishlist
Target Milestone: ---
Assignee: kdepim bugs
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2021-12-11 15:35 UTC by David de Cos
Modified: 2021-12-14 14:05 UTC (History)
1 user (show)

See Also:
Latest Commit:
Version Fixed In: 5.19.2


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description David de Cos 2021-12-11 15:35:44 UTC
I have many old folders in my Mail structure that I only keep for consultation, some of which share names with other folders that I currently use everyday. I almost never want to jump, move or copy mails to those folders, so the "Hide this folder in the folder selection dialog" is very handy.

However, if you have dozens of folders that hang from a common point (a past year, a previous job, etc), it can take you a long time to hide them one by one. It would be great if we could go to the parent folder properties and be able to check an additional option to make "Hide this folder in the folder selection dialog" recursive, so it's automatically applied to all the folders hanging from that point.
Comment 1 Laurent Montel 2021-12-13 05:47:54 UTC
Hi,
you have a plugin for changing folder settings
=> you can select which folder you want to change settings and you will apply new settings.

I think it will help you.
Regards
Comment 2 David de Cos 2021-12-13 12:02:37 UTC
Thank you very much for the info, Laurent. I didn't know this plugin, this should certainly speed the process.

However, I don't think it's working well for me. I select a few folders at once -> Mark "Hide this folder in the folder selection dialog" -> Accept -> Restart KMail -> Check the properties of those folders (not via the plugin, but right click -> Folder properties), and the option is unmarked. I've done a few attempts, and sometimes only 1 of the folders has the option marked, but all the others don't.

Can you please check if it works for you? Maybe I'm doing something wrong?

Thanks a lot!
Comment 3 Laurent Montel 2021-12-13 12:09:52 UTC
(In reply to David de Cos from comment #2)
> Thank you very much for the info, Laurent. I didn't know this plugin, this
> should certainly speed the process.
> 
> However, I don't think it's working well for me. I select a few folders at
> once -> Mark "Hide this folder in the folder selection dialog" -> Accept ->
> Restart KMail -> Check the properties of those folders (not via the plugin,
> but right click -> Folder properties), and the option is unmarked. I've done
> a few attempts, and sometimes only 1 of the folders has the option marked,
> but all the others don't.
> 
> Can you please check if it works for you? Maybe I'm doing something wrong?
> 
> Thanks a lot!

ok indeed it seems that there is a problem.
I work on it now.
Comment 4 Laurent Montel 2021-12-13 13:04:18 UTC
Git commit 565c4084cd2a44922ac64cb561533c36058ee790 by Laurent Montel.
Committed on 13/12/2021 at 13:03.
Pushed by mlaurent into branch 'release/21.12'.

Bug 446837: Fix Add recursive option to "Hide this folder in the folder selection dialog"
FIXED-IN: 5.19.2

M  +1    -0    src/collectionpage/collectiongeneralwidget.cpp
M  +1    -0    src/collectionpage/collectionviewwidget.cpp

https://invent.kde.org/pim/mailcommon/commit/565c4084cd2a44922ac64cb561533c36058ee790
Comment 5 Laurent Montel 2021-12-13 13:05:15 UTC
(In reply to Laurent Montel from comment #3)
> (In reply to David de Cos from comment #2)
> > Thank you very much for the info, Laurent. I didn't know this plugin, this
> > should certainly speed the process.
> > 
> > However, I don't think it's working well for me. I select a few folders at
> > once -> Mark "Hide this folder in the folder selection dialog" -> Accept ->
> > Restart KMail -> Check the properties of those folders (not via the plugin,
> > but right click -> Folder properties), and the option is unmarked. I've done
> > a few attempts, and sometimes only 1 of the folders has the option marked,
> > but all the others don't.
> > 
> > Can you please check if it works for you? Maybe I'm doing something wrong?
> > 
> > Thanks a lot!
> 
> ok indeed it seems that there is a problem.
> I work on it now.

Fixed.
Thanks for reporting this bug :)
Comment 6 David de Cos 2021-12-13 17:40:27 UTC
That's great, Laurent! Thank you very much for the fast response.

I just noticed something curious, a very minor bug:
1) Use the plugin to mark some folders as hidden in the folder selection dialog.
2) Accept and close KMail right away, without clicking on any folder.
3) Restart KMail and right-click on one of the folders that you just configured via the plugin.
4) The "Folder Properties" option is not there.

If you click on any other folder, the menu entry comes back again (so as I said, it's a very minor bug). Did you notice that too? If you want, I can create a new bug report for that.
Comment 7 Laurent Montel 2021-12-14 12:38:59 UTC
(In reply to David de Cos from comment #6)
> That's great, Laurent! Thank you very much for the fast response.
> 
> I just noticed something curious, a very minor bug:
> 1) Use the plugin to mark some folders as hidden in the folder selection
> dialog.
> 2) Accept and close KMail right away, without clicking on any folder.
> 3) Restart KMail and right-click on one of the folders that you just
> configured via the plugin.
> 4) The "Folder Properties" option is not there.
> 
> If you click on any other folder, the menu entry comes back again (so as I
> said, it's a very minor bug). Did you notice that too? If you want, I can
> create a new bug report for that.

Hi,
I can't reproduce it here...
Comment 8 David de Cos 2021-12-14 14:05:17 UTC
Hi Laurent,

You're right, I didn't report it correctly. I've been testing it more thoroughly, and I think I have a clearer picture now. In order to reproduce it, you need to:
1) Find an empty folder. If you don't have one, create it.
2) Close KMail.
3) Open KMail and go straight to right click on the empty folder. The entry "Folder properties" isn't in the menu!
4) Right click on any other folder that isn't empty. "Folder properties" is there, as normal.
5) Go back to right click on the empty folder. "Folder properties" reappears.

So it only happens right after starting KMail, and before clicking on any non-empty folder. That's exactly what I was doing when testing the folder plugin yesterday, so I interpreted it wrongly.

One more thing: actually, the folder doesn't have to be empty. In reality, step number 1 should be "find a folder in which no message is selected". I actually don't know how to do that on purpose, but the fact is that I have some old folders in which I hadn't entered in a while, which do not have any message selected. So if I right click on those folders after starting KMail, the menu entry isn't there. Maybe you know how to unselect all messages in a folder, otherwise just use an empty one.

Thanks!