Add context to request::activate signal

This commit is contained in:
Emmanuel Lepage Vallee 2014-05-05 23:12:21 -04:00 committed by Uli Schlachter
parent f637265334
commit b0ede3108e
2 changed files with 3 additions and 2 deletions

3
ewmh.c Normal file → Executable file
View File

@ -422,7 +422,8 @@ ewmh_process_client_message(xcb_client_message_event_t *ev)
{ {
if((c = client_getbywin(ev->window))) { if((c = client_getbywin(ev->window))) {
luaA_object_push(globalconf.L, c); luaA_object_push(globalconf.L, c);
luaA_object_emit_signal(globalconf.L, -1, "request::activate", 0); lua_pushstring(globalconf.L,"ewmh");
luaA_object_emit_signal(globalconf.L, -2, "request::activate", 1);
lua_pop(globalconf.L, 1); lua_pop(globalconf.L, 1);
} }
} }

View File

@ -237,7 +237,7 @@ function rules.execute(c, props, callbacks)
-- Do this at last so we do not erase things done by the focus -- Do this at last so we do not erase things done by the focus
-- signal. -- signal.
if props.focus and (type(props.focus) ~= "function" or props.focus(c)) then if props.focus and (type(props.focus) ~= "function" or props.focus(c)) then
c:emit_signal('request::activate') c:emit_signal('request::activate',"rules")
end end
end end