/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-gtk

  • Committer: Jelmer Vernooij
  • Date: 2007-02-01 15:50:40 UTC
  • Revision ID: jelmer@samba.org-20070201155040-3hq4mfbxs99kzazy
add framework for tests.

Show diffs side-by-side

added added

removed removed

Lines of Context:
56
56
import gettext
57
57
gettext.install('olive-gtk')
58
58
 
59
 
from olive.frontend.gtk import OliveGtk
 
59
 
 
60
# make sure we could import bzrlib
 
61
try:
 
62
    import bzrlib
 
63
except ImportError:
 
64
    # try to find bzr if it exist in $PATH
 
65
    p = os.popen('bzr version')
 
66
    s = p.read()
 
67
    r = p.close()
 
68
    if r not in (None, 0):
 
69
        print >>sys.stderr, "bzr not found"
 
70
        sys.exit(1)
 
71
    else:
 
72
        for i in s.splitlines():
 
73
            if i.startswith("Using bzrlib: "):
 
74
                path = os.path.split(i[14:])[0]
 
75
                sys.path.append(path)
 
76
                break
 
77
        else:
 
78
            print >>sys.stderr, "Can't find bzrlib location"
 
79
            sys.exit(1)
 
80
 
 
81
 
 
82
from olive import OliveGtk
 
83
from bzrlib.plugin import load_plugins
 
84
load_plugins()
 
85
 
 
86
import bzrlib.ui
 
87
import olive.ui
 
88
bzrlib.ui.ui_factory = olive.ui.GtkUIFactory()
60
89
 
61
90
app = OliveGtk()
62
91
gtk.main()