From a5b310872c3499466877f5978dcfafdd46ca7583 Mon Sep 17 00:00:00 2001 From: Vlad Glagolev Date: Sat, 3 Feb 2018 17:22:17 -0500 Subject: [PATCH] Respect 'enable-scroll' setting for xworkspaces module --- src/modules/xworkspaces.cpp | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/modules/xworkspaces.cpp b/src/modules/xworkspaces.cpp index 642bec05..a250afdc 100644 --- a/src/modules/xworkspaces.cpp +++ b/src/modules/xworkspaces.cpp @@ -264,8 +264,10 @@ namespace modules { output += module::get_output(); } - m_builder->cmd(mousebtn::SCROLL_DOWN, string{EVENT_PREFIX} + string{EVENT_SCROLL_DOWN}); - m_builder->cmd(mousebtn::SCROLL_UP, string{EVENT_PREFIX} + string{EVENT_SCROLL_UP}); + if (m_scroll) { + m_builder->cmd(mousebtn::SCROLL_DOWN, string{EVENT_PREFIX} + string{EVENT_SCROLL_DOWN}); + m_builder->cmd(mousebtn::SCROLL_UP, string{EVENT_PREFIX} + string{EVENT_SCROLL_UP}); + } m_builder->append(output);