Mercurial > sypikslang
comparison gamelib/gamegui.py @ 257:c949ac17cfd9
Standardise button positions
author | Neil Muller <drnlmuller@gmail.com> |
---|---|
date | Sun, 13 May 2012 01:34:37 +0200 |
parents | 05c89ce70ac4 |
children | 6f96e28e6cfd |
comparison
equal
deleted
inserted
replaced
256:44a09802fff4 | 257:c949ac17cfd9 |
---|---|
573 | 573 |
574 def set_activity_window(self, activity): | 574 def set_activity_window(self, activity): |
575 # Oh, what tangled webs we weave | 575 # Oh, what tangled webs we weave |
576 if not self.activity: | 576 if not self.activity: |
577 self.activity = activity | 577 self.activity = activity |
578 actbut = SwitchWinButton((300, 0), 'Schemes', activity) | 578 actbut = SwitchWinButton((450, 0), 'Schemes', activity) |
579 self.add_child(actbut) | 579 self.add_child(actbut) |
580 | 580 |
581 def _make_science_widgets(self): | 581 def _make_science_widgets(self): |
582 for widget in self._sciences: | 582 for widget in self._sciences: |
583 self.remove_child(widget) | 583 self.remove_child(widget) |
636 | 636 |
637 self.develop = DevelopmentWindow(screen, self) | 637 self.develop = DevelopmentWindow(screen, self) |
638 self.activity = ActivityWindow(screen, self, self.develop) | 638 self.activity = ActivityWindow(screen, self, self.develop) |
639 self.develop.set_activity_window(self.activity) | 639 self.develop.set_activity_window(self.activity) |
640 | 640 |
641 devbut = SwitchWinButton((150, 0), 'Engineering', self.develop) | 641 devbut = SwitchWinButton((300, 0), 'Engineering', self.develop) |
642 self.add_child(devbut) | 642 self.add_child(devbut) |
643 actbut = SwitchWinButton((300, 0), 'Schemes', self.activity) | 643 actbut = SwitchWinButton((450, 0), 'Schemes', self.activity) |
644 self.add_child(actbut) | 644 self.add_child(actbut) |
645 | 645 |
646 self._sciences = [] | 646 self._sciences = [] |
647 # Setup for the first turn | 647 # Setup for the first turn |
648 self.update_labels() | 648 self.update_labels() |