projects
/
naja.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Blank the screen on each frame
[naja.git]
/
naja
/
scenes
/
scene.py
diff --git
a/naja/scenes/scene.py
b/naja/scenes/scene.py
index d85dbab5db8937da03e7213a403ea73438cc9b91..f0acf21bdf9f62a1f9fef85a1f3ce4771234c116 100644
(file)
--- a/
naja/scenes/scene.py
+++ b/
naja/scenes/scene.py
@@
-10,7
+10,20
@@
class Scene(object):
E.g. Splash screen, game board, credits, win, lose.
"""
def __init__(self):
E.g. Splash screen, game board, credits, win, lose.
"""
def __init__(self):
+ self.widgets = []
+
+ def enter(self):
+ pass
+
+ def exit(self):
pass
pass
- def handle_event(self):
+ def render(self, surface):
+ self.render_widgets(surface)
+
+ def render_widgets(self, surface):
+ for widget in self.widgets:
+ widget.render(surface)
+
+ def handle_event(self, ev):
pass
pass