support buffer as a hook target
This commit is contained in:
parent
0e8add34ae
commit
c8fdbc2a60
|
@ -458,6 +458,8 @@ void add_hook(const CommandParameters& params, const Context& context)
|
|||
|
||||
if (params[0] == "global")
|
||||
GlobalHookManager::instance().add_hook(params[1], hook_func);
|
||||
else if (params[0] == "buffer")
|
||||
context.buffer().hook_manager().add_hook(params[1], hook_func);
|
||||
else if (params[0] == "window")
|
||||
context.window().hook_manager().add_hook(params[1], hook_func);
|
||||
else
|
||||
|
|
Loading…
Reference in New Issue
Block a user