When closing the GnomeAbout box (or other GtkDialog subclasses), I get crashes and weird callback behaviour. What up with that?
Normally, when handling closed signals on a window, you should follow the advice in FAQ 10.6. However, for GnomeAbout, things aren’t so simple. Jon Willeke took the time to point out that in the case of GnomeAbout, to avoid having a window be destroyed when you close it, you need to also connect to the “response” handler. Malcolm Tredinnick offered a more detailed explanation of how this works: A GtkDialog box has two main signals it implements: ‘close’ and ‘response’. It also inherits the ‘delete-event’ signal from the GtkWidget class which also has a role to play here. The ‘response’ signal is emitted pretty much whenever any action happens that causes the dialog box to finish running. The response signal emission will contain a “response ID” which can be user-defined or any one of the gtk.RESPONSE_* constants in pyGTK. The standard values correspond to things like one of the standard buttons being pushed or the window being destroyed. You can act differently based on the response ID
Related Questions
- When closing the GnomeAbout box (or other GtkDialog subclasses), I get crashes and weird callback behaviour. What up with that?
- My windows computer crashes when I adjust the "remedies in rubric" box while in the Complete Millennium?
- Im using Eclipse PDE and I started getting some weird exceptions/behaviour. Whats the matter?