diff options
author | Ismaël Bouya <ismael.bouya@normalesup.org> | 2016-06-13 14:12:58 +0200 |
---|---|---|
committer | Ismaël Bouya <ismael.bouya@normalesup.org> | 2016-06-13 14:12:58 +0200 |
commit | 1df30f075c186c4c3d41d5f6014817b1b6b7b1ae (patch) | |
tree | a08e18b3fffbadbdecfb4680727fcc6059408752 | |
parent | 189bf90cfc9401b4bc0f6f36c152a439626cef3a (diff) | |
download | MusicSampler-1df30f075c186c4c3d41d5f6014817b1b6b7b1ae.tar.gz MusicSampler-1df30f075c186c4c3d41d5f6014817b1b6b7b1ae.tar.zst MusicSampler-1df30f075c186c4c3d41d5f6014817b1b6b7b1ae.zip |
Make it compatible with python2.7
-rw-r--r-- | helpers.py | 5 |
1 files changed, 3 insertions, 2 deletions
@@ -1,3 +1,4 @@ | |||
1 | # -*- coding: utf-8 -*- | ||
1 | from pygame import * | 2 | from pygame import * |
2 | from math import pi | 3 | from math import pi |
3 | 4 | ||
@@ -62,7 +63,7 @@ class Key: | |||
62 | background_surface.blit(self.surface, self.position) | 63 | background_surface.blit(self.surface, self.position) |
63 | 64 | ||
64 | def do_actions(self): | 65 | def do_actions(self): |
65 | print("coucou" + self.key_sym) | 66 | print("coucou " + self.key_sym) |
66 | pass | 67 | pass |
67 | 68 | ||
68 | keys = { | 69 | keys = { |
@@ -181,7 +182,7 @@ class RoundedRect: | |||
181 | self.radius = radius | 182 | self.radius = radius |
182 | 183 | ||
183 | def surface(self): | 184 | def surface(self): |
184 | rectangle = filledRoundedRect(self.rect, self.outer_color, self.radius) | 185 | rectangle = self.filledRoundedRect(self.rect, self.outer_color, self.radius) |
185 | 186 | ||
186 | inner_rect = Rect(( | 187 | inner_rect = Rect(( |
187 | self.rect.left + 2 * self.linewidth, | 188 | self.rect.left + 2 * self.linewidth, |