summaryrefslogtreecommitdiff
path: root/src/input/feedback_haptics.cpp
diff options
context:
space:
mode:
authorjacqueline <me@jacqueline.id.au>2024-05-02 19:12:26 +1000
committerjacqueline <me@jacqueline.id.au>2024-05-02 19:12:26 +1000
commit1573a8c4cde1cd9528b422b2dcc598e37ffe94a7 (patch)
treed162822b8fd7054f81bace0c7a65ab4d5e6f93ef /src/input/feedback_haptics.cpp
parenta231fd1c8afedbeb14b0bc77d76bad61db986059 (diff)
downloadtangara-fw-1573a8c4cde1cd9528b422b2dcc598e37ffe94a7.tar.gz
WIP merge cyclically dependent components into one big component
Diffstat (limited to 'src/input/feedback_haptics.cpp')
-rw-r--r--src/input/feedback_haptics.cpp37
1 files changed, 0 insertions, 37 deletions
diff --git a/src/input/feedback_haptics.cpp b/src/input/feedback_haptics.cpp
deleted file mode 100644
index 5e83d0d6..00000000
--- a/src/input/feedback_haptics.cpp
+++ /dev/null
@@ -1,37 +0,0 @@
-/*
- * Copyright 2024 jacqueline <me@jacqueline.id.au>
- *
- * SPDX-License-Identifier: GPL-3.0-only
- */
-
-#include "feedback_haptics.hpp"
-
-#include <cstdint>
-
-#include "lvgl/lvgl.h"
-
-#include "core/lv_event.h"
-#include "esp_log.h"
-
-#include "haptics.hpp"
-
-namespace input {
-
-using Effect = drivers::Haptics::Effect;
-
-Haptics::Haptics(drivers::Haptics& haptics_) : haptics_(haptics_) {}
-
-auto Haptics::feedback(uint8_t event_type) -> void {
- switch (event_type) {
- case LV_EVENT_FOCUSED:
- haptics_.PlayWaveformEffect(Effect::kMediumClick1_100Pct);
- break;
- case LV_EVENT_CLICKED:
- haptics_.PlayWaveformEffect(Effect::kSharpClick_100Pct);
- break;
- default:
- break;
- }
-}
-
-} // namespace input