From d973959f7f34e02eeb01766b01aff680639a8c4c Mon Sep 17 00:00:00 2001 From: tcmal Date: Tue, 6 Aug 2024 14:39:55 +0100 Subject: Add support for mouse button binds --- src/config.rs | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) (limited to 'src/config.rs') diff --git a/src/config.rs b/src/config.rs index 3182ba7..aebe0f1 100644 --- a/src/config.rs +++ b/src/config.rs @@ -2,16 +2,16 @@ #![allow(clippy::unreadable_literal)] // Colours are more readable this way imo use xcb::x::ModMask; -use xkeysym::Keysym; use crate::{ - bind, + bind, bind_btn, + buttons::ButtonBinds, clients::TagFocus, conn_info::Colour, helpers::{ focus_next, focus_prev, set_tag, set_tag_focus, spawn, toggle_floating, toggle_fullscreen, }, - keys::{Keybind, Keybinds}, + keys::Keybinds, }; /// Width of the border around windows @@ -87,3 +87,9 @@ pub const KEYBINDS: Keybinds = Keybinds(&[ // TAGKEYS( XK_9, 8) // { MODKEY|ShiftMask, XK_q, quit, {0} }, ]); + +/// The (mouse) button binds to use +pub const BUTTON_BINDS: ButtonBinds = ButtonBinds(&[ + bind_btn!(MAIN_MODIFIER , N1 -> &toggle_floating), + // TODO +]); -- cgit v1.2.3