From: Eero T. <ee...@us...> - 2008-01-26 22:53:03
|
Hi, On Saturday 26 January 2008, Benny Malengier wrote: > Hmm, pygtk cleans up gtk connects on window destroy so we don't > disconnect ourselves indeed, We destroy the window also at the end when > close is called on our ManagedWindow class so it is not due to keeping on > processing. X is such that if you click save twice after each other, it > is called twice. Yes, it's no supposed to lose user input, somebody might for example want to implement a double or triple click handler for the button... :-) > As eg person dialog needs to do some checks before=20 > knowing if we will actually save, Will both actions lead to removing the window/widgets? > disconnecting then connecting again is=20 > far more elaborate than insensitive/sensitive ok button. Setting things insensitive while they are processed seems to be good solution from UI point of view if it fixes the issue. > However, this specific bug was found because person editor hided before > being destroyed, I removed the hide. That does not remove the error > itself though. > > GRAMPS has many windows, passing X-events on other windows while saving > and not yet having destroyed a window can again leads to crashes if > things are clicked to fast. Sorry, could you explain the problem a bit more? Clicks to a window go to only that window, not to other windows? > So what you say sounds reasonable, but in reality does not solve it, it > just shifts the problem to the next window. > I think the suggestion of Brian is ok, work with a progress dialog that > is modal, so X knows that rest should not receive X-events. > The only problem is then that on crash, our crash handler needs to remove > the modal dialog, otherwise the interface remains blocked. =46rom the UI point of view mixing modal and non-modal windows is bad as mo= dal windows are (should be) trancient to their parents so that they keep above them (to indicate that user needs to finish interacting with them before she can use the underlying ones), where as non-modal ones aren't. Result is that user can top non-modal windows, but not interact with them=20 and to user it seems that the application has frozen (is broken). - Eero |