[gnome-games/sudoku-tube] Fix mistake, forgot to change back



commit 62830c8f5fc00269ebfae3652e700f1b21321495
Author: Zhang Sen <zh jesse gmail com>
Date:   Sun Jul 12 21:47:12 2009 +0800

    Fix mistake, forgot to change back

 gnome-sudoku/src/lib/tracker_box.py |    5 +++--
 1 files changed, 3 insertions(+), 2 deletions(-)
---
diff --git a/gnome-sudoku/src/lib/tracker_box.py b/gnome-sudoku/src/lib/tracker_box.py
index 2e0e712..effc6ce 100644
--- a/gnome-sudoku/src/lib/tracker_box.py
+++ b/gnome-sudoku/src/lib/tracker_box.py
@@ -205,8 +205,9 @@ class TrackerModel:
         return identifier
 
     def get_tracker_color(self, identifier):
-        return self.TRACKER_COLORS[identifier]
-        if 0:
+        try:
+            return self.TRACKER_COLORS[identifier]
+        except IndexError:
             new_color = self._generate_new_color()
             self.TRACKER_COLORS.append(new_color)
             return self.get_tracker_color(identifier)



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]