diff options
author | Jeremy Katz <katzj@redhat.com> | 2005-01-13 15:43:25 +0000 |
---|---|---|
committer | Jeremy Katz <katzj@redhat.com> | 2005-01-13 15:43:25 +0000 |
commit | d27e2a77bf142827419e7ad128e3425dd79f76d6 (patch) | |
tree | 66563427249057a4285a05c9075892f535ca21bf /gui.py | |
parent | 01ec3f4f1c075c952c6a965c7c43dafa2a16c661 (diff) | |
download | anaconda-d27e2a77bf142827419e7ad128e3425dd79f76d6.tar.gz anaconda-d27e2a77bf142827419e7ad128e3425dd79f76d6.tar.xz anaconda-d27e2a77bf142827419e7ad128e3425dd79f76d6.zip |
2005-01-13 Jeremy Katz <katzj@redhat.com>
* gui.py (findGladeFile): Look for the glade file in the
appropriate places
Diffstat (limited to 'gui.py')
-rwxr-xr-x | gui.py | 11 |
1 files changed, 10 insertions, 1 deletions
@@ -399,6 +399,14 @@ def addFrame(dialog, title=None, showtitle = 1): dialog.connect ("key-release-event", handleShiftPrintScrnRelease) +def findGladeFile(file): + for dir in ("/mnt/source/RHupdates/", "/tmp/updates/", + "ui/", "/usr/share/anaconda/ui/"): + fn = dir + file + if os.access(fn, os.R_OK): + return fn + raise RuntimeError, "Unable to find glade file %s" %(fn,) + class WaitWindow: def __init__(self, title, text): if flags.rootpath: @@ -1234,7 +1242,8 @@ class InstallControlWindow: self.mainxml.signal_autoconnect(sigs) def loadGlade(self): - self.mainxml = gtk.glade.XML("anaconda.glade", domain="anaconda") + self.mainxml = gtk.glade.XML(findGladeFile("anaconda.glade"), + domain="anaconda") def setup_window (self, runres): self.setLtR() |