bugfix
authorpin <pin@fe552daf-6dbe-4428-90eb-1537e0879342>
Thu, 18 Feb 2010 14:31:36 +0000 (14:31 +0000)
committerpin <pin@fe552daf-6dbe-4428-90eb-1537e0879342>
Thu, 18 Feb 2010 14:31:36 +0000 (14:31 +0000)
git-svn-id: https://svn.cri.ensmp.fr/svn/minwii/trunk@41 fe552daf-6dbe-4428-90eb-1537e0879342

src/app/widgets/playingscreen.py

index 0e78285..1bf002c 100755 (executable)
@@ -48,10 +48,10 @@ class _PlayingScreenBase(object) :
         dispWidth = screen.get_width() - 2 * BORDER
         dispHeight = screen.get_height() - 2 * BORDER
         
-        columnWidth = int(round(float(dispWidth) / keyboardLength))
+        columnWidth = int(round(float(dispWidth) / self.keyboardLength))
 
         rects = []
-        for i in range(keyboardLength) :
+        for i in range(self.keyboardLength) :
             upperLeftCorner = (i*columnWidth + BORDER, BORDER)
             rect = pygame.Rect(upperLeftCorner, (columnWidth, dispHeight))
             rects.append(rect)
@@ -76,7 +76,7 @@ class _PlayingScreenBase(object) :
 class SongPlayingScreen(_PlayingScreenBase) :
     
     def __init__(self, song) :
-        super(SongPlayingScreen, self).__init__(song.)
+        super(SongPlayingScreen, self).__init__(song.distinctNotes)
         self.song = song