awful.mouse: Add a "request::default_mousebindings" signal.
`rc.lua` and the module must attach to this signal to add buttons to the default set.
This commit is contained in:
parent
8b6ea8243a
commit
d6568993e2
|
@ -529,6 +529,15 @@ end)
|
|||
-- when button 1 is pressed.
|
||||
-- @staticfct mouse.coords
|
||||
|
||||
capi.client.connect_signal("scanning", function()
|
||||
capi.client.emit_signal("request::default_mousebindings", "startup")
|
||||
end)
|
||||
|
||||
-- Private function to be used by `ruled.client`.
|
||||
function mouse._get_client_mousebindings()
|
||||
return default_buttons
|
||||
end
|
||||
|
||||
return mouse
|
||||
|
||||
-- vim: filetype=lua:expandtab:shiftwidth=4:tabstop=8:softtabstop=4:textwidth=80
|
||||
|
|
|
@ -244,6 +244,17 @@
|
|||
* @signal request::urgent
|
||||
*/
|
||||
|
||||
/** Emitted during startup to gather the default client mousebindings.
|
||||
*
|
||||
* This signals gives a chance to all module to register new client keybindings.
|
||||
* Assuming the client rules does not overwrite them with the `keys` property,
|
||||
* they will be added to all clients.
|
||||
*
|
||||
* @signal request::default_mousebindings
|
||||
* @tparam string context The reason why the signal was sent (currently always
|
||||
* `startup`).
|
||||
*/
|
||||
|
||||
/** When a client gets tagged.
|
||||
* @signal tagged
|
||||
* @tag t The tag object.
|
||||
|
|
Loading…
Reference in New Issue