diff options
author | Agustin Zubiaga <aguzubiaga97@gmail.com> | 2011-12-24 13:17:02 (GMT) |
---|---|---|
committer | Agustin Zubiaga <aguzubiaga97@gmail.com> | 2011-12-24 13:17:02 (GMT) |
commit | 31cc302699d1741cfe524e5c86d44b3023c7da20 (patch) | |
tree | d9095588aa7f5677578411bcc482a9ba698bc68e | |
parent | 51ffb28a81039813967b5f1ea0dd4eef0de9aa20 (diff) |
Codificacion de caracteres UTF-8 en timer.py y que se cree un nuevo juego automaticamente al cambiar la dificultad
-rw-r--r-- | terronesweeper.py | 6 | ||||
-rw-r--r-- | timer.py | 1 |
2 files changed, 3 insertions, 4 deletions
diff --git a/terronesweeper.py b/terronesweeper.py index bc19cae..bacecc9 100644 --- a/terronesweeper.py +++ b/terronesweeper.py @@ -41,9 +41,6 @@ from sugar.activity.widgets import StopButton from sugar.activity.widgets import ToolbarButton from sugar.graphics.toolbutton import ToolButton from sugar.graphics.menuitem import MenuItem -from sugar.graphics import style -from sugar.graphics.icon import Icon -from sugar.graphics.xocolor import XoColor from timer import Timer @@ -280,10 +277,11 @@ class TerronesWeeper(activity.Activity): difficulty_levels = {'easy': (5, gtk.ICON_SIZE_DIALOG), 'medium': (10, gtk.ICON_SIZE_LARGE_TOOLBAR), 'difficult': (20, gtk.ICON_SIZE_MENU)} + def change_difficulty(self, widget): _property, order = widget.get_current_difficulty() self.size, self.icon = self.difficulty_levels[_property] - + self.refresh_game(None) def refresh_game(self, widget): self.terron_button.set_icon("terron") @@ -1,4 +1,5 @@ #!/usr/bin/env python +# -*- coding: UTF-8 -*- # # TerronesWeeper Activity - timer.py # |