From 5ba33f846129f3e6c0505b19f94634b24505e828 Mon Sep 17 00:00:00 2001 From: Vaxry <43317083+vaxerski@users.noreply.github.com> Date: Sun, 26 Apr 2026 15:16:36 +0100 Subject: config/lua: init lua config manager, use lua if available (#13817) Adds a new lua config manager, which will automatically be used if there is a lua config present. --- src/managers/input/Touch.cpp | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) (limited to 'src/managers/input/Touch.cpp') diff --git a/src/managers/input/Touch.cpp b/src/managers/input/Touch.cpp index 942c168c..f49db8b7 100644 --- a/src/managers/input/Touch.cpp +++ b/src/managers/input/Touch.cpp @@ -15,13 +15,13 @@ void CInputManager::onTouchDown(ITouch::SDownEvent e) { m_lastInputTouch = true; - static auto PSWIPETOUCH = CConfigValue("gestures:workspace_swipe_touch"); - static auto PGAPSOUTDATA = CConfigValue("general:gaps_out"); - auto* const PGAPSOUT = sc((PGAPSOUTDATA.ptr())->getData()); + static auto PSWIPETOUCH = CConfigValue("gestures:workspace_swipe_touch"); + static auto PGAPSOUTDATA = CConfigValue("general:gaps_out"); + auto* const PGAPSOUT = sc((PGAPSOUTDATA.ptr())); // TODO: WORKSPACERULE.gapsOut.value_or() auto gapsOut = *PGAPSOUT; - static auto PBORDERSIZE = CConfigValue("general:border_size"); - static auto PSWIPEINVR = CConfigValue("gestures:workspace_swipe_touch_invert"); + static auto PBORDERSIZE = CConfigValue("general:border_size"); + static auto PSWIPEINVR = CConfigValue("gestures:workspace_swipe_touch_invert"); Event::SCallbackInfo info; Event::bus()->m_events.input.touch.down.emit(e, info); @@ -149,8 +149,8 @@ void CInputManager::onTouchMove(ITouch::SMotionEvent e) { const auto ANIMSTYLE = g_pUnifiedWorkspaceSwipe->m_workspaceBegin->m_renderOffset->getStyle(); const bool VERTANIMS = ANIMSTYLE == "slidevert" || ANIMSTYLE.starts_with("slidefadevert"); - static auto PSWIPEINVR = CConfigValue("gestures:workspace_swipe_touch_invert"); - static auto PSWIPEDIST = CConfigValue("gestures:workspace_swipe_distance"); + static auto PSWIPEINVR = CConfigValue("gestures:workspace_swipe_touch_invert"); + static auto PSWIPEDIST = CConfigValue("gestures:workspace_swipe_distance"); const auto SWIPEDISTANCE = std::clamp(*PSWIPEDIST, sc(1LL), sc(UINT32_MAX)); // Handle the workspace swipe if there is one if (g_pUnifiedWorkspaceSwipe->m_initialDirection == -1) { -- cgit v1.2.3