OSDN Git Service

bug fix: cannot show window when first
authorHirotaka Kawata <hktechno@hotmail.com>
Tue, 15 Jun 2010 07:30:01 +0000 (16:30 +0900)
committerHirotaka Kawata <hktechno@hotmail.com>
Tue, 15 Jun 2010 07:30:01 +0000 (16:30 +0900)
main.py

diff --git a/main.py b/main.py
index 5b74f77..2770d9b 100644 (file)
--- a/main.py
+++ b/main.py
@@ -54,16 +54,17 @@ class Main:
     
     def main(self):
         gtk.gdk.threads_enter()
+        window = self.builder.get_object("window1")
         
         # settings allocation
         try:
             alloc = get_config("DEFAULT", "allocation")
             alloc = eval(alloc)
-            window = self.builder.get_object("window1")
             window.resize(alloc.width, alloc.height)
-            window.show_all()
         except:
             print >>sys.stderr, "[Warning] Allocation not defined"        
+
+        window.show_all()
         
         # Start gtk main loop
         gtk.main()