projects
/
minwii.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
fallback pgu standard.
[minwii.git]
/
src
/
app
/
events.py
diff --git
a/src/app/events.py
b/src/app/events.py
index
8e13a85
..
a67a416
100755
(executable)
--- a/
src/app/events.py
+++ b/
src/app/events.py
@@
-1,12
+1,19
@@
import pygame
from sys import modules
import pygame
from sys import modules
-events = ['TIMEOUT', 'NOTEON', 'NOTEOFF', 'NOTEEND', 'COLDOWN', 'COLUP', 'COLOVER']
+events = ['NOTEON',
+ 'NOTEOFF',
+ 'NOTEEND',
+ 'COLDOWN',
+ 'COLUP',
+ 'COLOVER',
+ 'COLSTATECHANGE']
+
eventNames = {}
self = modules[__name__]
for i, name in enumerate(events) :
eventNames = {}
self = modules[__name__]
for i, name in enumerate(events) :
- eventType = pygame.USEREVENT
+
i
+ eventType = pygame.USEREVENT
+ 1 +
i
eventNames[eventType] = name
setattr(self, name, eventType)
eventNames[eventType] = name
setattr(self, name, eventType)
@@
-33,3
+40,5
@@
pygame_events = [
for name in pygame_events :
eventNames[getattr(pygame, name)] = name
for name in pygame_events :
eventNames[getattr(pygame, name)] = name
+
+eventCodes = dict([v, k] for k, v in eventNames.items())