On Sat, 26 Jul 2003 16:32:57 +0200 (CEST) Robert Vazan <[EMAIL PROTECTED]> wrote:
RV> IMO, there is a general problem with reentrancy that needs general RV> solution. Yes, I totally agree. Unfortunately I also think that I know what this general solution is: make Mahogany multithreaded. In this particular case I am quite sure that MT-design will be much simpler than the current one. But, of course, I don't have anywhere the time required to actuall do it :-( RV> I've just stumbled into one problem in this class (I've got RV> autosave in middle of composer construction) and I hotfixed it by RV> carefully locking that part of code. Could you please send the patch? TIA! RV> Let's first look where the problem comes from. When writing code, one RV> tends to think that every event is executed as atomic transaction, so RV> one can break invariants as far as they are recovered later in the RV> event. Modal dialogs change this. This is not limited to modal dialogs. Calls to wxYield() (which are necessary for such mundae things as updating the cursor to show the busy state under GTK) are very dangerous because of this. Under MSW the virtual list control can call us back at any time it needs to refresh. There are probably other things which I forget. RV> Now the solution. The idea is to stop event processing in modal dialogs. No. You surely don't want to stop list control redrawing, without speaking of new mail checks, while a dialog is opened. This is not a solution. RV> Yet I think that maintaining temporary queue and then requeuing can be RV> done in reasonable time with high quality. I know this is another thing RV> I am not going to do in foreseeable future, but I would like to hear RV> your opinions/votes about this. I really don't think this is a good idea. Idle and other events should be continued to be generated while the dialog is shown. Again, the real solution is to use threads. If you've ever looked at ASMailFolder class you know that the current design was never meant to be used without threads -- it was supposed to exist in its current form only during very short time and be upgraded to the full MT as soon as possible. Needless to say that Karsten's departure from the project development slightly changed our plans... Nevertheless, I think that MTing Mahogany is the 4th biggest task right now and I'm reasonably confident that _some_ day it will be done. As I wrote in the roadmap, my plan is: 0. release 0.65 1. work on options synchronization and everything else needed to make it possible to use M comfortably from different computers/OS 2. rewrite address book (both format (performance!) and GUI) 3. rewrite composer 4. MT If you can help with (3) (even if it's going to be less than originally planned) and if I finally decide to postpone (2) until later, (4) could happen before the end of the year. Still, for me the most important is (1) and so this is what I'm going to do first. Regards, VZ ------------------------------------------------------- This SF.Net email sponsored by: Free pre-built ASP.NET sites including Data Reports, E-commerce, Portals, and Forums are available now. Download today and enter to win an XBOX or Visual Studio .NET. http://aspnet.click-url.com/go/psa00100003ave/direct;at.aspnet_072303_01/01 _______________________________________________ Mahogany-Developers mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/mahogany-developers
