controller/handler: allow set_ev_handler without dispatchers
Signed-off-by: YAMAMOTO Takashi <yamamoto@valinux.co.jp> Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
This commit is contained in:
parent
4b8a4fc870
commit
b869748e4b
@ -38,7 +38,7 @@ def set_ev_cls(ev_cls, dispatchers=None):
|
|||||||
return _set_ev_cls_dec
|
return _set_ev_cls_dec
|
||||||
|
|
||||||
|
|
||||||
def set_ev_handler(ev_cls, dispatchers):
|
def set_ev_handler(ev_cls, dispatchers=None):
|
||||||
def _set_ev_cls_dec(handler):
|
def _set_ev_cls_dec(handler):
|
||||||
handler.ev_cls = ev_cls
|
handler.ev_cls = ev_cls
|
||||||
handler.dispatchers = _listify(dispatchers)
|
handler.dispatchers = _listify(dispatchers)
|
||||||
|
Loading…
Reference in New Issue
Block a user