On Thu, 5 Sep 2002 12:32:30 +0200 Xavier Nodet <[EMAIL PROTECTED]> wrote:
XN> I already implemented a draft of the 'Moving folder' feature. As XN> I mostly did that while I could not read this list, I did it 'my way' XN> and it does not include the 'change folder ordering' feature As I understand now, these operations are really quite independent, so it's ok. XN> Current status XN> -------------- XN> XN> 1. There is a 'Move' command in the folder menu. It allows you to choose XN> the folder you want as new parent for the moved folder. Ok. Did you manage (or tried) to get DND to work? XN> 2. It is not able to move a folder that has sub-folders. This seems like a rather serious limitation as I'd expect this to be the most useful feature, in fact (you can rather easily move one folder manually, doing it for a whole hierarchy isn't as simple). Another useful thing would be to able to move several folders at once. For this we should have multiple selections in the tree though -- this is not difficult, but it would confuse lots of existing code I'm afraid. XN> I don't know how NNTP and NEWS folder work, so moving them is XN> disabled. I think you could enable it because there is nothing to do at cclient level anyhow (you can't move news groups...). OTOH, it doesn't matter that much. XN> For IMAP folders, the RENAME command is not sent yet so XN> this is also disabled. Actually, maybe it could be made even more powerful than simply moving the folders on the same server. For example, right now I'd really like to switch from Free IMAP server I use to my own one (because I regularly run out of their (small) quota) and it would be nice if I could simply create an entry for the new IMAP server in my folder tree and move all my existing folders there. XN> Note that, for IMAP folders, I suppose that we could move the root XN> folder of the server (when moving hierarchies is supported). Then no XN> RENAME command is needed for this or any of its sub-folders. Yes, but we'd have to copy all the messages. XN> How it works XN> ------------ XN> XN> This is done by creating a new MFolderFromProfile object with the XN> correct name (i.e. the full path of the target + the name of the moved XN> folder). Then I loop over all the entries in the profile associated with XN> the old folder, and create the same intries in the profile of the new XN> folder, while disabling the environment variables expansion. Looks very good! XN> Questions XN> --------- XN> XN> 1. Do you think that create new-delete old idea is a good one ? It's the only one I can think of to be honest. As long as you don't move the folder itself (i.e. physically move the messages), I don't see any problems with it. When/if we do need to move the messages there could be some nasty race conditions with this but we're not there yet. BTW, do you update the filters using the old folder name to the new one after moving? XN> 2. I have a problem to update the folder cache, which means that I must XN> close (and re-open) the moved folder to get it to display its number XN> of messages. XN> XN> My understanding is that I can't create a new entry in the cache XN> because the MFolder instance for the old folder is not deleted yet XN> when I try to do that, but I did not look at this problem carefully XN> yet. Sorry, I don't see why shouldn't you be able to do it: simply using MfStatusCache::GetStatus(oldname) and UpdateStatus(newname) should do the trick, shouldn't it? XN> 3. Should I commit now ? I guess I should because: I think you should :-) I probably won't be able to work on this myself right now but it shouldn't do any harm neither. Thanks! VZ ------------------------------------------------------- This sf.net email is sponsored by: OSDN - Tired of that same old cell phone? Get a new here for FREE! https://www.inphonic.com/r.asp?r=sourceforge1&refcode1=vs3390 _______________________________________________ Mahogany-Developers mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/mahogany-developers
