Add make_event(..) to EventHookContext

This commit is contained in:
jesopo 2019-01-30 19:37:52 +00:00
parent 72072bbd3d
commit 5dda000c96

View file

@ -275,6 +275,10 @@ class EventHookContext(object):
def __init__(self, parent, context):
self._parent = parent
self.context = context
def make_event(self, **kwargs):
return self._parent.make_event(**kwargs)
def hook(self, function: CALLBACK_TYPE, priority: int = DEFAULT_PRIORITY,
replay: bool = False, **kwargs) -> EventCallback:
return self._parent._context_hook(self.context, function, priority,