summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorkhachbe <woody.hojeily@gmail.com>2024-07-21 13:59:09 +0200
committerGitHub <noreply@github.com>2024-07-21 13:59:09 +0200
commitcf373d315e9fb060576ed407bd5ee2dfb8a6d2e2 (patch)
treee7964e2ad4068fb7c8f0330fb0d72192dafbfb20 /src
parent016da234d0e852de3ef20eb2e89ac58d2a85f6e7 (diff)
touch: add touch swipe invert config (#6940)
Diffstat (limited to 'src')
-rw-r--r--src/config/ConfigManager.cpp1
-rw-r--r--src/managers/input/Touch.cpp2
2 files changed, 2 insertions, 1 deletions
diff --git a/src/config/ConfigManager.cpp b/src/config/ConfigManager.cpp
index a5f18693..6928a802 100644
--- a/src/config/ConfigManager.cpp
+++ b/src/config/ConfigManager.cpp
@@ -519,6 +519,7 @@ CConfigManager::CConfigManager() {
m_pConfig->addConfigValue("gestures:workspace_swipe_forever", Hyprlang::INT{0});
m_pConfig->addConfigValue("gestures:workspace_swipe_use_r", Hyprlang::INT{0});
m_pConfig->addConfigValue("gestures:workspace_swipe_touch", Hyprlang::INT{0});
+ m_pConfig->addConfigValue("gestures:workspace_swipe_touch_invert", Hyprlang::INT{0});
m_pConfig->addConfigValue("xwayland:use_nearest_neighbor", Hyprlang::INT{1});
m_pConfig->addConfigValue("xwayland:force_zero_scaling", Hyprlang::INT{0});
diff --git a/src/managers/input/Touch.cpp b/src/managers/input/Touch.cpp
index a1f949c2..736a2ae5 100644
--- a/src/managers/input/Touch.cpp
+++ b/src/managers/input/Touch.cpp
@@ -103,7 +103,7 @@ void CInputManager::onTouchMove(ITouch::SMotionEvent e) {
return;
const bool VERTANIMS = m_sActiveSwipe.pWorkspaceBegin->m_vRenderOffset.getConfig()->pValues->internalStyle == "slidevert" ||
m_sActiveSwipe.pWorkspaceBegin->m_vRenderOffset.getConfig()->pValues->internalStyle.starts_with("slidefadevert");
- static auto PSWIPEINVR = CConfigValue<Hyprlang::INT>("gestures:workspace_swipe_invert");
+ static auto PSWIPEINVR = CConfigValue<Hyprlang::INT>("gestures:workspace_swipe_touch_invert");
static auto PSWIPEDIST = CConfigValue<Hyprlang::INT>("gestures:workspace_swipe_distance");
const auto SWIPEDISTANCE = std::clamp(*PSWIPEDIST, (int64_t)1LL, (int64_t)UINT32_MAX);
// Handle the workspace swipe if there is one