From 356eea0f947d6304b53051c3aa413b51f0391239 Mon Sep 17 00:00:00 2001 From: Walther Neuper Date: Mon, 14 Dec 2009 12:24:12 +0000 Subject: 3rd review display, establish coding standards --- diff --git a/ReckonPrimer.activity/display.py b/ReckonPrimer.activity/display.py index 644fc58..7a317bd 100755 --- a/ReckonPrimer.activity/display.py +++ b/ReckonPrimer.activity/display.py @@ -43,6 +43,12 @@ class Display: self.running = False # first round of calculations self.active_topic = None + def register(self, sess, co, learner): + """register _after_ Session and Coach have been instantiated""" + self._sess = sess + self._co = co + self._learner = learner + def _permanent_gui_elements(self, window): self.main_window = window # Save the sugar main window @@ -85,21 +91,15 @@ class Display: self.table_with_start = gtk.Table(15, 6, True) # Insert the 3 tables into the right half of the screen - self.table.attach(self.settings_table, 1, 2, 0, 5) - self.table.attach(self.topic_table, 1, 2, 0, 5) - self.table.attach(self.table_with_start, 1, 2, 0, 5) + self.table.attach(self.settings_table, 1, 2, 0, 5) + self.table.attach(self.topic_table, 1, 2, 0, 5) + self.table.attach(self.table_with_start,1, 2, 0, 5) # show all tables self.settings_table.show() self.topic_table.show() self.table_with_start.show() - self.table.show() - - def register(self, sess, co, learner): - """register _after_ Session and Coach have been instantiated""" - self._sess = sess - self._co = co - self._learner = learner + self.table.show() # since all other tables have benn inserted def update_time(self): minutes, seconds = divmod(self.stopwatch.elapsed, 60) -- cgit v0.9.1