/b-gtk/fix-viz

To get this branch, use:
bzr branch http://gegoxaren.bato24.eu/bzr/b-gtk/fix-viz

« back to all changes in this revision

Viewing changes to dialog.py

  • Committer: Jelmer Vernooij
  • Date: 2011-04-06 14:53:44 UTC
  • Revision ID: jelmer@samba.org-20110406145344-m6s0i7q7ssjwhmwq
Support use without gtk.Spinner, which is only available in pygtk >= 2.22.

Show diffs side-by-side

added added

removed removed

Lines of Context:
25
25
 
26
26
def _message_dialog(type, primary, secondary, parent=None, buttons=gtk.BUTTONS_OK):
27
27
    """ Display a given type of MessageDialog with the given message.
28
 
    
 
28
 
29
29
    :param type: message dialog type
30
 
    
 
30
 
31
31
    :param message: the message you want to display.
32
32
    """
33
33
    dialog = gtk.MessageDialog(flags=gtk.DIALOG_MODAL, type=type, parent=parent,
34
34
                               buttons=buttons)
35
35
    dialog.set_markup('<big><b>' + primary + '</b></big>')
36
 
    dialog.format_secondary_markup(secondary)
 
36
    dialog.format_secondary_text(secondary)
37
37
    response = dialog.run()
38
38
    dialog.destroy()
39
39
    return response