/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 olive/dialog.py

  • Committer: Jelmer Vernooij
  • Date: 2007-02-03 13:01:12 UTC
  • Revision ID: jelmer@samba.org-20070203130112-m1stbo29f1ahthzs
Move diff to top-level directory as well.

Show diffs side-by-side

added added

removed removed

Lines of Context:
24
24
import gtk.glade
25
25
 
26
26
 
 
27
def about():
 
28
    """ Display the AboutDialog. """
 
29
    version = None
 
30
    try:
 
31
        import bzrlib.plugins.gtk
 
32
    except ImportError:
 
33
        version = 'N/A'
 
34
    else:
 
35
        version = bzrlib.plugins.gtk.__version__
 
36
    from guifiles import GLADEFILENAME
 
37
 
 
38
    # Load AboutDialog description
 
39
    dglade = gtk.glade.XML(GLADEFILENAME, 'aboutdialog')
 
40
    dialog = dglade.get_widget('aboutdialog')
 
41
 
 
42
    # Set version
 
43
    dialog.set_version(version)
 
44
 
 
45
    dialog.run()
 
46
    # Destroy the dialog
 
47
    dialog.destroy()
 
48
 
27
49
def _message_dialog(type, primary, secondary, buttons=gtk.BUTTONS_OK):
28
50
    """ Display a given type of MessageDialog with the given message.
29
51