diff options
author | Yann Leboulanger <asterix@lagaule.org> | 2008-08-04 16:11:46 +0400 |
---|---|---|
committer | Yann Leboulanger <asterix@lagaule.org> | 2008-08-04 16:11:46 +0400 |
commit | 80f6d7909c6c498f34eba40dd4f75aa0f7c5d167 (patch) | |
tree | da1bc06cd63cd0a3fd8d73f4607bc657f902728c | |
parent | e22c6e96977b1d88bdf6bbecc48f4c71650f0858 (diff) |
make gtkexcepthook dialog non modal. fixes #4148
-rw-r--r-- | src/gtkexcepthook.py | 16 |
1 files changed, 7 insertions, 9 deletions
diff --git a/src/gtkexcepthook.py b/src/gtkexcepthook.py index 6d8999f89..fad9b850d 100644 --- a/src/gtkexcepthook.py +++ b/src/gtkexcepthook.py @@ -47,6 +47,7 @@ def _info(type, value, tb): _('It probably is not fatal, but should be reported ' 'to the developers nonetheless.')) + dialog.set_modal(False) #FIXME: add icon to this button RESPONSE_REPORT_BUG = 42 dialog.add_buttons(gtk.STOCK_CLOSE, gtk.BUTTONS_CLOSE, @@ -81,18 +82,15 @@ def _info(type, value, tb): # on expand the details the dialog remains centered on screen dialog.set_position(gtk.WIN_POS_CENTER_ALWAYS) - dialog.show_all() - close_clicked = False - while not close_clicked: - resp = dialog.run() - if resp == RESPONSE_REPORT_BUG: + def on_dialog_response(dialog, response): + if response == RESPONSE_REPORT_BUG: url = 'http://trac.gajim.org/wiki/HowToCreateATicket' helpers.launch_browser_mailer('url', url) else: - close_clicked = True - - dialog.destroy() + dialog.destroy() + dialog.connect('response', on_dialog_response) + dialog.show_all() _exception_in_progress.release() @@ -108,4 +106,4 @@ if __name__ == '__main__': sys.excepthook = _info print x # this always tracebacks -# vim: se ts=3:
\ No newline at end of file +# vim: se ts=3: |