+# -*- coding: utf-8 -*-
+"""
+formatage des événements
+
+$Id$
+$URL$
+"""
+
from events import eventNames
import sys
self = sys.modules[__name__]
def log_COLDOWN(e) :
- return '%s' % e.column.tone.nom
+ tone = e.column.tone
+ return '%s (%s)' % (e.midi, e.nom)
+
+def log_COLSTATECHANGE(e) :
+ return u'%5s %s' % (e.state, e.syllabus)
def log_default(e) :
return str(e)
import types
import pygame
from StringIO import StringIO
-from logging import getLogger, basicConfig, DEBUG
-import sys
-from events import TIMEOUT, COLOVER, eventNames
-basicConfig(level=DEBUG, stream = sys.stdout)
-console = getLogger('minwii')
-eventLog = getLogger('minwii.events')
-
-hiddenEvents = {pygame.MOUSEMOTION:True,
- TIMEOUT:True,
- #COLOVER:True,
- }
-from event_pprinters import pprinters
+from log import console, eventLog, hiddenEvents, pprinters
class _EventDispatcher :
def __init__(self) :
--- /dev/null
+# -*- coding: utf-8 -*-
+"""
+utilitaires pour tracer l'activité de miiwii
+
+$Id$
+$URL$
+"""
+
+from events import TIMEOUT, COLOVER, eventNames
+from event_pprinters import pprinters
+import sys
+import pygame
+from logging import basicConfig, getLogger, DEBUG
+
+basicConfig(level=DEBUG, stream = sys.stdout)
+console = getLogger('minwii')
+eventLog = getLogger('minwii.events')
+
+hiddenEvents = {pygame.MOUSEMOTION:True,
+ TIMEOUT:True,
+ #COLOVER:True,
+ }