diff options
author | Ryan Rix <phrkonaleash@gmail.com> | 2009-12-08 15:33:09 -0700 |
---|---|---|
committer | Ryan Rix <phrkonaleash@gmail.com> | 2009-12-08 15:33:09 -0700 |
commit | 1211b0e1d64fa5438e10b1040443c2ee06be899a (patch) | |
tree | 1caada60c5ce367734a2b8bbc152953c16fe4e7a | |
parent | ee0f707b94d8f22fe5d70a77031931cfbe7cb3b8 (diff) | |
download | fedora-tour-1211b0e1d64fa5438e10b1040443c2ee06be899a.tar.gz fedora-tour-1211b0e1d64fa5438e10b1040443c2ee06be899a.tar.xz fedora-tour-1211b0e1d64fa5438e10b1040443c2ee06be899a.zip |
Created a working window in pygtk. woo!
-rw-r--r-- | frontend/tour_gtk_frontend.py | 21 |
1 files changed, 13 insertions, 8 deletions
diff --git a/frontend/tour_gtk_frontend.py b/frontend/tour_gtk_frontend.py index cd415ad..178f3e8 100644 --- a/frontend/tour_gtk_frontend.py +++ b/frontend/tour_gtk_frontend.py @@ -18,23 +18,23 @@ # import io -import os.path -import xml.parsers.expat -import sys +import gtk """ This class is responsible for the creation and destruction of the main window. """ class Frontend: def __init__(self): - self.mainWindow=create_win() + self.mainWindow=self.create_win() self.mainWindow.connect("delete_event", self.winDelete) - self.mainWindow.connect("destroy",self.winDestory) + self.mainWindow.connect("destroy",self.winDestroy) + + self.mainWindow.show() - def winDestroy(self,widget,Data=none): + def winDestroy(self,widget,Data=None): return False - def winDelete(self,widget,Data=none): + def winDelete(self,widget,Data=None): gtk.main_quit() """ @@ -42,4 +42,9 @@ class Frontend: def create_win(self): return gtk.Window(gtk.WINDOW_TOPLEVEL) - pass
\ No newline at end of file + def main(self): + gtk.main() + +if __name__=="__main__": + frontend = Frontend() + frontend.main()
\ No newline at end of file |